php-general Digest 29 Mar 2009 21:12:59 -0000 Issue 6038

2009-03-29 Thread php-general-digest-help

php-general Digest 29 Mar 2009 21:12:59 - Issue 6038

Topics (messages 290794 through 290798):

Re: Sort a multi-dimensional array on a certain key followed by another key
290794 by: Virgilio Quilario

Re: Calling function on the same line?
290795 by: Andrea Giammarchi
290796 by: Andrea Giammarchi

Re: foreach and form submission.
290797 by: Angus Mann

Security Support
290798 by: Grant Peel

Administrivia:

To subscribe to the digest, e-mail:
php-general-digest-subscr...@lists.php.net

To unsubscribe from the digest, e-mail:
php-general-digest-unsubscr...@lists.php.net

To post to the list, e-mail:
php-gene...@lists.php.net


--
---BeginMessage---
 Ok so, I have an array

 [0(index)][1st key][2nd key]

 Basically I don't care about the index. As a matter of fact I'd prefer it
 reset to still be in order afterwards.

 However, I need to sort the 1st key and keep correlation w the second key.
 Then sort on the second key.

 I have video volumes and scenes like

 [0][110][1]
 [1][110][3]
 [2][110][2]
 [3][110][4]

 Any help would be much appreciated.


looks like a job for array_multisort() function
http://php.net/array_multisort

virgil
http://www.jampmark.com
---End Message---
---BeginMessage---

I don't , I mean if the function is not str_replace you do not necesary need 
the echo (array_push, as example)
This notation:
?=
is deprecated since dunno how long ago ... strongly not suggested

 Date: Sun, 29 Mar 2009 01:06:16 +0800
 Subject: Re: [PHP] Calling function on the same line?
 From: virgilio.quila...@gmail.com
 To: an_...@hotmail.com
 CC: php-gene...@lists.php.net
 
 
  I miss the utility to do stuff like that ... seriously ... but in any case:
 
  ?php
  echo ($f = 'str_replace') ? $f(a, b, aaa) : null;
  ?
 
  where echo is optional.
 
  Regards
 
 you mean this
 ?= ($f = 'str_replace') ? $f(a,b,aaa) : null; ?
 
 virgil
 http://www.jampmark.com

_
Drag n’ drop—Get easy photo sharing with Windows Live™ Photos.

http://www.microsoft.com/windows/windowslive/products/photos.aspx---End Message---
---BeginMessage---

How do you pass that string?
If you replace via other file, you do not need to use strings, just call the 
function.
If you are parsing a variable, you do not need the inline ...
$_GET['function'](a, b, aaa);
if the query string is function=str_replace

I do not get the problem at all specially now that you do not need variables 
... and if you will end up with eval, you are doing something wrong.

Regards



Date: Sat, 28 Mar 2009 17:09:15 +0300
Subject: Re: [PHP] Calling function on the same line?
From: danondan...@gmail.com
To: an_...@hotmail.com

Thank you for trying to help, But I am trying to do it without variables =[

On Sat, Mar 28, 2009 at 3:51 PM, Andrea Giammarchi an_...@hotmail.com wrote:




I miss the utility to do stuff like that ... seriously ... but in any case:



?php

echo ($f = 'str_replace') ? $f(a, b, aaa) : null;

?



where echo is optional.



Regards





 Date: Sat, 28 Mar 2009 15:26:18 +0300

 From: danondan...@gmail.com

 To: php-gene...@lists.php.net

 Subject: [PHP] Calling function on the same line?



 Is there any way to do something like:



 ?php

 (str_replace)(a, b, aaa);

 ?



 ?



 One of the problems that I must keep str_replace on the same line...The

 only solution I see is call_user_func, but I would like to know if you guys

 might have a clue =]

 Tried looking on the manual, sadly didn't found anything



 Thanks, Daniel



_

More than messages–check out the rest of the Windows Live™.

http://www.microsoft.com/windows/windowslive/

_
News, entertainment and everything you care about at Live.com. Get it now!
http://www.live.com/getstarted.aspx---End Message---
---BeginMessage---

Thanks Ashley...that did the trick.
After reading about the limitations of strip_tags I decided to just replace 
the bad bits as below...
It still uses your foreach suggestion but replaces  and  with ( 
and ) instead of stripping tags.


I think I will extend the good and bad arrays to deal with magic quotes also 
!


$bad = array('','lt;','#60;', '', 'gt;', '#62');
$good = array('(', '(', '(', ')', ')', ')');
foreach ($_POST as $key = $value) {
$_POST[$key] = str_ireplace($bad, $good, $value);
}






I'd do something like this, so as to preserve the original post data
array:

$data = Array();
foreach($_POST as $key = $value)
{
   $data[$key] = strip_tags($value);
}

Note that strip_tags() will not be able to decently clean up messy code
(i.e. code where the opening or closing tags themselves aren't formed
properly)


Ash
www.ashleysheridan.co.uk




---End Message---
---BeginMessage---

Good Morning / Afternoon,

We run several of our 

[PHP] Security Support

2009-03-29 Thread Grant Peel

Good Morning / Afternoon,

We run several of our own servers:

- Dell Power Edge 1U, Pentium,
- FreeBSD (6.x soon to be 7.x)
- along with all the standard Web Application installation (PHP Apache Exim, 
Pop3, Proftp, MySQL etc etc).


What I am asking here, is if any one in this community has the knowledge to 
act as a security consultant in an occasional, as required basis. Anyone 
interested should have expience with Apache, PHP, Perl on the FreeBSD 
platform.


We are more than willing to compensate for services rendered, and are more 
than willing to discuss terms.


In the end, we would be more than willing to share any non-fudiciary 
information with anyone who could find it useful (via this or other mailing 
lists).


We are asking any interested parties to contact us off-list such that we 
don't need to make any private matters public.


This is a bonified request, as we can setup servers ourselves, but simply do 
not have the time to research various run time, and security related items.


TIA,

-Grant 



--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] Security Support

2009-03-29 Thread abdulazeez alugo


 

 From: gp...@thenetnow.com
 To: php-general@lists.php.net
 Date: Sun, 29 Mar 2009 17:12:32 -0400
 Subject: [PHP] Security Support
 
 Good Morning / Afternoon,
 
 We run several of our own servers:
 
 - Dell Power Edge 1U, Pentium,
 - FreeBSD (6.x soon to be 7.x)
 - along with all the standard Web Application installation (PHP Apache Exim, 
 Pop3, Proftp, MySQL etc etc).
 
 What I am asking here, is if any one in this community has the knowledge to 
 act as a security consultant in an occasional, as required basis. Anyone 
 interested should have expience with Apache, PHP, Perl on the FreeBSD 
 platform.
 
 We are more than willing to compensate for services rendered, and are more 
 than willing to discuss terms.
 
 In the end, we would be more than willing to share any non-fudiciary 
 information with anyone who could find it useful (via this or other mailing 
 lists).
 
 We are asking any interested parties to contact us off-list such that we 
 don't need to make any private matters public.
 
 This is a bonified request, as we can setup servers ourselves, but simply do 
 not have the time to research various run time, and security related items.
 
 TIA,
 
 -Grant 


Hey Guys,

Let's be honest with ourselves here. If you've applied for this job, let me see 
your hands up!!!

 

Alugo Abdulazeez

www.frangeovic.com

_
News, entertainment and everything you care about at Live.com. Get it now!
http://www.live.com/getstarted.aspx

Re: [PHP] Security Support

2009-03-29 Thread David Wonderly


- Original Message - 
From: abdulazeez alugo defati...@hotmail.com

To: gp...@thenetnow.com; php-general@lists.php.net
Sent: Sunday, March 29, 2009 6:09 PM
Subject: RE: [PHP] Security Support







From: gp...@thenetnow.com
To: php-general@lists.php.net
Date: Sun, 29 Mar 2009 17:12:32 -0400
Subject: [PHP] Security Support

Good Morning / Afternoon,

We run several of our own servers:

- Dell Power Edge 1U, Pentium,
- FreeBSD (6.x soon to be 7.x)
- along with all the standard Web Application installation (PHP Apache 
Exim,

Pop3, Proftp, MySQL etc etc).

What I am asking here, is if any one in this community has the knowledge 
to

act as a security consultant in an occasional, as required basis. Anyone
interested should have expience with Apache, PHP, Perl on the FreeBSD
platform.

We are more than willing to compensate for services rendered, and are more
than willing to discuss terms.

In the end, we would be more than willing to share any non-fudiciary
information with anyone who could find it useful (via this or other 
mailing

lists).

We are asking any interested parties to contact us off-list such that we
don't need to make any private matters public.

This is a bonified request, as we can setup servers ourselves, but simply 
do
not have the time to research various run time, and security related 
items.


TIA,

-Grant



Hey Guys,

Let's be honest with ourselves here. If you've applied for this job, let me 
see your hands up!!!




Alugo Abdulazeez

www.frangeovic.com

_
News, entertainment and everything you care about at Live.com. Get it now!
http://www.live.com/getstarted.aspx




*Pauses and listens to crickets chirp*

Dave Wonderly
WebGenero
www.webgenero.com


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] Security Support

2009-03-29 Thread Marc Christopher Hall
I is a hi skool gradjuate

-Original Message-
From: abdulazeez alugo [mailto:defati...@hotmail.com] 
Sent: Sunday, March 29, 2009 7:10 PM
To: gp...@thenetnow.com; php-general@lists.php.net
Subject: RE: [PHP] Security Support



 

 From: gp...@thenetnow.com
 To: php-general@lists.php.net
 Date: Sun, 29 Mar 2009 17:12:32 -0400
 Subject: [PHP] Security Support
 
 Good Morning / Afternoon,
 
 We run several of our own servers:
 
 - Dell Power Edge 1U, Pentium,
 - FreeBSD (6.x soon to be 7.x)
 - along with all the standard Web Application installation (PHP Apache
Exim, 
 Pop3, Proftp, MySQL etc etc).
 
 What I am asking here, is if any one in this community has the knowledge
to 
 act as a security consultant in an occasional, as required basis. Anyone 
 interested should have expience with Apache, PHP, Perl on the FreeBSD 
 platform.
 
 We are more than willing to compensate for services rendered, and are more

 than willing to discuss terms.
 
 In the end, we would be more than willing to share any non-fudiciary 
 information with anyone who could find it useful (via this or other
mailing 
 lists).
 
 We are asking any interested parties to contact us off-list such that we 
 don't need to make any private matters public.
 
 This is a bonified request, as we can setup servers ourselves, but simply
do 
 not have the time to research various run time, and security related
items.
 
 TIA,
 
 -Grant 


Hey Guys,

Let's be honest with ourselves here. If you've applied for this job, let me
see your hands up!!!

 

Alugo Abdulazeez

www.frangeovic.com

_
News, entertainment and everything you care about at Live.com. Get it now!
http://www.live.com/getstarted.aspx


__ Information from ESET Smart Security, version of virus signature
database 3973 (20090329) __

The message was checked by ESET Smart Security.

http://www.eset.com

 

__ Information from ESET Smart Security, version of virus signature
database 3973 (20090329) __

The message was checked by ESET Smart Security.

http://www.eset.com
 


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] Security Support

2009-03-29 Thread abdulazeez alugo


 

 From: da...@wonderly.com
 To: defati...@hotmail.com; gp...@thenetnow.com; php-general@lists.php.net
 Date: Sun, 29 Mar 2009 18:16:35 -0500
 Subject: Re: [PHP] Security Support
 
 
 - Original Message - 
 From: abdulazeez alugo defati...@hotmail.com
 To: gp...@thenetnow.com; php-general@lists.php.net
 Sent: Sunday, March 29, 2009 6:09 PM
 Subject: RE: [PHP] Security Support
 
 
 
 
 
 
  From: gp...@thenetnow.com
  To: php-general@lists.php.net
  Date: Sun, 29 Mar 2009 17:12:32 -0400
  Subject: [PHP] Security Support
 
  Good Morning / Afternoon,
 
  We run several of our own servers:
 
  - Dell Power Edge 1U, Pentium,
  - FreeBSD (6.x soon to be 7.x)
  - along with all the standard Web Application installation (PHP Apache 
  Exim,
  Pop3, Proftp, MySQL etc etc).
 
  What I am asking here, is if any one in this community has the knowledge 
  to
  act as a security consultant in an occasional, as required basis. Anyone
  interested should have expience with Apache, PHP, Perl on the FreeBSD
  platform.
 
  We are more than willing to compensate for services rendered, and are more
  than willing to discuss terms.
 
  In the end, we would be more than willing to share any non-fudiciary
  information with anyone who could find it useful (via this or other 
  mailing
  lists).
 
  We are asking any interested parties to contact us off-list such that we
  don't need to make any private matters public.
 
  This is a bonified request, as we can setup servers ourselves, but simply 
  do
  not have the time to research various run time, and security related 
  items.
 
  TIA,
 
  -Grant
 
 
 Hey Guys,
 
 Let's be honest with ourselves here. If you've applied for this job, let me 
 see your hands up!!!
 
 
 
 Alugo Abdulazeez
 
 www.frangeovic.com
 
 
 
 *Pauses and listens to crickets chirp*
 
 Dave Wonderly
 WebGenero
 www.webgenero.com


steam

Hey Dave,

Are you trying to tell us something or are you just writing your first 
novel?/steam

 

Alugo Abdulazeez 


_
Drag n’ drop—Get easy photo sharing with Windows Live™ Photos.

http://www.microsoft.com/windows/windowslive/products/photos.aspx

Re: [PHP] Security Support

2009-03-29 Thread Michael A. Peters

Grant Peel wrote:

Good Morning / Afternoon,

We run several of our own servers:

- Dell Power Edge 1U, Pentium,
- FreeBSD (6.x soon to be 7.x)
- along with all the standard Web Application installation (PHP Apache 
Exim, Pop3, Proftp, MySQL etc etc).


What I am asking here, is if any one in this community has the knowledge 
to act as a security consultant in an occasional, as required basis. 
Anyone interested should have expience with Apache, PHP, Perl on the 
FreeBSD platform.


No experience with FreeBSD and probably not enough with Perl - but 
whoever you hire, make sure they suggest your php build is hardened by 
suhosin - both the core php patch and the loadable module.


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Security Support

2009-03-29 Thread Michael A. Peters

Marc Christopher Hall wrote:

I is a hi skool gradjuate


Yea, dude, well me GED says I kin git it dun wit less wastid time.

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] Security Support

2009-03-29 Thread abdulazeez alugo


 
 Date: Sun, 29 Mar 2009 19:02:15 -0700
 From: mpet...@mac.com
 To: m...@hallmarcwebsites.com
 CC: php-general@lists.php.net
 Subject: Re: [PHP] Security Support
 
 Marc Christopher Hall wrote:
  I is a hi skool gradjuate
 
 Yea, dude, well me GED says I kin git it dun wit less wastid time.
 
 -- 
No be only una get pidgin English ooo. Me sef fit do am sharp sharp no be say 
them say.
_
More than messages–check out the rest of the Windows Live™.
http://www.microsoft.com/windows/windowslive/