[PHP-DEV] Extension debugging (stand alone extension)

2002-11-14 Thread Glenn MacGregor
Hi All, I have written an extension to php, it looks like it is crashin in a library call. Is there anyway to use gdb to debug this stuff? Thanks Glenn -- PHP Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP-DEV] extension 4.0.6 -> 4.2.2

2002-07-29 Thread Rasmus Lerdorf
HTTP_SERVER_VARS are still around On 29 Jul 2002, Robin Ericsson wrote: > Hi, > > > I'm began converting a module I wrote for 4.0.6, and I use this code: > > if ((zend_hash_find(&EG(symbol_table), "HTTP_SERVER_VARS", > sizeof("HTTP_SERVER_VARS"), (void **) &data) != FAILURE) && > Z_TYPE_PP(data)

[PHP-DEV] extension 4.0.6 -> 4.2.2

2002-07-28 Thread Robin Ericsson
Hi, I'm began converting a module I wrote for 4.0.6, and I use this code: if ((zend_hash_find(&EG(symbol_table), "HTTP_SERVER_VARS", sizeof("HTTP_SERVER_VARS"), (void **) &data) != FAILURE) && Z_TYPE_PP(data) == IS_ARRAY) In 4.2.x, I just change this to _SERVER, or is there another "fancier"

[PHP-DEV] extension problem

2002-07-04 Thread adel
hi I have an extension problem. i have wrote this exemple #include... char* xx(){ return "true"; } it's a simple example. I have compiled it into .SO dynamic library. when I try to load it into PHP i get this message cannot include .(may be not php extension). CAN YOU HELP ME PLEASE.

Re: [PHP-DEV] extension modules

2002-07-02 Thread Torsten Curdt
Thanks for the help guys! :-) -- Torsten -- PHP Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP-DEV] extension modules

2002-07-02 Thread Torsten Curdt
configure of php itself or the extension module? On Tuesday 02 July 2002 21:45, George Schlossnagle wrote: > Actually, if you run configure with > > --with-sqlanywhere=shared, that directive should be added to config.h > > On Tuesday, July 2, 2002, at 03:42 PM, Torsten Curdt wrote: > > On Tuesda

Re: [PHP-DEV] extension modules

2002-07-02 Thread George Schlossnagle
Actually, if you run configure with --with-sqlanywhere=shared, that directive should be added to config.h On Tuesday, July 2, 2002, at 03:42 PM, Torsten Curdt wrote: > On Tuesday 02 July 2002 21:31, George Schlossnagle wrote: >> You need to do a >> >> ZEND_GET_MODULE(modulename); >> >> in yor e

Re: [PHP-DEV] extension modules

2002-07-02 Thread Torsten Curdt
On Tuesday 02 July 2002 21:31, George Schlossnagle wrote: > You need to do a > > ZEND_GET_MODULE(modulename); > > in yor extension. That did it!! :-)) Thanks I found a #ifdef COMPILE_DL_SQLANYWHERE ZEND_GET_MODULE(sqlanywhere) #endif in the code. I only needed to removed the preprocessor instr

Re: [PHP-DEV] extension modules

2002-07-02 Thread George Schlossnagle
You need to do a ZEND_GET_MODULE(modulename); in yor extension. George On Tuesday, July 2, 2002, at 03:25 PM, Torsten Curdt wrote: > On Tuesday 02 July 2002 21:21, [EMAIL PROTECTED] wrote: >> On Tue, 2 Jul 2002, Torsten Curdt wrote: >>> Two simple questions: >>> >>> 1) Does the "core" (aka li

Re: [PHP-DEV] extension modules

2002-07-02 Thread derick
On Tue, 2 Jul 2002, Torsten Curdt wrote: [...] > Hm... but now I am back puzzled why I cannot load my self compiled extension > module. I always get: > > PHP Warning: Invalid library (maybe not a PHP library) '..' > > I thought I get this because it needs to be "registered" at compile time

Re: [PHP-DEV] extension modules

2002-07-02 Thread Torsten Curdt
On Tuesday 02 July 2002 21:21, [EMAIL PROTECTED] wrote: > On Tue, 2 Jul 2002, Torsten Curdt wrote: > > Two simple questions: > > > > 1) Does the "core" (aka libphp4.so) need to know about all possible > > extension modules at compilation time (--with-FOO=shared) in order to > > load a module? Or i

Re: [PHP-DEV] extension modules

2002-07-02 Thread derick
On Tue, 2 Jul 2002, Torsten Curdt wrote: > Two simple questions: > > 1) Does the "core" (aka libphp4.so) need to know about all possible extension > modules at compilation time (--with-FOO=shared) in order to load a module? Or > is it possible to just load any module that is compiled against t

[PHP-DEV] extension modules

2002-07-02 Thread Torsten Curdt
Two simple questions: 1) Does the "core" (aka libphp4.so) need to know about all possible extension modules at compilation time (--with-FOO=shared) in order to load a module? Or is it possible to just load any module that is compiled against the same php version? 2) When will extension module

Re: [PHP-DEV] Extension news: cryptopp

2002-05-03 Thread J Smith
I can definitely look into it, although I can't guarantee any results yet, as we're about to go back into heavy development of a new app at work (which uses the extension), but hopefully I'll get some free time to put towards it. I'll let you know how things are in two weeks or so; I should h

Re: [PHP-DEV] Extension news: cryptopp

2002-05-02 Thread derick
Hello, I read some of the documentation, and noticed that this API seems to be very usable for an abstraction to multiple encryption libraries. It even looks a lot like the API I had in mind for the revamped mcrypt extension. Would you be interested in figuring the best way to do it, so that w

[PHP-DEV] Extension news: cryptopp

2002-05-02 Thread J Smith
Just thought I'd give an update about the current status of the Crypto++ extension for PHP I've been working on the past month or two, called simply cryptopp. The extension is coming along rather nicely and is stablizing towards a solid release. I'd still consider the current releases of beta

Re: [PHP-DEV] Extension format (fwd)

2002-02-14 Thread Brad House
Umm, look at README.EXTENSIONS in the source distribution. Very explicit. RTFM ?! David Croft wrote: > Could someone please update me on what needs to be changed to make an > 4.0.6 extension function on 4.1.1? > > Thanks. > > -- - Brad House Sr. Developer Mai

[PHP-DEV] Extension format (fwd)

2002-02-14 Thread David Croft
Could someone please update me on what needs to be changed to make an 4.0.6 extension function on 4.1.1? Thanks. -- |> /+\ \| | |> David Croft Infotrek -- Forwarded message -- Date: Mon, 11 Feb 2002 18:21:19 -0500 (EST) From: David Croft <[EMAIL PROTECTED]> To: [EMAIL PROTECTE

[PHP-DEV] extension library versions (XSLT)

2002-01-25 Thread Florian Clever
Is there a way to detect from PHP what the version of the underlaying extension being used is? For example in the case of the XSLT/Slabtron extension: xslt_getLibInfo() which would then return an Array: $returnValue['lib'] = 'Sablot' $returnValue['version'] = '0.81' thanks, Florian http://fc

[PHP-DEV] extension

2002-01-25 Thread Vadim Tkachenko
Hello. I released extension for work with System V messages (IPC). If you want (need), i can post it in CVS or other place. With best regards, Vadim Tkachenko. -- PHP Development Mailing List To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [E

[PHP-DEV] Extension / calling require_once()

2001-11-18 Thread Andreas Aderhold
Hi There, can I call a "php-function" from inside a php extension? I mean simply doing a call to the ZE that does call the method that the php function/construct require_once() triggers. Would be very cool if this is possible. Andi -- PHP Development Mailing List To

Re: [PHP-DEV] Extension checkins?

2001-11-02 Thread Jonathan Gillette
On Thu, 1 Nov 2001 18:25:52 -0600, [EMAIL PROTECTED] (Matt McClanahan) wrote: > Mentioning what it does may be a good start.. I have been in communication with the developer for DbTcp [http://www.fastflow.it/dbftp/], a proxy server for Windows ODBC connections. I rely on PHP for production wor

Re: [PHP-DEV] Extension checkins?

2001-11-01 Thread Matt McClanahan
On Fri, Nov 02, 2001 at 12:11:17AM +, Jonathan Gillette wrote: > Hi. I'm aware of an extension that would fit quite nicely into the > current set. What's the protocol for proposing a entry into the > extension repository? Mentioning what it does may be a good start.. Matt -- PHP Develop

[PHP-DEV] Extension checkins?

2001-11-01 Thread Jonathan Gillette
Hi. I'm aware of an extension that would fit quite nicely into the current set. What's the protocol for proposing a entry into the extension repository? Thanks, Jonathan -- PHP Development Mailing List To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands,

Re: [PHP-DEV] extension not shutting down on each request

2001-07-25 Thread Stanislav Malyshev
GK>> It seems that on termination of a script the GK>> PHP_MSHUTDOWN_FUNCTION is not called. MSHUTDOWN is called on the module shutdown (i.e., engine shutdown), RSHUTDOWN - on the request end. GK>> However the doc at www.zend.com says : GK>> GK>> "... As dynamic loadable modules are loaded only

[PHP-DEV] extension not shutting down on each request

2001-07-25 Thread Gilles Koffmann
Hi, I'm working on an extension with PHP 4.06, VC++6 and doing OO syntax overloading. It seems that on termination of a script the PHP_MSHUTDOWN_FUNCTION is not called. However the doc at www.zend.com says : "... As dynamic loadable modules are loaded only on page requests, the request shutdow

[PHP-DEV] extension crashes on reload

2001-07-20 Thread Gilles Koffmann
Hi, I'm writing an extension to access Delphi, C++ builder and Kylix objects. PHP 4.0.6, Win98, VC++6 sp5 My extension crashes (page fault in Kernel32.dll) when I reload my script (2nde execution). What could cause this crash ? Thank's. Gilles -- PHP Development Mailing List

[PHP-DEV] Extension creation help

2001-07-16 Thread BREGERAS Olivier
Hi I devel. a PHP extension. I need global variable. So I define them between the 2 macro : ZEND_BEGIN_MODULE_GLOBALS and ZEND_END_MODULE_GLOBALS. I uncomment ZEND_DECLARE_MODULE_GLOBALS. I put this code in the ZEND_RINIT_FUNCTION : { MODELIXE_LS_FETCH(); MODELIXE_G(premier)=NUL

RE: [PHP-DEV] extension depending on extension?

2001-05-23 Thread James Moore
> Alright, so what I'm doing is wrapping two libraries from the > Jabber Project (http://www.jabber.org). The first is an > xmlnodes wrapper, similar to DOM but more internalized as > well as some other helper functions, the second is jabber > specific functionality. Here is where it gets t

[PHP-DEV] extension depending on extension?

2001-05-23 Thread temas
Alright, so what I'm doing is wrapping two libraries from the Jabber Project (http://www.jabber.org). The first is an xmlnodes wrapper, similar to DOM but more internalized as well as some other helper functions, the second is jabber specific functionality. Here is where it gets tricky, the xmln

Re: [PHP-DEV] extension/module versioning

2001-05-06 Thread Stig Sæther Bakken
[<[EMAIL PROTECTED]>] > dev team, > > what are the chances of having a function call for every extension that > returns the version? this would be extremely useful for determining > whether the correct version is installed, rather than checking to see > if the function_exists(). > > eg. > > $ve

Re: [PHP-DEV] extension/module versioning

2001-05-06 Thread Wez Furlong
On 2001-05-06 02:06:42, [EMAIL PROTECTED] wrote: > what are the chances of having a function call for every extension that > returns the version? this would be extremely useful for determining > whether the correct version is installed, rather than checking to see > if the function_exists(). > $ve

Re: [PHP-DEV] extension/module versioning

2001-05-05 Thread avi
On Sun, 6 May 2001, Anil Madhavapeddy wrote: hey anil, > Probably better to do something like this: > $version = get_extension_version('xml'); > to avoid cluttering the namespace with more functions. whatever it takes 8^) > Although, why not just use phpversion() ? because then you can't wri

Re: [PHP-DEV] extension/module versioning

2001-05-05 Thread Anil Madhavapeddy
[EMAIL PROTECTED] wrote: > > $version_id = xml_version(); > > or > > $version_id = ibase_version(); > Probably better to do something like this: $version = get_extension_version('xml'); to avoid cluttering the namespace with more functions. Although, why not just use phpversion() ? Extensions a

[PHP-DEV] extension/module versioning

2001-05-05 Thread avi
dev team, what are the chances of having a function call for every extension that returns the version? this would be extremely useful for determining whether the correct version is installed, rather than checking to see if the function_exists(). eg. $version_id = xml_version(); or $version_i

Re: [PHP-DEV] Extension help

2001-03-20 Thread Sterling Hughes
On Tue, 20 Mar 2001, Barry Mitchelson wrote: > ok, I have managed to add a member variable, but am having problems when i try to >retreive it using zend_find_hash > > here's the code : > > for the extension : > > PHP_FUNCTION(create_object) > { > > ... other stuff > > add_proper

Re: [PHP-DEV] Extension help

2001-03-20 Thread Barry Mitchelson
On Tue, Mar 20, 2001 at 06:48:39PM +0200, Stanislav Malyshev wrote: > BM>> is there full documentation of the Zend API - i found the stuff > BM>> on the zend website to be useful, but didn't cover everything. > > Well, that's the most full one that exists. Eventually, it should be > extended to c

Re: [PHP-DEV] Extension help && mailing list???

2001-03-20 Thread Stanislav Malyshev
MB>> > If there is, I couldn't find it either. The docs are at http://www.zend.com/apidoc/ -- Stanislav Malyshev, Zend Products Engineer [EMAIL PROTECTED] http://www.zend.com/ +972-3-6139665 ext.115 -- PHP Development Mailing List To unsubscribe, e-mail: [EMAIL PROTEC

Re: [PHP-DEV] Extension help

2001-03-20 Thread Stanislav Malyshev
BM>> is there full documentation of the Zend API - i found the stuff BM>> on the zend website to be useful, but didn't cover everything. Well, that's the most full one that exists. Eventually, it should be extended to cover the most, but before it happnes, you have the code and the PHP-DEV... --

Re: [PHP-DEV] Extension help

2001-03-20 Thread Barry Mitchelson
On Tue, Mar 20, 2001 at 05:15:58PM +0100, Marc Boeren wrote: > > >BTW, (*tmpString)->value.str.val == Z_STRVAL_PP(tmpString) but the > >latter looks much nicer :) > > Granted, but that's what happens if you just examine the code and don't read > the documentation :-) is there full documentation

[PHP-DEV] Extension help && mailing list???

2001-03-20 Thread Marc Boeren
> >is there full documentation of the Zend API - i found the stuff on the > zend website to be useful, but didn't cover everything. > > If there is, I couldn't find it either. > So it's that and the source code itself. > > If anyone knows about more documentation, could someone put it up (or

RE: [PHP-DEV] Extension help

2001-03-20 Thread Marc Boeren
>BTW, (*tmpString)->value.str.val == Z_STRVAL_PP(tmpString) but the >latter looks much nicer :) Granted, but that's what happens if you just examine the code and don't read the documentation :-) Cheerio, Marc. -- PHP Development Mailing List To unsubscribe, e-mail: [EMAI

Re: [PHP-DEV] Extension help

2001-03-20 Thread Stanislav Malyshev
BM>> > but I may be wrong on the level of indirection. BM>> > The zval cannot automagically be put in a %s and treated as a string, you BM>> > should manually extract the pointer to the actual string. BM>> BM>> even though i did convert_to_string_ex(tmpString) ? The convert_to_string_ex makes tmp

Re: [PHP-DEV] Extension help

2001-03-20 Thread Andrei Zmievski
On Tue, 20 Mar 2001, Stanislav Malyshev wrote: > MB>> zend_printf("foo = %s", (*tmpString)->value.str.val); > > BTW, (*tmpString)->value.str.val == Z_STRVAL_PP(tmpString) but the > latter looks much nicer :) And much like Perl but not quite that bad yet.. :)) -Andrei * Life may be expensive, bu

RE: [PHP-DEV] Extension help

2001-03-20 Thread Stanislav Malyshev
MB>> zend_printf("foo = %s", (*tmpString)->value.str.val); BTW, (*tmpString)->value.str.val == Z_STRVAL_PP(tmpString) but the latter looks much nicer :) -- Stanislav Malyshev, Zend Products Engineer [EMAIL PROTECTED] http://www.zend.com/ +972-3-6139665 ext.115 -- PHP Development Mailing Li

RE: [PHP-DEV] Extension help

2001-03-20 Thread Marc Boeren
> Hi! > > >even though i did convert_to_string_ex(tmpString) ? > You should still do that, but the only thing that really does is set the zval type to IS_STRING, and the value union is set accordingly (instead of e.g. a long in value.lval, you get the value as a string in value.str.val (and the

Re: [PHP-DEV] Extension help

2001-03-20 Thread Barry Mitchelson
On Tue, Mar 20, 2001 at 03:59:29PM +0100, Marc Boeren wrote: > > >> You're almost correct, sizeof("foo") should be sizeof("foo")+1 > > >hmm... still not working :( > > My fault for not reading on beyond the first typo: > > >zend_printf("foo = %s",tmpString); > > should probably be > > zend_p

RE: [PHP-DEV] Extension help

2001-03-20 Thread Marc Boeren
>> You're almost correct, sizeof("foo") should be sizeof("foo")+1 >hmm... still not working :( My fault for not reading on beyond the first typo: >zend_printf("foo = %s",tmpString); should probably be zend_printf("foo = %s", (*tmpString)->value.str.val); but I may be wrong on the level of i

Re: [PHP-DEV] Extension help

2001-03-20 Thread Barry Mitchelson
On Tue, Mar 20, 2001 at 03:24:00PM +0100, Marc Boeren wrote: > > > >zend_hash_find(obj->value.obj.properties,"foo",sizeof("foo"),(void**)&tmpSt > ring); > > You're almost correct, sizeof("foo") should be sizeof("foo")+1 hmm... still not working :( > > Cheerio, Marc. > > -- > PHP Developmen

RE: [PHP-DEV] Extension help

2001-03-20 Thread Marc Boeren
>zend_hash_find(obj->value.obj.properties,"foo",sizeof("foo"),(void**)&tmpSt ring); You're almost correct, sizeof("foo") should be sizeof("foo")+1 Cheerio, Marc. -- PHP Development Mailing List To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [

Re: [PHP-DEV] Extension help

2001-03-20 Thread Barry Mitchelson
ok, I have managed to add a member variable, but am having problems when i try to retreive it using zend_find_hash here's the code : for the extension : PHP_FUNCTION(create_object) { ... other stuff add_property_string(return_value,"foo","hello!",1); ... other stuff

Re: [PHP-DEV] Extension help

2001-03-19 Thread Sterling Hughes
On Mon, 19 Mar 2001, Barry Mitchelson wrote: > hey, > > I'm writing an extension which defines a class. In the constructor, I'd like to >create a member variable which I can then access with the other member functions in >my extension. > > In php it would be like : > > class foo > { > >

[PHP-DEV] Extension help

2001-03-19 Thread Barry Mitchelson
hey, I'm writing an extension which defines a class. In the constructor, I'd like to create a member variable which I can then access with the other member functions in my extension. In php it would be like : class foo { var $m_bar; function foo() {

[PHP-DEV] Extension Security

2001-03-15 Thread clayton collie
im writing an extension to provide shared memory and memory mapped file support to Windows. the latter, however raises the possibility for abuse. how can i, in an extension, ensure that access is limited to files under the user's virtual directory root ? id hate to have someone mapping to \IO.S

[PHP-DEV] extension developer list?

2001-03-08 Thread Marc Boeren
Hi! I for one wouldn't mind a separate mailing list for developers of php extensions. I would subscribe to both the php-dev and php-ext (?) mailing-lists, so I would still receive the same amount of mail, but the mails about extending php wouldn't be cluttered by bug reports or discussions abou