![]() |
|
|||||||
| Register | FAQ | Members List | Downloads | Calendar | Today's Posts | Search | Webmaster Resources | Webmaster Blogs |
![]() UK Web Hosting |
![]() Website Hosting |
![]() UK One Way |
|
![]() |
|
|
LinkBack | Thread Tools | Display Modes |
|
||||
|
You can create a function dynamically in php by using create_function function. This is especiallyuseful for creating anonymous callback functions. First parameter to the create_function function is a string specifying the function arguments and second parameter is a string specifying function body. For example :
Code:
<?php
$dynamic_func = create_function('$arg1, $arg2', 'return pow($arg1, $arg2);');
echo $dynamic_func(2,6);
?>
|
![]() |
| Bookmarks |
| Webmaster Resources |
| • UK Web Hosting • UK WW SEO Tools • Free site submission • Web Directory |
| Advertisement |
![]() |
| Site Of the Month |
![]() Nominate site of the month |
|
|
| UK Webmaster World Forums - Internet marketing, web development, domain names, SEO contest and discussuons. |
| Subscribe to our feeds |