Jump to content

Have you ever confused the php functions syntaxes?


asmith

Recommended Posts

Hey :)

 

Some functions that maybe look like each other, has different place of arguments.

for example :

 

in_array("find",$array) .  find is first, the array is second.

strpos ($string, "find") ,  find is last, string is first.

 

I remember after a while, I gotta check them in php.net which is which.

any logic behind these places of arguments?

That's one of the reasons that a decent IDE helps so much; shows you the function prototype as you type the function

 

Indeed. I know its not exactly an IDE but I wish vim could do this. The best Iv'e got is to hold CTRL-1 whilst over a function name and have a shell script lookup the function in the manual for me.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.