> void function(integer);
>
> What does the void mean?  And how would I use the function?  I just get a
> parse error when I use the function with the "void" in it and the "called
to
> undefined function" (even with an integer) when I omit the "void."

The word in that location in the documentation never means something you
should type.

Rather, it means what kind of data you should expect to get back from the
function.

Thus, int blah(); indicates that blah() returns an integer.

"void" just means it doesn't return anything -- The function in question
must do something useful, though, so it probably has some sort of
side-effect.  It either prints something or loads something or...

It's also possible that you pass in argument[s] to get data back rather than
the function returning a value.

Anyway, after you got rid of the "void", and you got "undefined function"
that probably means that you were typing everything okay, but that you don't
have that particular PHP extension in your installation.

PHP has forty 'leven different extensions, and some are mutually
incompatible and others are just plain arcane :-)  Anyway, whatever function
you are trying to use is probably in an extension you didn't install.

Under Windows, you figure out which extension that is, make sure you have
the xxx_php.dll that goes with it, and uncomment (or add) the line in
php.ini that loads that extension.

Under Un*x, you generally just recompile from source code.

There is one more possiblity:  You may have an old version of PHP installed,
and you're trying to use some cool new function.

Make a page with just <?php phpinfo();?> in it and throw it on your server
and surf to it.

Compare your version number with the documentation to see if the function
was added later than your version.  If so, you'll have to upgrade.

--
Visit the Zend Store at http://www.zend.com/store/
Wanna help me out?  Like Music?  Buy a CD: http://l-i-e.com/artists.htm
Volunteer a little time: http://chatmusic.com/volunteer.htm



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to