Re: [PHP-DEV] call_stack

2002-11-27 Thread Brad Fisher
Andi Gutmans wrote: At 03:41 PM 11/27/2002 +0100, Derick Rethans wrote: On Wed, 27 Nov 2002, Miham KEREKES wrote: Hi! I'm new to this list, I want to know if there is any function which could return the actual call stack, or is it planned to be added? It could be very useful

Re: [PHP-DEV] Re: Function to retrieve headers for message/rfc822 attachments

2002-03-05 Thread Brad Fisher
I was trying to keep the naming consistent with the naming of the functions in the c-client lib The actual c-client function called is mail_fetch_header, so it became imap_fetch_header It seems to be the general way in which the original imap module developers named their functions But, I

Re: [PHP-DEV] New Module

2002-03-05 Thread Brad Fisher
J Smith wrote: I hesitate to mention this because I don't want to get stuck in a corner here, but I've been working on and off on a PHP encryption extension for precisely the reasons you mention I'm using Crypto++, a public This sounds to me like one of the better ways to do it Just have

Re: [PHP-DEV] New Module

2002-03-05 Thread Brad Fisher
loadable module? Something like: bool crypto_register_algorithm(string name, function crypt, function decrypt) Actually after thinking about it a bit more, why not: bool crypto_register_algorithm(string name, function crypt_decrypt) Then crypt and decrypt could have function

Re: [PHP-DEV] Counterpart to htmlentities function: unhtmlentities

2002-02-28 Thread Brad Fisher
Just a newer version of the unhtmlentities function This one utilizes the same tables as htmlentities, and (hopefully) is a little more locale friendly It also supports #; (decimal) #x; (hex) and #X; (hex) numeric entity formats -Brad Index: ext/standard//basic_functionsc

Re: [PHP-DEV] Counterpart to htmlentities function: unhtmlentities

2002-02-28 Thread Brad Fisher
The correct proto for unhtmlentities is: /* {{{ proto string unhtmlentities(string str [, string charset]) sry about that -Brad -- PHP Development Mailing List http://wwwphpnet/ To unsubscribe, visit: http://wwwphpnet/unsubphp

Re: [PHP-DEV] Re: Function to retrieve headers for message/rfc822 attachments

2002-02-27 Thread Brad Fisher
: Brad Fisher wrote: This is a function I wrote a while back so I could access more of the headers available in a mail message. The imap_headers and imap_fetchheaders functions work fine for retrieving headers for the main body of a given message, but if you receive an email

[PHP-DEV] Function to retrieve headers for message/rfc822 attachments

2002-02-26 Thread Brad Fisher
This is a function I wrote a while back so I could access more of the headers available in a mail message. The imap_headers and imap_fetchheaders functions work fine for retrieving headers for the main body of a given message, but if you receive an email with an attachment which is itself an

[PHP-DEV] Counterpart to htmlentities function: unhtmlentities

2002-02-26 Thread Brad Fisher
Just another function I have found useful.. PHP has a htmlentities function, but no unhtmlentities function to go the other direction.. (At least not that I am aware of). So, here you go. Don't think this one would perform nearly as quickly if it were done using regexps in PHP... This

[PHP-DEV] Refinement of wordwrap

2002-02-26 Thread Brad Fisher
Yet another refinement... This function wraps a string at a given width, but also respects embedded HTML, so HTML links are not broken. Basically, this would be a fairly drop-in replacement for the exitsing wordwrap function, with the addition of the HTMLmode parameter... -Brad

Re: [PHP-DEV] Re: Counterpart to htmlentities function: unhtmlentities

2002-02-26 Thread Brad Fisher
= get_html_translation_table(HTML_ENTITIES); $trans = array_flip($trans); $data = strtr($data,$trans); -Rasmus On Tue, 26 Feb 2002, Brad Fisher wrote: I have looked at the following: http://www.php.net/anoncvs.php http://cvs.php.net/cvs.php I am rather new to CVS, so

Re: [PHP-DEV] Re: Function to retrieve headers for message/rfc822 attachments

2002-02-26 Thread Brad Fisher
Here is my attempt at a unified diff against the current CVS. Let me know if I need to do anything differently. -Brad -- diff for php_imap.c --- --- php_imap.c +++ php_imap.c Tue Feb 26 23:00:58 2002 @@ -91,6 +91,7 @@ PHP_FE(imap_bodystruct, NULL)

Re: [PHP-DEV] Re: Counterpart to htmlentities function: unhtmlentities

2002-02-26 Thread Brad Fisher
, but that shouldn't slow it down too much if it were added. -Brad Rasmus Lerdorf wrote: But then we are not talking about the reverse of htmlentities because htmlentities() would never create #32; On Tue, 26 Feb 2002, Brad Fisher wrote: Not as trivial as you make it seem

Re: [PHP-DEV] Re: Counterpart to htmlentities function: unhtmlentities

2002-02-26 Thread Brad Fisher
Here are the diffs for the unhtmlentities function. Also included is a test script for some rudimentary benchmarking. -Brad unhtmlentities_test.php Description: application/unknown-content-type-microsoft --- html.c Tue Feb 26 22:44:44 2002 +++ html.c Wed Feb 27 00:42:04 2002 @@

Re: [PHP-DEV] Here we try again

2002-01-30 Thread Brad Fisher
Sure. Modify the Zend Engine so that it can be told to write the parsed opcodes to a file instead of executing them. Then modify ZE to be able to recognize those binary files, and execute them directly without the need for parsing. It should give you a performance increase and let you