Sara Golemon wrote:
I ran a simple
./configure --with-apxs2=/usr/bin/apxs2 --with-mysql=/usr/local/mysql
--with-mysqli=/usr/local/mysql/bin/mysql_config --with-zlib --with-gd
This'll build 'em staticly into a new mod_php5.so, but you want just the
extension so you can plug it into your exis
Hi Marcus,
I'm very well aware of this. But to me, optimizing code to win CPU-cycles is
one of the great pleasures I have in programming :). So I am and was fully
aware that what I submitted here were probably those less interesting 90% of
code that isn't used all the time. But I still enjoy findi
Slackers that don't write their own books are the worst!
LOL, I couldnt agree more! :-D
Regards
Mark
--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php
Hi Sara
The short answer is: call php_request_shutdown(NULL); to kill the active
interpreter (one is started implicitly by PHP_EMBED_START_BLOCK(), then
php_request_startup(TSRMLS_C); to initialize a new one (the last one active
at PHP_EMBED_END_BLOCK() will be impliticly shutdown).
Great many
Hello,
I have made an unaccepted php_embed extension available at
http://www.badcode.be/~descript/PHP/php_embed/
Take a look at the example :
http://www.badcode.be/~descript/PHP/php_embed/examples/pembed_new.c
I use this part of code on my software with C++
If you have questions ...
Michael
-
Slackers that don't write their own books are the worst!
Wez Furlong wrote:
I heard something similar; lazy bums the lot of 'em.
--Wez.
On 3/14/06, George Schlossnagle <[EMAIL PROTECTED]> wrote:
Sara Golemon wrote:
Originally George and Wez were going to be writing this book (and may yet do
I heard something similar; lazy bums the lot of 'em.
--Wez.
On 3/14/06, George Schlossnagle <[EMAIL PROTECTED]> wrote:
> Sara Golemon wrote:
>
> >
> >Originally George and Wez were going to be writing this book (and may yet do
> >their own version -- that's up to them). Due to innocuous reasons
> I ran a simple
> ./configure --with-apxs2=/usr/bin/apxs2 --with-mysql=/usr/local/mysql
> --with-mysqli=/usr/local/mysql/bin/mysql_config --with-zlib --with-gd
>
This'll build 'em staticly into a new mod_php5.so, but you want just the
extension so you can plug it into your existing webserver b
Hi,
I have been lurking on this list for a while, and this is my first
post. Sorry it has to be such a daft question. I don't even know if
it's the right list, so my apologies in advance.
I need to add mysqli support to a web server and our sys admin refuses
to do anything unless it co
Sara Golemon wrote:
Originally George and Wez were going to be writing this book (and may yet do
their own version -- that's up to them). Due to innocuous reasons that I
can probably talk about but won't to be on the safe side, I wound up taking
over the project (and the ISBN number along with
Hello Ron,
the first rule about optimizing is the 80-20 or 90-10 rule or whatever
you like more. Either way the idea is that the program spends more than
90% of it's run-time in less than 10% of it's functions. This is a very
general idea but nontheless has proven right since people program. On
> > > Is this the right book as it has a publish date of March 2005.
> >
> > Extending and Embedding PHP (Paperback)
> > by Sara Golemon
> >
> > * Paperback: 448 pages
> > * Publisher: Sams (May 24, 2006)
> > * Language: English
> > * ISBN: 067232704X
> >
> it's pretty strange. at amazon.com the
Mark Evans wrote:
Is this the right book as it has a publish date of March 2005.
Hmm, it seems that amazon.co.uk are confused :-)
Searching amazon.com gives me
Extending and Embedding PHP (Paperback)
by Sara Golemon
* Paperback: 448 pages
* Publisher: Sams (May 24, 2006)
* Language: English
Is this the right book as it has a publish date of March 2005.
Hmm, it seems that amazon.co.uk are confused :-)
Searching amazon.com gives me
Extending and Embedding PHP (Paperback)
by Sara Golemon
* Paperback: 448 pages
* Publisher: Sams (May 24, 2006)
* Language: English
* ISBN: 067232704X
you might get Sara Golemon's not yet released book (ISBN: 067232704X) about
"Extending and Embedding PHP"
I just did a search on Amazon for the above ISBN and it returned a book
as follows
Extending and Embedding PHP - Wez Furlong, George Schlossnagle
Paperback 448 pages (March 2005)
Publishe
Brian Moon wrote:
Oh, you want an operator to do that? Does some other language have
this that we are wanting to copy here?
IIRC C# 3.0 adds a new operator ?: written as "foo = bar ?: 'default
value';". I tried to search a resource with some documentation about
this new operator, but Goog
But you still don't have a default value, just an empty default
value(string, zero, etc.). You can't i.e. initialize $_GET["ConfirmCode"]
with "Yes" using settype...
Oh, you want an operator to do that? Does some other language have this
that we are wanting to copy here? Seems overly complica
To Jay Smith, Marcus Boerger, George Schlossnagle,
Sara Golemon, Michael Walter in particular, and all
who've kindly responded to my struggle to upgrade my
C++ to handle my hopes on php, thank you.
We now have a C++ class factory for generating Php objects
derived from C++ classes, as I'd original
If you want an example of doing request startup/shutdown multithreaded
with the embed SAPI and are willing to wade through a bit of XS, you can
check out the PHP::Interpreter Perl module (on CPAN:
http://search.cpan.org/dist/PHP-Interpreter/). That links against the
embed SAPI but uses the nat
Here one can't say much without any details (_relevant_ code and backtrace)
php_embed_* are afaik wrapping up the complete engine und request init and
shutdown. If you want to do multiple independent requests you should take an
a bit closer look on the SAPI layer to use the functions I mentione
Johannes Schlueter wrote:
Hi Mark,
On Tuesday 14 March 2006 20:48, Marco wrote:
Is there a way from within the embedded system to destroy all created
variables so that the environment is the same as when it was started or do
we need to shutdown the embedded engine and start it up again?
Hi Mark,
On Tuesday 14 March 2006 20:48, Marco wrote:
> Is there a way from within the embedded system to destroy all created
> variables so that the environment is the same as when it was started or do
> we need to shutdown the embedded engine and start it up again?
PHP was designed as an langua
Brian Moon wrote:
>>> $ConfirmCode = (isset($_GET['ConfirmCode']) ? $_GET['ConfirmCode'] :
>>> '');
>> I agree that this is really a PITA, but until we get an operator for
>> this, we should stuck on the ternary.
>
>
> Another option is to use settype(); This has two advantages. One, if
>
How much C++ programming have you done previously?
-Andrei
On Mar 14, 2006, at 10:45 AM, Andrew Mather (BT Std) wrote:
Is it possible to pass a C++ member function to the create_object
member in
zend_class_entry ?
This would allow a factory-like generator of zend/c++ object pairs.
error:
Hi All
The company I am doing some work for is currently using the php_embed to
access the php engine from within a windows based c++ application.
I have been asked a question that I dont know the answer to and all my
googling attempts have failed.
Is there a way from within the embedded system
Is it possible to pass a C++ member function to the create_object member in
zend_class_entry ?
This would allow a factory-like generator of zend/c++ object pairs.
error: argument of type `
zend_object_value (MyClassFactory::)(zend_class_entry*, void***)' does
not match `zend_object_value
Should I have opened a BUG report instead ? It's just an one line patch...
Let me know if I need to open a BUG report.
Regards,
Cristiano Duarte
--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php
On Tue, 14 Mar 2006 07:32:15 -0800
[EMAIL PROTECTED] (Andi Gutmans) wrote:
> Yeah that sounds good. Maybe change UPDATE to UPDATING
First draft commited in:
php-src / README.UPDATING_TO_PHP6
--Pierre
--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.ph
> -Original Message-
> From: Jochem Maas [mailto:[EMAIL PROTECTED]
> Sent: Tuesday, March 14, 2006 6:03 PM
> To: Dmitry Stogov
> Cc: 'Ron Korving'; internals@lists.php.net
> Subject: Re: [PHP-DEV] Re: Calling performance geeks
>
>
> Dmitry Stogov wrote:
> > Php.ini is parsed only on php
On 3/14/06, Andi Gutmans <[EMAIL PROTECTED]> wrote:
> That's obviously not what I meant... but I've been in situations
> where there were LANs which were inaccessible by outside sources...
Do you know that most of the security or attacks problems come from
coworkers? :)
--Pierre
--
PHP Internal
That's obviously not what I meant... but I've been in situations
where there were LANs which were inaccessible by outside sources...
Never mind.. Not worth the discussion :)
Andi
At 07:35 AM 3/14/2006, Rasmus Lerdorf wrote:
Andi Gutmans wrote:
At 07:13 AM 3/14/2006, Pierre wrote:
Intranet a
Andi Gutmans wrote:
At 07:13 AM 3/14/2006, Pierre wrote:
Intranet apps does not need to be secure? That's new to me.
Depends what it is. A lot have to be secure, but some don't. For
example, some apps are on local networks (for example a group Wiki),
which are inaccessible outside a specific
On 3/14/06, Pierre <[EMAIL PROTECTED]> wrote:
> On 3/14/06, Andi Gutmans <[EMAIL PROTECTED]> wrote:
>
> > >We agree on that, yes. I was even in the first to ask for migration
> > >docs. However a migration doc is not supposed to document how to keep
> > >doing things badly.
> >
> > Well at least do
Yeah that sounds good. Maybe change UPDATE to UPDATING
Thanks!
At 07:30 AM 3/14/2006, Pierre wrote:
On 3/14/06, Andi Gutmans <[EMAIL PROTECTED]> wrote:
> >We agree on that, yes. I was even in the first to ask for migration
> >docs. However a migration doc is not supposed to document how to kee
On 3/14/06, Andi Gutmans <[EMAIL PROTECTED]> wrote:
> >We agree on that, yes. I was even in the first to ask for migration
> >docs. However a migration doc is not supposed to document how to keep
> >doing things badly.
>
> Well at least document the first part and I'll make sure the second
> happe
At 07:13 AM 3/14/2006, Pierre wrote:
On 3/14/06, Andi Gutmans <[EMAIL PROTECTED]> wrote:
> At 06:28 AM 3/14/2006, Pierre wrote:
> >On 3/14/06, Andi Gutmans <[EMAIL PROTECTED]> wrote:
> > > Pierre and all,
> > >
> > > A while ago I suggested to add an UPGRADING file for the PHP 6
> > > upgrade, wh
On 3/14/06, Andi Gutmans <[EMAIL PROTECTED]> wrote:
> At 06:28 AM 3/14/2006, Pierre wrote:
> >On 3/14/06, Andi Gutmans <[EMAIL PROTECTED]> wrote:
> > > Pierre and all,
> > >
> > > A while ago I suggested to add an UPGRADING file for the PHP 6
> > > upgrade, where we'd document every time we break B
$ConfirmCode = (isset($_GET['ConfirmCode']) ? $_GET['ConfirmCode'] :
'');
I agree that this is really a PITA, but until we get an operator for this,
we should stuck on the ternary.
Another option is to use settype(); This has two advantages. One, if
the variable does not exist, settype
Dmitry Stogov wrote:
Php.ini is parsed only on php startup (not on each request).
So this improvement will not give to much.
er - forgive me if what I say is stupid but if php is being pun as a CGI
isn't startup overhead incurred on each and every request?
also given the proliferation of shar
At 06:28 AM 3/14/2006, Pierre wrote:
On 3/14/06, Andi Gutmans <[EMAIL PROTECTED]> wrote:
> Pierre and all,
>
> A while ago I suggested to add an UPGRADING file for the PHP 6
> upgrade, where we'd document every time we break BC and how to solve
> that. For example, with nuking register_globals we
On 3/14/06, Andi Gutmans <[EMAIL PROTECTED]> wrote:
> Pierre and all,
>
> A while ago I suggested to add an UPGRADING file for the PHP 6
> upgrade, where we'd document every time we break BC and how to solve
> that. For example, with nuking register_globals we could write what
> we broke, and if re
Jason Garber wrote:
> Hello internals,
>
> Since nobody could seem to agree on a language construct for
> accessing a variable that you don't know exists (ifsetor),
> I would like to propose a simpler approach.
>
> It returns the value of the passed variable, or NULL if the variable
>
Php.ini is parsed only on php startup (not on each request).
So this improvement will not give to much.
Dmitry.
> -Original Message-
> From: Ron Korving [mailto:[EMAIL PROTECTED]
> Sent: Tuesday, March 14, 2006 2:49 PM
> To: internals@lists.php.net
> Subject: Re: [PHP-DEV] Re: Calling pe
Thanks for the info. I do have a Linux box, but that one needs uptime. I'll
need a new one I can screw up while developing on it. I think I'll buy me
one soon, so I can do these kind of things in the future.
Thanks again,
Ron
"Rasmus Lerdorf" <[EMAIL PROTECTED]> schreef in bericht
news:[EMAIL
It's probably not measurable, but a lot of small improvements like these may
be measurable. I don't know how often this situation occurs per request, but
if it happens for all apache config flags and php.ini flags, it may be worth
improving. If an improvement is not measurable per request (but i
Ron Korving wrote:
Oh right, okay. For a moment I thought you were talking about a
variable-length case insensitive string compare based on this principle :)
Your macro seems like a good idea to me. The function I was talking about
was an apache-flag checking function, not php.ini, but I guess
Oh right, okay. For a moment I thought you were talking about a
variable-length case insensitive string compare based on this principle :)
Your macro seems like a good idea to me. The function I was talking about
was an apache-flag checking function, not php.ini, but I guess this could
just as
#define INI_IS_TRUE(str) \
(((str)[0] == 'O' || ((str)[0] == 'o') && \
(str)[1] == 'N' || ((str)[1] == 'n') && \
(ste)[2] == 0)) || \
(str[0] == '1' && str[1] == 0))
But it make sense only if it really gives speedup.
Dmitry.
> -Original Message-
> Fro
Ron Korving wrote:
If this is possible, like Dmitry said, with a macro, that would be
interesting. I'm curious what this macro would look like. Personally, I tend
to go for the less readable solution if the performance advantage is
definately there. A little comment to the code should always be
I could be missing the point (only skimmed your mail), but you need to
include your template implementation in every source file that tries
to instantiate the template, e.g. by adding the code to the header
file (the alternative, that is, explicitely instantiating the template
in factory.cpp, would
Someone upgrading from 4.4 to 6.0 would then have to work through a ton of
guides obviously. I guess there may be something that get reverted in
between (like E_STRICT on var), but those should be rare. There could of
course be improvements to changes or ease previous BC breaks. So of course
th
Where would you want to start UPGRADING from?
I think realistically to keep the work somewhat manageable we should focus
on providing disjunct steps.
4.4 -> 5.0
5.0 -> 5.1
..
5.y -> 6.0
If we find we have more resources to invest into this, we can inline some
of the hints from previous guid
Lukas Smith wrote:
Steph Fox wrote:
Where would you want to start UPGRADING from?
The main problem I faced with the 5.1.0 version was not knowing how
far back to go... or what to count 'in'. E.g. something that was only
in CVS for a few weeks and no releases - should that be included?
Needs
Steph Fox wrote:
Where would you want to start UPGRADING from?
The main problem I faced with the 5.1.0 version was not knowing how far
back to go... or what to count 'in'. E.g. something that was only in CVS
for a few weeks and no releases - should that be included?
Needs some thought for 6.
54 matches
Mail list logo