php-windows Digest 31 Aug 2004 03:58:24 -0000 Issue 2376

Topics (messages 24463 through 24466):

Loading PHP Module
        24463 by: Takahiro_Horie.nidek.com
        24465 by: Takahiro_Horie.nidek.com

Re: File permissions in XP
        24464 by: Vail, Warren

interacting with Java or C
        24466 by: Ragnar

Administrivia:

To subscribe to the digest, e-mail:
        [EMAIL PROTECTED]

To unsubscribe from the digest, e-mail:
        [EMAIL PROTECTED]

To post to the list, e-mail:
        [EMAIL PROTECTED]


----------------------------------------------------------------------
--- Begin Message ---
(BHello,
(B
(BI'm trying to create custom PHP 5.0.1 extensions for Windows XP and Apache
(B2.0.50. I was able to compile a sample extension (from a tutorial written
(Bfor PHP 4). The article is
(Bhttp://www.devarticles.com/c/a/Cplusplus/Developing-Custom-PHP-Extensions-Part-1/
(B
(BI ran into the problem where dl() can't be used on a multithreaded server.
(BThat is OK.
(B
(BI added extension=php_devarticles_mod.dll to my php.ini file. I restarted
(BApache, and it gave me this error:
(B
(B    "PHP Startup: Invalid library (maybe not a PHP library)
(B'php_devarticlesmod.dll"
(B
(BI'm not sure what to do, or how to figure out what went wrong. Is there
(Bsome way of knowing what exactly caused the loading to fail?
(B
(BSource code for php_devarticlesmod.dll is below.
(B
(BThanks in advance!
(B----------------------------------------------------------------
(B
(B/* include standard header */
(B/* you will need to include this in all of your php extension projects*/
(B#include "php.h"
(B
(B/* All the functions that will be exported (available) must be declared */
(BZEND_FUNCTION(hello_world);
(BPHP_MINFO_FUNCTION(devarticlesmod);
(B
(B/* Just a basic int to be used as a counter*/
(Bint i;
(B
(B/* function list so that the Zend engine will know what$B!G(Bs here */
(Bzend_function_entry devarticlesmod_functions[] =
(B{
(BZEND_FE(hello_world, NULL)
(B{NULL, NULL, NULL}
(B};
(B
(B/* module information */
(Bzend_module_entry devarticlesmod_module_entry =
(B{ STANDARD_MODULE_HEADER,
(B"DevArticles",
(Bdevarticlesmod_functions,
(BNULL,
(BNULL,
(BNULL,
(BNULL,
(BPHP_MINFO(devarticlesmod),
(BNO_VERSION_YET,
(BSTANDARD_MODULE_PROPERTIES };
(B
(B#if COMPILE_DL_DEVARTICLES_MOD
(BZEND_GET_MODULE(devarticlesmod)
(B#endif
(B
(BPHP_MINFO_FUNCTION(devarticlesmod)
(B{
(Bphp_info_print_table_start();
(Bphp_info_print_table_row(2, "DevArticles Extension", "All Systems Go");
(Bphp_info_print_table_end();
(B}
(B
(BZEND_FUNCTION(hello_world)
(B{
(B
(Bfor(i=0;i<5;i++)
(B{
(Bzend_printf("Hello World<br>");
(B}
(B}

--- End Message ---
--- Begin Message ---
(BProblem solved.
(B
(BI found a discrepency in the source code I copied from the tutorial -
(Bcompletely my own typo.
(B
(B
(B
(B                                                                                       
(B                        
(B                    Takahiro_Horie                                                     
(B                        
(B                    @nidek.com            To:     [EMAIL PROTECTED]                    
(B                
(B                                          cc:                                          
(B                        
(B                    08/30/2004            Subject:     [PHP-WIN] Loading PHP Module    
(B                        
(B                    11:28 AM                                                           
(B                        
(B                                                                                       
(B                        
(B                                                                                       
(B                        
(B
(B
(B
(B
(BHello,
(B
(BI'm trying to create custom PHP 5.0.1 extensions for Windows XP and Apache
(B2.0.50. I was able to compile a sample extension (from a tutorial written
(Bfor PHP 4). The article is
(Bhttp://www.devarticles.com/c/a/Cplusplus/Developing-Custom-PHP-Extensions-Part-1/
(B
(B
(BI ran into the problem where dl() can't be used on a multithreaded server.
(BThat is OK.
(B
(BI added extension=php_devarticles_mod.dll to my php.ini file. I restarted
(BApache, and it gave me this error:
(B
(B    "PHP Startup: Invalid library (maybe not a PHP library)
(B'php_devarticlesmod.dll"
(B
(BI'm not sure what to do, or how to figure out what went wrong. Is there
(Bsome way of knowing what exactly caused the loading to fail?
(B
(BSource code for php_devarticlesmod.dll is below.
(B
(BThanks in advance!
(B----------------------------------------------------------------
(B
(B/* include standard header */
(B/* you will need to include this in all of your php extension projects*/
(B#include "php.h"
(B
(B/* All the functions that will be exported (available) must be declared */
(BZEND_FUNCTION(hello_world);
(BPHP_MINFO_FUNCTION(devarticlesmod);
(B
(B/* Just a basic int to be used as a counter*/
(Bint i;
(B
(B/* function list so that the Zend engine will know what$B!G(Bs here */
(Bzend_function_entry devarticlesmod_functions[] =
(B{
(BZEND_FE(hello_world, NULL)
(B{NULL, NULL, NULL}
(B};
(B
(B/* module information */
(Bzend_module_entry devarticlesmod_module_entry =
(B{ STANDARD_MODULE_HEADER,
(B"DevArticles",
(Bdevarticlesmod_functions,
(BNULL,
(BNULL,
(BNULL,
(BNULL,
(BPHP_MINFO(devarticlesmod),
(BNO_VERSION_YET,
(BSTANDARD_MODULE_PROPERTIES };
(B
(B#if COMPILE_DL_DEVARTICLES_MOD
(BZEND_GET_MODULE(devarticlesmod)
(B#endif
(B
(BPHP_MINFO_FUNCTION(devarticlesmod)
(B{
(Bphp_info_print_table_start();
(Bphp_info_print_table_row(2, "DevArticles Extension", "All Systems Go");
(Bphp_info_print_table_end();
(B}
(B
(BZEND_FUNCTION(hello_world)
(B{
(B
(Bfor(i=0;i<5;i++)
(B{
(Bzend_printf("Hello World<br>");
(B}
(B}
(B
(B--
(BPHP Windows Mailing List (http://www.php.net/)
(BTo unsubscribe, visit: http://www.php.net/unsub.php

--- End Message ---
--- Begin Message ---
Seems I had to disable inheriting permissions from parent directories and
then open up permissions on that directory and all it's children.  Now it
functions more like my Linux sites.  Thanks to all that helped.

Warren Vail


-----Original Message-----
From: Gryffyn, Trevor [mailto:[EMAIL PROTECTED] 
Sent: Monday, August 30, 2004 6:35 AM
To: [EMAIL PROTECTED]
Cc: Warren Vail
Subject: RE: [PHP-WIN] File permissions in XP


Couple of things to consider:

1. Are you logged in as administrator?  Or otherwise have permissions under
your current login to make those changes?

2. What file system are you using?  NTFS has more specific options for user
based permissions than FAT32 does.

3. Can you get your script to create files anywhere?   Is there a place
you can test the script itself to make sure that it functionsl properly?

Good luck!

-TG

> -----Original Message-----
> From: Warren Vail [mailto:[EMAIL PROTECTED]
> Sent: Saturday, August 28, 2004 2:08 AM
> To: [EMAIL PROTECTED]
> Subject: [PHP-WIN] File permissions in XP
> 
> 
> I can't figure out how to define permissions so that php
> scripts running
> under an apache server can create files in a directory.  When 
> I browse the
> directory with the explorer, I notice the read only attribute 
> is set and I
> can't seem to clear it in windows xp professional, even with 
> the dos attrib
> command.  I'm not sure this is related to my problem but it 
> seem logical to
> me.  What am I missing?
> 
> Warren Vail
> 

-- 
PHP Windows Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

--- End Message ---
--- Begin Message ---
Hi fellows,

I was just wondering, I have to get a project done that involves
online payment, which are handled through a payment gateway in the
UK.

Problem is the company only provides a Java or C alternative to interact
with the gateway.

Any idea how to make PHP talk to Java or C ?

Any clues appreciated.

Ben

-- 
Superg�nstige DSL-Tarife + WLAN-Router f�r 0,- EUR*
Jetzt zu GMX wechseln und sparen http://www.gmx.net/de/go/dsl

--- End Message ---

Reply via email to