/    Sign up×
Community /Pin to ProfileBookmark

Attn: Coders need some help here

I am new to coding and need some help with my project. I cannot get the table to show the information….What the heck am I doing wrong??

<!DOCTYPE html PUBLIC “-//W3C//DTD XHTML 1.0 Strict//EN”
http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd“>
<html xmlns=”http://www.w3.org/1999/xhtml” lang=”en” xml:lang = “en” dir=”ltr”>
<head>
<title>Highest Waterfalls</title>
</head>
<script type=”text/javascript”>;
/* <![CDATA[ */
//This document prints the names, locations, and heights of the 10 highest waterfalls in the world.
document.write(“<h1>Don’s Jungle Tours</h1>”);
/* ]]> */
</script>
<meta http-equiv=”content-type” content=”text/html; charset=iso-8859-1″ />
<link rel=”stylesheet” href=”js_styles.css” type=”text/css” />
<body>
<h1>Highest Waterfalls</h1>
<p>The names, locations, and heights of the 10 highest waterfalls in the world are as follows:</p>
<script type=”text/javascript”>
/* <![CDATA[ */
document.write(“<table><colgroup span=”3″ width=”20%””);
document.write(“<tr><th>Name</th><th>Location</th><th>Height (in meters)</th></tr>”);
document.write(“<tr><td>Angel (upper fall)</td><td>Venezuela</td><td>807</td></tr>”;
document.write(“<tr><td>Itatinga</td><td>Brazil</td><td>628</td></tr>”);
document.write(“<tr><td>Cuquenan</td><td>Guyana/Venezuela</td><td>610</td></tr>”);
document.write(“<tr><td>Ormeli</td><td>Norway</td><td>563</td></tr>”);
document.write(“<tr><td>Tysse</td><td>Norway</td><td>533</td></tr>”);
document.write(“<tr><td>Pilao</td><td>Brazil</td><td>524</td></tr>”);
document.write(“<tr><td>Ribbon</td><td>USA</td><td>491</td></tr>”);
document.write(“<tr><td>Vestre Mardola</td><td>Norway</td><td>468</td></tr>”);
document.write(“<tr><td>Kaieteur</td><td>Guyana</td><td>457</td></tr>”);
document.write(“<tr><td>Cleve-Garth</td><td>New Zealand</td><td>450</td></tr>”);
document.write(“</table>”);
/* ]]> */
</script>
</body>
</html>

to post a comment
JavaScript

5 Comments(s)

Copy linkTweet thisAlerts:
@JMRKERSep 08.2008 — I have not looked beyond this, but it may start you in the right direction:

Remove the nested " characters in:
[code=php]
document.write("<table><colgroup span="3" width="20%"");
[/code]

to:
[code=php]
document.write("<table><colgroup span='3' width='20%'");
[/code]
Copy linkTweet thisAlerts:
@Primesale2000authorSep 08.2008 — Thank you for the help. But it is still not displaying the table with the information......
Copy linkTweet thisAlerts:
@HoboScriptSep 08.2008 — Since it looks like you are incredibly new to web stuff I'll be nice and just post a working version. Things of interest are escaping quotes and slashes. Escaping is putting a backslash in front of a character so as to be ignored within quotes. That's what the " and / are.

<i>
</i>&lt;!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"&gt;
&lt;html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang = "en" dir="ltr"&gt;
&lt;head&gt;
&lt;title&gt;Highest Waterfalls&lt;/title&gt;
&lt;meta http-equiv="content-type" content="text/html; charset=iso-8859-1" /&gt;
&lt;link rel="stylesheet" href="js_styles.css" type="text/css" /&gt;
&lt;/head&gt;

&lt;body&gt;
&lt;h1&gt;Don's Jungle Tours&lt;/h1&gt;
&lt;h1&gt;Highest Waterfalls&lt;/h1&gt;
&lt;p&gt;The names, locations, and heights of the 10 highest waterfalls in the world are as follows:&lt;/p&gt;
&lt;script type="text/javascript"&gt;
/* &lt;![CDATA[ */
document.write("&lt;table&gt;&lt;colgroup span="3" width="20%"");
document.write("&lt;tr&gt;&lt;th&gt;Name&lt;/th&gt;&lt;th&gt;Location&lt;/th&gt;&lt;th&gt;Height (in meters)&lt;/th&gt;&lt;/tr&gt;");
document.write("&lt;tr&gt;&lt;td&gt;Angel (upper fall)&lt;/td&gt;&lt;td&gt;Venezuela&lt;/td&gt;&lt;td&gt;807&lt;/td&gt;&lt;/tr&gt;");
document.write("&lt;tr&gt;&lt;td&gt;Itatinga&lt;/td&gt;&lt;td&gt;Brazil&lt;/td&gt;&lt;td&gt;628&lt;/td&gt;&lt;/tr&gt;");
document.write("&lt;tr&gt;&lt;td&gt;Cuquenan&lt;/td&gt;&lt;td&gt;Guyana/Venezuela&lt;/td&gt;&lt;td&gt;61&lt;/td&gt;&lt;/tr&gt;");
document.write("&lt;tr&gt;&lt;td&gt;Ormeli&lt;/td&gt;&lt;td&gt;Norway&lt;/td&gt;&lt;td&gt;563&lt;/td&gt;&lt;/tr&gt;");
document.write("&lt;tr&gt;&lt;td&gt;Tysse&lt;/td&gt;&lt;td&gt;Norway&lt;/td&gt;&lt;td&gt;533&lt;/td&gt;&lt;/tr&gt;");
document.write("&lt;tr&gt;&lt;td&gt;Pilao&lt;/td&gt;&lt;td&gt;Brazil&lt;/td&gt;&lt;td&gt;524&lt;/td&gt;&lt;/tr&gt;");
document.write("&lt;tr&gt;&lt;td&gt;Ribbon&lt;/td&gt;&lt;td&gt;USA&lt;/td&gt;&lt;td&gt;491&lt;/td&gt;&lt;/tr&gt;");
document.write("&lt;tr&gt;&lt;td&gt;Vestre Mardola&lt;/td&gt;&lt;td&gt;Norway&lt;/td&gt;&lt;td&gt;468&lt;/td&gt;&lt;/tr&gt;");
document.write("&lt;tr&gt;&lt;td&gt;Kaieteur&lt;/td&gt;&lt;td&gt;Guyana&lt;/td&gt;&lt;td&gt;457&lt;/td&gt;&lt;/tr&gt;");
document.write("&lt;tr&gt;&lt;td&gt;Cleve-Garth&lt;/td&gt;&lt;td&gt;New Zealand&lt;/td&gt;&lt;td&gt;450&lt;/td&gt;&lt;/tr&gt;");
document.write("&lt;/table&gt;");
/* ]]&gt; */
&lt;/script&gt;
&lt;/body&gt;
&lt;/html&gt;
Copy linkTweet thisAlerts:
@JMRKERSep 08.2008 — Might want to check the error console and look for syntax errors like (fixed):
[code=php]
document.write("<tr><td>Angel (upper fall)</td><td>Venezuela</td><td>807</td></tr>");
[/code]
Copy linkTweet thisAlerts:
@Primesale2000authorSep 08.2008 — Thank you HOBOScript your the "Man" or "Woman" I was up for hours trying to get this to work thank you very much.....
×

Success!

Help @Primesale2000 spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.25,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...