]> granicus.if.org Git - php/commitdiff
Update function names for PHP6 to php6*
authorUwe Schindler <thetaphi@php.net>
Tue, 6 Mar 2007 19:47:12 +0000 (19:47 +0000)
committerUwe Schindler <thetaphi@php.net>
Tue, 6 Mar 2007 19:47:12 +0000 (19:47 +0000)
sapi/nsapi/nsapi-readme.txt
sapi/nsapi/nsapi.c

index 54980bf0e0d8effd41676f009c09f21f5e60ae47..3b54a979bc0f6d63c97feae2639f652203b35442 100644 (file)
@@ -1,4 +1,4 @@
-Configuration of your Netscape/iPlanet/Sun Webserver for PHP5
+Configuration of your Netscape/iPlanet/Sun Webserver for PHP6
 -----------------------------------------------------------------
 
 These instructions are targetted at Netscape Enterprise Web Server and
@@ -28,13 +28,13 @@ Place the following two lines after mime.types init in
 for iPlanet/Sun Webserver 6.0 and above however at the end of the
 <path-to-server>/https-servername/config/magnus.conf file:
 
-    Init fn="load-modules" funcs="php5_init,php5_execute,php5_auth_trans" shlib="/path/to/phplibrary"
-    Init fn=php5_init errorString="Failed to initialize PHP!" [php_ini="/path/to/php.ini"]
+    Init fn="load-modules" funcs="php6_init,php6_execute,php6_auth_trans" shlib="/path/to/phplibrary"
+    Init fn=php6_init errorString="Failed to initialize PHP!" [php_ini="/path/to/php.ini"]
 
 The "shlib" will vary depending on your OS:
 
-       Unix: "<path-to-server>/bin/libphp5.so".
-       Windows: "c:/path/to/php5/php5nsapi.dll"
+       Unix: "<path-to-server>/bin/libphp6.so".
+       Windows: "c:/path/to/php6/php6nsapi.dll"
 
 
 In obj.conf (for virtual server classes [Sun 6.0+] in their vserver.obj.conf):
@@ -50,7 +50,7 @@ In obj.conf (for virtual server classes [Sun 6.0+] in their vserver.obj.conf):
     # For boolean ini-keys please use 0/1 as value, NOT "On","Off",... (this will not work
     # correctly), e.g. zlib.output_compression=1 instead of zlib.output_compression="On"
 
-    Service fn="php5_execute" type="magnus-internal/x-httpd-php" [inikey=value ...]
+    Service fn="php6_execute" type="magnus-internal/x-httpd-php" [inikey=value ...]
     .
     .
     .
@@ -61,7 +61,7 @@ PHP scripts (same like a cgi-bin directory):
 
     <Object name="x-httpd-php">
     ObjectType fn="force-type" type="magnus-internal/x-httpd-php"
-    Service fn="php5_execute" [inikey=value ...]
+    Service fn="php6_execute" [inikey=value ...]
     </Object>
 
 After that you can configure a directory in the Administration server and assign it
@@ -81,7 +81,7 @@ AUTHENTICATION IS PASSED TO YOUR PHP SCRIPT.  To configure PHP
 Authentication for the entire server, add the following line:
 
     <Object name="default">
-    AuthTrans fn=php5_auth_trans
+    AuthTrans fn=php6_auth_trans
     .
     .
     .
@@ -92,7 +92,7 @@ Authentication for the entire server, add the following line:
 To use PHP Authentication on a single directory, add the following:
 
     <Object ppath="d:\path\to\authenticated\dir\*">
-    AuthTrans fn=php5_auth_trans
+    AuthTrans fn=php6_auth_trans
     </Object>
 
 
@@ -103,7 +103,7 @@ You can use PHP to generate the error pages for "404 Not Found"
 or similar. Add the following line to the object in obj.conf for
 every error page you want to overwrite:
 
-    Error fn="php5_execute" code=XXX script="/path/to/script.php" [inikey=value inikey=value...]
+    Error fn="php6_execute" code=XXX script="/path/to/script.php" [inikey=value inikey=value...]
 
 where XXX ist the HTTP error code. Please delete any other Error
 directives which could interfere with yours.
@@ -116,7 +116,7 @@ Just generate a PHP script which displays a directory listing and
 replace the corresponding default Service line for
 type="magnus-internal/directory" in obj.conf with the following:
 
-    Service fn="php5_execute" type="magnus-internal/directory" script="/path/to/script.php" [inikey=value inikey=value...]
+    Service fn="php6_execute" type="magnus-internal/directory" script="/path/to/script.php" [inikey=value inikey=value...]
 
 For both error and directory listing pages the original URI and
 translated URI are in the variables $_SERVER['PATH_INFO'] and
@@ -141,9 +141,9 @@ till version 6.1. If a newer version of the Sun server is used, the detection
 fails and nsapi_virtual() is disabled.
 
 If this is the case, try the following:
-Add the following parameter to php5_init in magnus.conf:
+Add the following parameter to php6_init in magnus.conf:
 
-    Init fn=php5_init ... server_lib="ns-httpdXX.dll"
+    Init fn=php6_init ... server_lib="ns-httpdXX.dll"
     
 where XX is the correct DLL version number. To get it, look in the server-root
 for the correct DLL name. The DLL with the biggest filesize is the right one.
index 65604569e5460822df1279dcacc932c43a836f25..67f1eedbbd968e3f05dfad791f470af3b676f39f 100644 (file)
@@ -1,6 +1,6 @@
 /*
    +----------------------------------------------------------------------+
-   | PHP Version 5                                                        |
+   | PHP Version 6                                                        |
    +----------------------------------------------------------------------+
    | Copyright (c) 1997-2007 The PHP Group                                |
    +----------------------------------------------------------------------+
@@ -246,7 +246,7 @@ static void php_nsapi_init_dynamic_symbols(void)
                /* try user specified server_lib */
                module = GetModuleHandle(nsapi_dll);
                if (!module) {
-                       log_error(LOG_WARN, "php5_init", NULL, NULL, "Cannot find DLL specified by server_lib parameter: %s", nsapi_dll);
+                       log_error(LOG_WARN, "php6_init", NULL, NULL, "Cannot find DLL specified by server_lib parameter: %s", nsapi_dll);
                }
        } else {
                /* find a LOADED dll module from nsapi_dlls */
@@ -783,7 +783,7 @@ static void nsapi_php_ini_entries(NSLS_D TSRMLS_DC)
        }
 }
 
-void NSAPI_PUBLIC php5_close(void *vparam)
+void NSAPI_PUBLIC php6_close(void *vparam)
 {
        if (nsapi_sapi_module.shutdown) {
                nsapi_sapi_module.shutdown(&nsapi_sapi_module);
@@ -802,13 +802,13 @@ void NSAPI_PUBLIC php5_close(void *vparam)
 
        tsrm_shutdown();
 
-       log_error(LOG_INFORM, "php5_close", NULL, NULL, "Shutdown PHP Module");
+       log_error(LOG_INFORM, "php6_close", NULL, NULL, "Shutdown PHP Module");
 }
 
 /*********************************************************
 / init SAF
 /
-/ Init fn="php5_init" [php_ini="/path/to/php.ini"] [server_lib="ns-httpdXX.dll"]
+/ Init fn="php6_init" [php_ini="/path/to/php.ini"] [server_lib="ns-httpdXX.dll"]
 /   Initialize the NSAPI module in magnus.conf
 /
 / php_ini: gives path to php.ini file
@@ -816,7 +816,7 @@ void NSAPI_PUBLIC php5_close(void *vparam)
 /  servact_* functions
 /
 /*********************************************************/
-int NSAPI_PUBLIC php5_init(pblock *pb, Session *sn, Request *rq)
+int NSAPI_PUBLIC php6_init(pblock *pb, Session *sn, Request *rq)
 {
        php_core_globals *core_globals;
        char *strval;
@@ -833,13 +833,13 @@ int NSAPI_PUBLIC php5_init(pblock *pb, Session *sn, Request *rq)
 
        core_globals = ts_resource(core_globals_id);
 
-       /* look if php_ini parameter is given to php5_init */
+       /* look if php_ini parameter is given to php6_init */
        if (strval = pblock_findval("php_ini", pb)) {
                nsapi_sapi_module.php_ini_path_override = strdup(strval);
        }
        
 #ifdef PHP_WIN32
-       /* look if server_lib parameter is given to php5_init
+       /* look if server_lib parameter is given to php6_init
         * (this disables the automatic search for the newest ns-httpdXX.dll) */
        if (strval = pblock_findval("server_lib", pb)) {
                nsapi_dll = strdup(strval);
@@ -850,7 +850,7 @@ int NSAPI_PUBLIC php5_init(pblock *pb, Session *sn, Request *rq)
        sapi_startup(&nsapi_sapi_module);
        nsapi_sapi_module.startup(&nsapi_sapi_module);
 
-       daemon_atrestart(&php5_close, NULL);
+       daemon_atrestart(&php6_close, NULL);
 
        log_error(LOG_INFORM, pblock_findval("fn", pb), sn, rq, "Initialized PHP Module (%d threads exspected)", threads);
        return REQ_PROCEED;
@@ -859,19 +859,19 @@ int NSAPI_PUBLIC php5_init(pblock *pb, Session *sn, Request *rq)
 /*********************************************************
 / normal use in Service directive:
 /
-/ Service fn="php5_execute" type=... method=... [inikey=inivalue inikey=inivalue...]
+/ Service fn="php6_execute" type=... method=... [inikey=inivalue inikey=inivalue...]
 /
 / use in Service for a directory to supply a php-made directory listing instead of server default:
 /
-/ Service fn="php5_execute" type="magnus-internal/directory" script="/path/to/script.php" [inikey=inivalue inikey=inivalue...]
+/ Service fn="php6_execute" type="magnus-internal/directory" script="/path/to/script.php" [inikey=inivalue inikey=inivalue...]
 /
 / use in Error SAF to display php script as error page:
 /
-/ Error fn="php5_execute" code=XXX script="/path/to/script.php" [inikey=inivalue inikey=inivalue...]
-/ Error fn="php5_execute" reason="Reason" script="/path/to/script.php" [inikey=inivalue inikey=inivalue...]
+/ Error fn="php6_execute" code=XXX script="/path/to/script.php" [inikey=inivalue inikey=inivalue...]
+/ Error fn="php6_execute" reason="Reason" script="/path/to/script.php" [inikey=inivalue inikey=inivalue...]
 /
 /*********************************************************/
-int NSAPI_PUBLIC php5_execute(pblock *pb, Session *sn, Request *rq)
+int NSAPI_PUBLIC php6_execute(pblock *pb, Session *sn, Request *rq)
 {
        int retval;
        nsapi_request_context *request_context;
@@ -994,15 +994,15 @@ int NSAPI_PUBLIC php5_execute(pblock *pb, Session *sn, Request *rq)
 / will pass authentication through to php, and allow us to
 / check authentication with our scripts.
 /
-/ php5_auth_trans
+/ php6_auth_trans
 /   main function called from netscape server to authenticate
 /   a line in obj.conf:
-/              funcs=php5_auth_trans shlib="path/to/this/phpnsapi.dll"
+/              funcs=php6_auth_trans shlib="path/to/this/phpnsapi.dll"
 /      and:
 /              <Object ppath="path/to/be/authenticated/by/php/*">
-/              AuthTrans fn="php5_auth_trans"
+/              AuthTrans fn="php6_auth_trans"
 /*********************************************************/
-int NSAPI_PUBLIC php5_auth_trans(pblock * pb, Session * sn, Request * rq)
+int NSAPI_PUBLIC php6_auth_trans(pblock * pb, Session * sn, Request * rq)
 {
        /* This is a DO NOTHING function that allows authentication
         * information