Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

HTML Forum


You are currently viewing our HTML Forum as a guest. Please register to participate.
Login



Post a Project »

Find a Professional HTML Freelancer!

Find a Freelancer to help you with your HTML projects

FREE Outsourcing eBook!

Reply
Q? Anyone aware of possible comment attribute inside tags?
Old 05-18-2006, 07:30 PM Q? Anyone aware of possible comment attribute inside tags?
mgraphic's Avatar
Truth Seeker

Latest Blog Post:
JAMISONTUNES
Posts: 2,918
Name: Keith Marshall
Location: Connecticut
Trades: 0
Hello all:

Does anyone know if there is a way to make comments inside a (x)html tag? I want an eaiser way to keep track of nested elements. I understand that proper indentation will help keep track of opening and closing tags, but sometimes that is hard to achive when you are providing dynamic content (ie php output).

Here is an example of what I mean. Of course, this is only made-up syntax, but to help illustrate what I'm talking about:

HTML Code:
<div id="outer" !#="BO outer container">
   <div id="inner" !#="BO inner container">
      Some content here
   </div !#="EO inner container">
</div !#="EO outer container">
__________________

<mgraphic /> - I don't have a solution but I admire the problem.
mgraphic is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 05-18-2006, 07:36 PM Re: Q? Anyone aware of possible comment attribute inside tags?
kIDJOE's Avatar
Extreme Talker

Posts: 186
Location: Hollywood, CA
Trades: 0
I dont think you can actually comment within HTML tags, what you can do is add your comments in a tag that you make up your self.

<img src="XXX.gif" alt="XXX" width="XXX" height="XXX" style="XXX" comment="ADD YOUR COMMENT Here" />

It wont validate XHTML but you can add a cooment there and it wont affect your documents.

but I would just go for normal <!--COMMENTS-->
__________________

Please login or register to view this content. Registration is FREE
-
Please login or register to view this content. Registration is FREE
-

Please login or register to view this content. Registration is FREE
-
Please login or register to view this content. Registration is FREE

kIDJOE is offline
Reply With Quote
View Public Profile Visit kIDJOE's homepage!
 
Old 05-19-2006, 02:40 AM Re: Q? Anyone aware of possible comment attribute inside tags?
chrishirst's Avatar
Missing! presumed drunk.

Posts: 42,383
Name: Chris Hirst
Location: Blackpool. UK
Trades: 0
I just put standard HTML comments immediately after the tag.

<div id="main"> <!-- main container " -->

and comment the closing tag with the ID or class

that's what comment tags are there for
__________________
Chris. ->>
Please login or register to view this content. Registration is FREE
<<-

A foolish consistency is the hobgoblin of little minds
Thought for today:- Is SEO the only industry where all the cowboys are Indians?
chrishirst is online now
Reply With Quote
View Public Profile Visit chrishirst's homepage!
 
Old 05-19-2006, 06:58 AM Re: Q? Anyone aware of possible comment attribute inside tags?
Ultra Talker

Posts: 256
Location: Auckland, New Zealand
Trades: 0
You can do it like so:

HTML Code:
<div id="outer" style="/* BO outer container */">blah blah</div>
Not really a clean way, but if you do everything via CSS, then I guess you've got at least a good use for style with comments.


Cheers,

MC
__________________
#------------------------------signature---------------------------------------------------------------------------------#
Quote:
I am well recognised for what I don't do than what I do. Chores are just one of those things.
mastercomputers is offline
Reply With Quote
View Public Profile Visit mastercomputers's homepage!
 
Old 05-19-2006, 10:30 AM Re: Q? Anyone aware of possible comment attribute inside tags?
ADAM Web Design's Avatar
Canadastaninianite

Posts: 5,935
Name: Adam for web page design, not program
Location: Toronto, Ontario, Canada
Trades: 0
This may be stupid, but why not use the id attribute to name them directly?
Code:
<div id="level_1_outer">
<div id="level_2_inner">
Blah blah blah.
</div>
</div>
That way, you know how deeply an element is nested by its level.
__________________

Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
(my blog)


Please login or register to view this content. Registration is FREE
(with proof)
ADAM Web Design is offline
Reply With Quote
View Public Profile Visit ADAM Web Design's homepage!
 
Reply     « Reply to Q? Anyone aware of possible comment attribute inside tags?
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.24469 seconds with 12 queries