How to format HTML code

B

Bob Richardson

Is there a way to format HTML code so that it "looks pretty" using some
simple rules. What's in FP doesn't seem to be what I'm looking for. Ideally
a free download program would be available.
 
S

Steve Easton

When you publish the pages, the server will most likely "format" the code for you anyway.

What exactly are you trying to do??
How your html code "looks" is relatively unimportant. What is important is whether the pages
function properly.

That said, in FrontPage 2003 with your web and a page open, click Tools > Page Options and then
click the "Code Formatting" tab.


--
Steve Easton
Microsoft MVP FrontPage
95isalive
This site is best viewed............
........................with a computer
 
M

Michiel van der Blonk

Nothing will do it for you, but here is a link you might find interesting.
This is absolutely not true. HTMLTidy _will_ do it for you.
go to http://www.w3.org/People/Raggett/tidy/

Michiel
*****************************
Michiel van der Blonk
CaribMedia Marketing & Consultancy N.V.
Oranjestad, Aruba
Tel: (297) 583-4144 Fax: (297) 582-6102
http://www.caribmedia.com
----------------------------------------------------
Website Design, Web Application Development,
Web Hosting, Internet Marketing
----------------------------------------------------
Operators of:
Visit Aruba - http://www.VisitAruba.com
Aruba Links - http://www.ArubaLinks.com
Aruba Business Directory - http://www.visitaruba.com/business/
Aruba Real Estate Locator - http://www.arubarealestate.com
Aruba Bulletin Board - http://bb.visitaruba.com/
Aruba Trip Reports - http://tripreports.visitaruba.com
Aruba Chat - http://chat.visitaruba.com
The VisitAruba Plus SAVINGS CARD - http://www.visitaruba.com/plus/
Contents of this communication are confidential and legally privileged. This
document is intended solely for use of the individual(s) or entity/entities
to whom it is addr
 
B

Bob Richardson

How HTML looks is unimportant if you never look at it, or try to make
changes directly to it. Otherwise, logically formatted HTML code makes the
job substantially easier. When you remove or add a tab, it's crucial that
the balancing tags be added in the right place or the correct one removed.

For example, I'd like to be able to change something like:

<TABLE> <TR> <TD><FONT..> <CENTER>xxxxxx</<CENTER> </FONT> </TD>
</TR></TABLE>

into:

<TABLE>
<TR>
<TD>
<FONT..>
<CENTER>xxxxxx</<CENTER>
</FONT>
</TD>
</TR>
</TABLE>

It seems to me that "Code Formatting" only applies to future changes. I
haven't been able to change existing code into formatted code like the
above.
 
B

Bob Richardson

Tidy seems to do the job fine, but it's a bit cumbersome to use.

"Reformat" is very easy to use, but doesn't seem to do all that I'd like. I
couldn't figure out how to have the reformatting indent, and also create new
lines as needed.
 
R

Ronx

Tools->Page Options - Code Formatting tab
Here you set the size of the indents, and which tags should be
preceded/followed by a line break.
 
B

Bob Richardson

Thank you. Now I got it :)

Ronx said:
Tools->Page Options - Code Formatting tab
Here you set the size of the indents, and which tags should be
preceded/followed by a line break.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top