PHP Developers Network
http://forums.devnetwork.net/

how to create a new function
http://forums.devnetwork.net/viewtopic.php?f=19&t=137960
Page 1 of 1

Author:  kairya14 [ Sat Jun 15, 2013 12:43 am ]
Post subject:  how to create a new function

hello all,
i am new in php development,and i do not know hohw to make any function an any one told me how i will do this?

thanks in advance

Author:  pbs [ Sat Jun 15, 2013 12:49 am ]
Post subject:  Re: how to create a new function

Refer: http://www.php.net/manual/en/functions.user-defined.php

Author:  uday.strad [ Mon Jan 06, 2014 4:45 am ]
Post subject:  Re: how to create a new function

LOL...
What sort of question is this .... you will always find this answer....although your new next time make sure you google these doubts....

Heres your answer....
<?php
function writeMsg()
{
echo "Hello world!";
}

writeMsg(); // call the function
?>

Author:  disha [ Mon Jul 28, 2014 5:37 am ]
Post subject:  Re: how to create a new function

Hi,
You should try this code to call any function
<?php
function foo($arg_1, $arg_2, /* ..., */ $arg_n)
{
echo "Example function.\n";
return $retval;
}
?>

Thanks I hope it will help you.

Page 1 of 1 All times are UTC - 5 hours
Powered by phpBB® Forum Software © phpBB Group
http://www.phpbb.com/