php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Doc Bug #38853 Examples should include output
Submitted: 2006-09-16 12:13 UTC Modified: 2007-01-22 01:48 UTC
From: gokdeniz at cclub dot metu dot edu dot tr Assigned:
Status: Closed Package: Documentation problem
PHP Version: Irrelevant OS:
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: gokdeniz at cclub dot metu dot edu dot tr
New email:
PHP Version: OS:

 

 [2006-09-16 12:13 UTC] gokdeniz at cclub dot metu dot edu dot tr
Description:
------------
This is not a "problem", but a general issue that can be found in many pages of php documentation. When an example is given, sometimes it only shows the function call and not the output. It can be said that many of these are self-explaining, and it wouldn't be wrong. But a completely fool-proof documentation, which can be helpful even for a tired developer in late hours should include outputs for all examples.

Here is only one sample for the issue, and during my experience with php I've seen many pages giving examples like this. 
http://www.php.net/manual/en/function.realpath.php  shows how to call realpath function """ $real_path = realpath("../../index.php"); """ Proper output may be given as 
""" //Assuming your php file resides in /var/www/mysite/dir1/dir2
     echo $real_path
     // outputs
     // /var/www/mysite/index.php


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2007-01-22 01:48 UTC] didou@php.net
Hello,

We are aware of the need of examples and their output.
I just added one for realpath and I'm closing the bug as this item is on our TODO.

By the wat, the next manual version will include nice graphics for the GD docs :)
 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Wed Nov 19 21:00:01 2025 UTC