Jump to content

Recommended Posts

When creating an application, I catch  myself writing numberous comments for small things and nothing for large things.

Should I write comments for everything or not write comments at all? I feel that if someone is purchasing my product that they have the right to know where to look for a specific function or area of code.

Of course at the same time I don't want to take 100 lines of the php page just to have comments.
Link to comment
https://forums.phpfreaks.com/topic/28783-comments/
Share on other sites

I'm not sure what phpDocumentor is but after looking it up, it creates html chm and other files, correct?

Would it be better to just write readme files with each script to let the user know where to look and what does what? That way it doesn't actually take up space in the application..
Link to comment
https://forums.phpfreaks.com/topic/28783-comments/#findComment-131781
Share on other sites

In my experience with phpDocumentor comments, if you're creating a professional application that could feasibly get very complicated, it's well worth the four or five lines of comments per method. Of course, for simple mutator and accessor methods, you may not want to put much documentation in, as you usually know exactly what it does just by looking at the method's name.
Link to comment
https://forums.phpfreaks.com/topic/28783-comments/#findComment-131945
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.