Re: php_error_docref (was: Re: [PHP-DEV] Re: [PHP-CVS] cvs: php4 /main main.c php.h)

From: Date: Thu, 08 Aug 2002 10:15:06 +0000
Subject: Re: php_error_docref (was: Re: [PHP-DEV] Re: [PHP-CVS] cvs: php4 /main main.c php.h)
References: 1 2 3  Groups: php.dev 
Request: Send a blank email to php-dev+get-86637@lists.php.net to get a copy of this message
I suggest we allow docref parameter being NULL and convert the called finctions name into the documents name. Problem 1 is how do we know inside the handler that we are called from setup phase? I mean it would be nice to direct to the sapi page. But this would require every sapi to have its own page (Hartmut). Problem 2 we will have to either use TSRM build allways or have to surrender the feature in non TSRM builds. marcus At 11:57 08.08.2002, Wez Furlong wrote:
Thanks :-) It's not really my idea - it's been on the todo forever. I just thought, we might also want an option for setting the target for the link. Also, it worth talking to some php-doc guys (I think Hartmut might have something to say about this) about the docref parameter and how it is interpreted, because it would be great if we could point the user at a named offset into the page, using the # "operator": php_error_docref(E_WARNING, "features.remote-files#no_ftp_write", "Cannot write to remote files using ftp"); produces a URL like this: http://php.net/manual/en/features.remote-files.php#no_ftp_write It seems obvious enough, but it's worth checking with a doc "guru" to see if there are any rules/restrictions or whatever about how the docs are built and how the references are made. --Wez. On 08/08/02, "Markus Fischer" <mfischer@guru.josefine.at> wrote: Wow!
    I'm impressed. That's one of the best ideas I've read on this
    list for months, and I really mean it that way. +1
    - Markus
On Wed, Aug 07, 2002 at 11:32:19PM +0100, Wez Furlong wrote :
This seems OK, but I have a suggestion: add a string parameter that refers to a location in the manual.
[...]
So, the C code would look something like this: php_error_docref(E_WARNING, "features.remote-files", "Cannot write to remote files using ftp");
[...]
Warning: Cannot write to remote files using ftp. <a href="http://php.net/manual/en/features.remote-files.php">Click Here for more information.</a> or if html_errors is off: Warning: Cannot write to remote files using ftp. See http://php.net/manual/en/features.remote-files.php for more information.
-- PHP Development Mailing List <http://www.php.net/> To unsubscribe, visit: http://www.php.net/unsub.php


« previous php.dev (#86637) next »