标题几乎说明了一切。我认为它格式正确,但由于某种原因,我仍然看到用浏览器打开时的标签。对代码墙感到抱歉,我很确定问题非常简单,但现在最容易复制和粘贴整个问题。
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta http-equiv="Content-Style-Type" content="text/css">
<title></title>
<meta name="Generator" content="Cocoa HTML Writer">
<meta name="CocoaVersion" content="1038.36">
<style type="text/css">
p.p1 {margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px Helvetica}
p.p2 {margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px Helvetica; min-height: 14.0px}
span.Apple-tab-span {white-space:pre}
</style>
</head>
<body>
<p class="p1"><html xmlns="http://www.assignment9.com/xhtml"></p>
<p class="p1"><head> <title>James</title> </head></p>
<p class="p2"><br></p>
<p class="p1"><body style="background-color : black; color : white"></p>
<p class="p1"><span class="Apple-tab-span"> </span><h1>Musical background</h1></p>
<p class="p1"><p>James has had a rich musical background.<span class="Apple-converted-space"> </span>He started playing the upright bass at 10 years old.<span class="Apple-converted-space"> </span>From there he moved to the electric bass at 13 and guitar at 15.<span class="Apple-converted-space"> </span>Guitar is his true love and calling.<span class="Apple-converted-space"> </span>James has been self taught on guitar for 8 years and is now gigging fairly often in the hartford area. </p></p>
<p class="p2"><br></p>
<p class="p1"><span class="Apple-tab-span"> </span><h2>James' Favorite Musical Groups</h2></p>
<p class="p1"><p>With all the genre's of music out there, James has been influenced by bands and artists from several genre's including, The Eagles, Van Halen, Brad Paisley, Europe, Joe Bonamassa.<span class="Apple-converted-space"> </span></p></p>
<p class="p2"><br></p>
<p class="p1"><img src="IMG_0123" alt="PRS Santana SE/></p>
<p class="p2"><br></p>
<p class="p1"><span class="Apple-tab-span"> </span><h3>Musical Instruments</h3></p>
<p class="p1"><p>James currently 4 guitars and he loves each and everyone one of them.<span class="Apple-converted-space"> </span>His first guitar was a Fender Stratocaster.<span class="Apple-converted-space"> </span>It served as his only electric guitar until earlier this year when he purchased a PRS Santana SE.<span class="Apple-converted-space"> </span>This is now his primary electric guitar.<span class="Apple-converted-space"> </span>For acoustic guitars, has a Takemine G Series acoustic electric guitar and a Breedlove 514CE acoustic electric guitar.<span class="Apple-converted-space"> </span>He frequently is seen giggling with both guitars</p></p>
<p class="p2"><br></p>
<p class="p1"></body></p>
<p class="p1"></html></p>
</body>
</html>
答案 0 :(得分:2)
看起来您使用Cocoa HTML编写器,但将HTML粘贴到Visual(WYSIWYG)编辑器中。这个问题是它用html编码的等价物编码你的所有标签(例如&amp; gt;) 如果此软件具有HTML /源视图,请尝试将内容粘贴到那里,然后保存。
如果没有将内容粘贴到不进行html格式化的普通文本编辑器中,然后使用.html扩展名保存文件。
如果您不确定如何提取原始HTML代码,请删除&lt; p&gt;标签,然后将文本复制到以下网站:http://www.opinionatedgeek.com/DotNet/Tools/HTMLEncode/decode.aspx
答案 1 :(得分:0)
您的问题是HTML中的内容是HTML实体。 <
与文字&lt;和>
与&gt;相同所以,它正确地格式化你的HTML,但你的内容看起来就像HTML。
以下是HTML实体的链接:http://www.w3schools.com/html/html_entities.asp