RE: [PHP] Functions
Hi not the () after the function name > > function ShowMessage() { > echo "Show message...\n"; > } > > How can I call the function now? > echo ShowMessage(); :: Emil --- Emil Rasmussen http://www.noget.net -- 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]
RE: [PHP] Functions
That should bee notice and not "not"! Ups :-) > > Hi > > not the () after the function name > > > > > function ShowMessage() { > > echo "Show message...\n"; > > } > > > > How can I call the function now? > > > > > echo ShowMessage(); > > > :: Emil > > --- > Emil Rasmussen > http://www.noget.net > > -- > 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] > -- 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]
RE: [PHP] What does "url_rewriter.tags" do?
> Subject: [PHP] What does "url_rewriter.tags" do? > What does it do? url_rewriter.tags is a list of HTML elements that will get the PHPSESSID added to them. Its all about sessions: http://www.php.net/manual/en/ref.session.php. Emil -- Emil Rasmussen http://www.noget.net -- 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]
Re: [PHP] A compress function?
Hey > With all the wonderful String functions in PHP, I haven't been able to find > a str_compress(). Is there such an animal? Let's say I have a string like > this: > > $myString = First_word <30 spaces> second_word <10 spaces> etc... This would proberly work: -- function str_compress($stString) { if (substr_count($stString,' ') == 0) { return $stString; } $stString = str_replace(' ',' ',$stString); return str_compress($stString); } echo str_compress('dsfsd fdf sdf sdfd sf sf sdf sf s fdsf sdfsdf sfsfsd sfs sf '); -- Regards Emil ps. I admit that I dont know if there is a built in function. -- Emil Rasmussen http://noget.net -- 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]
Re: [PHP] $GLOBALS
> i´m new in PHP. What does the expression: >$ref=$GLOBALS["HTTP_GET_VARS"]["ref"]; >$id=$GLOBALS["HTTP_GET_VARS"]["id"]; > do? It gives you the content of the querystring variable ref and id. eg. page.php?id=20&ref=value > What is $GLOBALS? $GLOBALS is an array wich contains all the varibles in the "global variable scope". http://dk.php.net/manual/en/language.variables.scope.php You can get an overview of all the variables by using the print_r() function: print_r($GLOBALS); http://dk.php.net/manual/en/function.print-r.php > What are the parameters ["HTTP_GET_VARS"]["ref"]? ["HTTP_GET_VARS"] is also an array, and it contains alle the variables from the querystring. And ['ref'] is a querystring variable. /Emil -- Emil Rasmussen http://noget.net -- 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]