Comments form an important part in documentation.
You can start the program with a brief description of the entire program on
top of the page. Here is how you can do this:
The first few lines gives a brief description of the class. This is how I
prefer to display a block of description.
Line comments can be used to explain any
particular action in the code. This is demonstrated below.
I prefer to place the Line Comment on the same line with the particular
action, rather than placing it above or below the action. The Following is
what I don't prefer:
The code should be properly indented so that the control structures are
visible and can be properly understood. The PEAR RFC standard recommends
four spaces, not tabs of any size, in your code. But you can use spaces for
the same. Here is an example of indenting code.
I prefer opening parenthesis to follow the conditions in control
structures, but the opening parenthesis should start with the new line in
case of functions or classes or class members. Also the IF and ELSE
statements should be well covered by braces.
| Comments: |
| website | Bob Gaston | 07/06/07 15:29 |
| RE: PHP BEGINNER | cavell | 05/05/07 16:20 |
| RE: PHP BEGINNER | wana | 04/30/07 00:31 |
| RE: uploading pictures to mySQL | wana | 04/30/07 00:23 |
| RE: time delay | Glenn | 09/27/05 19:56 |
| RE: Help required to configure php_gd.dll | Robert Sedlak | 07/08/05 13:25 |
| PHP BEGINNER | dennis gonzales | 05/07/05 04:17 |
| Main pages doesn't download | Sergio | 02/09/05 07:48 |
| connect to database | dina | 02/01/05 01:25 |
| RE: Finding a good PHP book(free downloads) | Abhishek | 01/31/05 02:02 |
| RE: uploading pictures to mySQL | khan | 01/13/05 10:22 |
| Finding a good PHP book(free downloads) | santhosh kumar | 01/02/05 01:36 |
| need help (MySQL) | Dayananda.MR | 11/18/04 08:04 |
| RE: Finding a PHP book(free download) | hamid | 11/11/04 13:28 |
| documentation | sentayehu | 11/16/03 04:40 |
| RE: CSS Links | 3steps | 11/04/03 23:33 |
| PHP Coding Standard | vicen | 05/26/03 04:58 |
| RE: My if/else style | vicen | 05/26/03 04:23 |
| RE: good programming style | Jim | 04/07/03 16:58 |
| RE: if/else | kelvin | 02/26/03 11:33 |
| RE: My if/else style | Carlo | 01/14/03 17:15 |
| RE: My if/else style | Nick | 12/16/02 23:23 |
| Need Help | Marth164 | 11/20/02 20:16 |
| RE: I need a good php editor in Windows | Adolf | 11/05/02 10:27 |
| PHP Beginner | Prathaban | 09/24/02 08:07 |
| PHP editor for windows, but installable zippy | Gary | 09/24/02 02:21 |
| RINGTONE | meshal | 09/16/02 11:33 |
| RE: Indenting and inline commenting | akeppel | 09/14/02 09:31 |
| RE: Who Cares? | akeppel | 09/13/02 13:19 |
| Indenting and inline commenting | akeppel | 09/13/02 13:13 |
| PHP url parameter retrieval | Jason | 09/13/02 02:42 |
| RE: I need a good asp editor on linux | Vinay | 09/05/02 06:57 |
| RE: I need a good php editor in Windows | David Phillips | 08/23/02 02:45 |
| RE: I need a good php editor in Windows | Michael McLoughlin | 08/18/02 19:21 |
| function sql_connection | majid hussain | 08/14/02 13:35 |
| Pop up windows | ivan | 08/14/02 13:27 |
| php and c++ program | salat | 08/05/02 09:00 |
| RE: I need a good php editor in Windows | Sachith | 07/26/02 00:57 |
| program for friendly printer option in php | Praveen | 07/22/02 06:42 |
| i need magure help. | natasha | 07/20/02 21:42 |
| How to make ODBC Connection in PHP | Bright | 07/13/02 03:35 |
| Como limpio la pantalla?? | Leysner | 07/12/02 16:31 |
| User Validation==how? | Nuker | 07/05/02 10:13 |
| RE: i have problems with my first steps. | iranianguy | 06/24/02 07:59 |
| RE: i have problems with my first steps. | shahin | 06/24/02 07:43 |
| how to create chat site by using php? | farah | 06/17/02 03:15 |
| pourcentages | yousfi | 06/12/02 11:43 |
| How do I create Frames using PHP. | Unindra | 06/11/02 17:47 |
| RE: Use a good editor | steve | 06/10/02 12:36 |
| RE: Strings | steve | 06/10/02 12:24 |
| uploading pictures to mySQL | Miss_V | 06/07/02 15:33 |
| PHP-NUKE, Dreamweaver, Frontpage | BioHazard | 06/06/02 14:08 |
| Strings | Bokkie | 06/05/02 16:49 |
| Help required to configure php_gd.dll | P.V.Raja | 05/27/02 03:05 |
| PHPDocumentor 1.0.0 STABLE released | Greg Beaver | 05/25/02 13:04 |
| PHP editor for Linux | Ashok | 05/23/02 14:14 |
| RE: Finding a PHP book(free download) | rajesh kumar | 05/22/02 07:38 |
| RE: I need a good php editor in Windows | Sudhir | 05/21/02 17:01 |
| IMAP/LDAP : mailbox configuration | Penta | 05/15/02 04:13 |
| How to encrypt strings in PHP? | Cin | 05/13/02 04:30 |
| RE: demande d avoir une Documentation PHP | Miguel | 05/10/02 10:51 |
| RE: Help! How to use Access 2K with PHP? | TRos | 05/06/02 20:25 |
| RE: I need a good php editor in Windows | Earl Cooley | 05/04/02 00:05 |
| Finding a PHP book(free download) | cvdanh | 05/03/02 06:00 |
| Apache user Authentication against PostgreSQL | Jackie | 05/02/02 15:24 |
| send me php builder | suhail | 04/28/02 17:00 |
| Help! How to use Access 2K with PHP? | Simon | 04/28/02 05:57 |
| RE: File Uploads in PHP | Ashwin | 04/24/02 15:03 |
| time delay | Zorz | 04/24/02 08:04 |
| how to prepare platform for Php.. | azmi | 04/18/02 05:20 |
| RE: i have problems with my first steps. | ovi | 04/18/02 04:49 |
| Who Cares? | PHP buff | 04/17/02 22:55 |
| I interesed php so much! | dusit | 04/17/02 01:52 |
| hoping someone could teach me php | phpbeginner | 04/15/02 19:29 |
| RE: and i need a php editor for os x | Greg | 04/10/02 11:48 |
| i have problems with my first steps. | Naghmeh | 04/03/02 04:04 |
| File System Object | socheat | 04/02/02 01:40 |
| how to send mail | bles | 04/01/02 01:23 |
| RE: I need someone, who can teach me PHP. | Paresh Parihar | 03/28/02 00:00 |
| and i need a php editor for os x | radon | 03/26/02 08:05 |
| RE: I need a good php editor in Windows | Mikey | 03/26/02 05:43 |
| RE: I need a good php editor in Windows | roger | 03/22/02 00:43 |
| how to create a masck to telphone in PHP | Thomas | 03/21/02 07:09 |
| RE: I need a good php editor in Windows | mac | 03/19/02 03:19 |
| RE: file writing | Steven | 03/16/02 10:54 |
| demande d avoir une Documentation PHP | Essayd | 03/13/02 05:17 |
| RE: I need someone, who can teach me PHP. | Ashwini Kumar Rath | 03/11/02 09:34 |
| file writing | Khaos | 03/09/02 23:22 |
| RE: I need a good php editor in Windows | Paonza | 03/08/02 07:58 |
| RE: I need a good php editor in Windows | toby | 03/06/02 14:34 |
| New commerce in PHP | Riaghan | 03/04/02 19:53 |
| i wany to build php on my site | shams | 02/23/02 21:50 |
| RE: I need a good php editor in Windows | Dave Starling | 02/23/02 12:06 |
| I need someone, who can teach me PHP. | Mikael Voss | 02/22/02 08:11 |
| code php to oracle | yoke | 02/22/02 05:04 |
| RE: I need a good php editor in Windows | Jim | 02/21/02 23:17 |
| RE: I need a good php editor in Windows | Simon B/ | 02/20/02 23:28 |
| I need a good php editor in Windows | Suvendu | 02/17/02 03:09 |
| PHP deprecation | Derek Piper | 02/15/02 10:14 |
| RE: if/else - function braces and all that... | fLIPIS | 02/12/02 06:56 |
| RE: style | SileNceR | 02/12/02 02:34 |
| suggest good editor for PHP | sachinrase | 02/11/02 00:47 |
| I am a beginner | Emsi Ell | 02/08/02 13:06 |
| RE: Use a good editor | will | 02/08/02 03:16 |
| "populate" | Richness | 01/28/02 03:16 |
| File Uploads in PHP | ravi | 01/27/02 13:31 |
| RE: data value and header problem.. what's wr | Nathan Hyde | 01/24/02 19:33 |
| coding help | prabhakar | 01/24/02 05:32 |
| RE: if, and, or, else | Rod K | 01/16/02 07:35 |
| RE: CSS Links | Steve | 01/16/02 06:57 |
| if, and, or, else | cody69 | 01/15/02 03:01 |
| data value and header problem.. what's wrong? | balaburu | 01/13/02 23:43 |
| How do I update a particular field... | sujan | 01/01/02 09:04 |
| interface base de données et web | dali | 12/27/01 07:30 |
| CSS Links | Ruckus | 12/14/01 12:53 |
| RE: Nice try, but... | Pete | 12/14/01 00:04 |
| html in php? never | Aswan | 12/11/01 00:50 |
| software testing the ICRADIUS | johary anodith | 11/23/01 07:38 |
| RE: what about PHPDOC? | Joshua Eichorn | 11/07/01 15:38 |
| There can be only one - WAS: braces and all.. | blazer | 10/31/01 23:36 |
| RE: Nice try, but... | Richard Samar | 10/21/01 18:40 |
| good programming style | headcore | 10/21/01 05:54 |
| RE: strange coding style | Strudleman | 10/19/01 01:17 |
| RE: help! what exactly is PHP? | Strudleman | 10/19/01 00:43 |
| RE: if/else | RockMonkey | 10/18/01 21:04 |
| RE: help! what exactly is PHP? | morpheus() | 10/14/01 01:05 |
| Something to remember | Vincent Vollers | 10/13/01 12:39 |
| RE: Programming is an art | Sujith Nair | 10/13/01 06:27 |
| RE: Programming is an art | Vincent Oostindie | 10/12/01 18:35 |
| Programming is an art | Torkel Lyng | 10/12/01 07:07 |
| help! what exactly is PHP? | mazzy star | 10/12/01 02:09 |
| RE: Nice try, but... | Vincent Oostindie | 10/11/01 18:13 |
| RE: Nice try, but... | Vincent Oostindie | 10/11/01 18:09 |
| RE: Nice try, but... | Vincent Oostindie | 10/11/01 18:06 |
| Use a good editor | Michael Madsen | 10/11/01 04:01 |
| RE: Nice try, but... | sayonion | 10/10/01 21:14 |
| RE: Nice try, but... | Cal Evans | 10/10/01 20:05 |
| RE: Nice try, but... | Peimann | 10/10/01 17:37 |
| RE: if/else | sluggo | 10/10/01 16:46 |
| RE: if/else, brackets etc | Greg MacLellan | 10/10/01 16:23 |
| RE: if/else | Barry Kukkuk | 10/10/01 09:16 |
| RE: strange coding style | phil | 10/10/01 07:14 |
| style | Ste | 10/10/01 07:10 |
| if/else - function braces and all that... | Ranjith | 10/10/01 02:09 |
| indentation | Ren | 10/07/01 19:46 |
| RE: what about phpdoc? | paul | 10/07/01 17:13 |
| Nice try, but... | Vincent Oostindie | 10/07/01 10:20 |
| RE: Openning/Closing Tags | Digital Wokan | 10/07/01 00:33 |
| My if/else style | Digital Wokan | 10/07/01 00:30 |
| RE: if/else | morpheus() | 10/06/01 12:59 |
| RE: strange coding style | morpheus() | 10/06/01 12:53 |
| Tabs v. Spaces | Brian | 10/05/01 21:57 |
| RE: strange coding style | lee | 10/05/01 21:42 |
| the foo() example | Dweezel | 10/05/01 16:34 |
| RE: if/else | Michael Lidgren | 10/05/01 06:02 |
| RE: strange coding style | Sujith Nair | 10/05/01 00:33 |
| RE: Openning/Closing Tags | Sujith Nair | 10/04/01 23:56 |
| bracing code blocks and indention | Nil-Joe Angsioco | 10/04/01 21:30 |
| if/else | dan | 10/04/01 11:17 |
| what about PHPDOC? | Bryan Alsdorf | 10/04/01 11:09 |
| strange coding style | marcel | 10/04/01 10:11 |
| Openning/Closing Tags | Fil / RezoX | 10/04/01 02:02 |
| what about phpdoc? | borkazoid | 10/03/01 23:29 |
|
If you are looking for help, please post on the appropriate forum here. Your questions will be answered much more quickly.
|