Discover Habbo's history
Treat yourself with a Secret Santa gift.... of a random Wiki page for you to start exploring Habbo's history!
Happy holidays!
Celebrate with us at Habbox on the hotel, on our Forum and right here!
Join Habbox!
One of us! One of us! Click here to see the roles you could take as part of the Habbox community!


View Poll Results: Commenting Good or Bad?

Voters
14. You may not vote on this poll
  • It's good and I use it.

    7 50.00%
  • It's good but I don't use it.

    2 14.29%
  • Bad, hate everything about it.

    0 0%
  • Idc about commenting..

    5 35.71%
Page 1 of 2 12 LastLast
Results 1 to 10 of 14
  1. #1
    Join Date
    Nov 2005
    Posts
    4,486
    Tokens
    921

    Latest Awards:

    Default [Poll] Commenting - Good or Bad?

    - Do you use commenting? -

    Well, I was just thinking - In HTML & PHP, I comment alot.
    But I don't see other people commenting when using html.

    I find that by commenting, the HTML & PHP code, I can remember things more easier and also, it just makes the code easier to read.

    - How do I comment? -

    In HTML, you can comment by;
    Adding; <!-- before the comment, and..
    Adding; --> after the comment.

    In PHP, you can comment by;
    Adding; // before short comments, and..
    /* and */ after blocks of comments.

    - Commenting good or bad? -

    Some people think commenting can make codes look bulky, ugly or hard to read, but I think it's the opposite.

    As I don't see alot of HTML anymore with comments, I was just thinking if people have stopped commenting as they might think it's a bad idea.

    What do you think?
    "RETIRED" FROM HABBO(X)

    :¬:

    TOMSPIT / COWLY05


  2. #2
    Join Date
    May 2008
    Posts
    127
    Tokens
    0

    Default

    When, I've coded I've used comment.
    It's very useful on free/opensource scripts.

  3. #3
    Join Date
    Nov 2005
    Posts
    4,486
    Tokens
    921

    Latest Awards:

    Default

    Yeah, when sometimes I use a base from open-source projects.
    I would be terribly lost without them.
    They sure can be life-savers.

    - Tom
    "RETIRED" FROM HABBO(X)

    :¬:

    TOMSPIT / COWLY05


  4. #4
    Join Date
    May 2008
    Posts
    127
    Tokens
    0

    Default

    Quote Originally Posted by TomSpit View Post
    Yeah, when sometimes I use a base from open-source projects.
    I would be terribly lost without them.
    They sure can be life-savers.

    - Tom
    Yeah. =D

  5. #5
    Join Date
    Sep 2006
    Location
    Evanston, Illinois.
    Posts
    2,361
    Tokens
    0

    Latest Awards:

    Default

    I comment on heavily when I'm working with teams in PHP, in Html, there isn't too much you need to comment on because it's self explanatory whereas a complex file opener function in php could have a simple /* File Opener */, which can save a lot of time for yourself aswell (if your tired...mt dew ), when working by myself just opening and closing divs - easier to keep track of, and basic php stuff.

    But I got a big job working at an office in Chicago so I'll have to do a LOT more commenting from now on.
    How could this hapen to meeeeeeeeeeeeeee?lol.

  6. #6
    Join Date
    Jul 2005
    Location
    North Wales
    Posts
    4,233
    Tokens
    1,544

    Latest Awards:

    Default

    Depends, if its my code and I'm working alone then no, but if I'm editing something or working with someone I try to comment on areas to remember where everything is and what is does but I don't comment as much as I would like to.

  7. #7
    Join Date
    Dec 2006
    Location
    Doncaster, UK
    Posts
    4,244
    Tokens
    0

    Latest Awards:

    Default

    I only usually comment on variables.
    A collection of forum users' views on obesity
    Quote Originally Posted by mynameisjake View Post
    sounds good
    Quote Originally Posted by Stephen View Post
    Just google it.
    Quote Originally Posted by jesus View Post
    jesus christ
    Quote Originally Posted by Alexicles. View Post
    It will probably soon go away.

  8. #8
    Join Date
    Mar 2008
    Posts
    5,108
    Tokens
    3,780

    Latest Awards:

    Default

    I usually comment to phpDoc standards.

    Commenting HTML isn't that useful unless you are commenting where certain divs end.

    <!-- navigation -->
    <div id="navigation">
    blablabla
    <div id="test">hlbalbkadlfjs</div>

    <!-- /navigation -->
    </div>

  9. #9
    Join Date
    Sep 2006
    Location
    Evanston, Illinois.
    Posts
    2,361
    Tokens
    0

    Latest Awards:

    Default

    why on earth would you comment on variables nasri, there really self explanatory.
    How could this hapen to meeeeeeeeeeeeeee?lol.

  10. #10
    Join Date
    Mar 2008
    Posts
    5,108
    Tokens
    3,780

    Latest Awards:

    Default

    Not really.

    PHP Code:
    <?php
    $database
    ['server']   = 'localhost'// MySQL server
    $database['username'] = 'root'// MySQL username
    ?>
    That, easy for non-coders to read
    Last edited by Dentafrice; 28-05-2008 at 03:03 AM.

Page 1 of 2 12 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •