Reputation: 1013
why in the world I'm a getting a syntax error from <!DOCTYPE html>
?
<!DOCTYPE html>
<html>
<head>
<title>Portfolio</title>
<link rel="stylesheet" type="text/css" href="shapes.css">
</head>
<body>
<div class="content">
<div class="header">
</div>
<div class="middle">
<div class="image">
</div>
<div class="text">
</div>
</div>
</div>
</body>
</html>
Syntax error
File "/Volumes/postergren_projectDrive/Projekt/programmingSandbox/Udacity/Intro to HTML and CSS/startBlock/portfolio/toplist/index.html", line 1
<!DOCTYPE html>
^
SyntaxError: invalid syntax
[Finished in 0.0s with exit code 1]
[shell_cmd: "python" -u "/Volumes/postergren_projectDrive/Projekt/programmingSandbox/Udacity/Intro to HTML and CSS/startBlock/portfolio/toplist/index.html"]
[dir: /Volumes/postergren_projectDrive/Projekt/programmingSandbox/Udacity/Intro to HTML and CSS/startBlock/portfolio/toplist]
[path: /usr/bin:/bin:/usr/sbin:/sbin]
Upvotes: 0
Views: 11101
Reputation: 1013
It was an easy solution, after the first comment i realized it.
It was just a human error, had forgot to set my build system in sublime to chrome instead of anaconda(python).
Thanks..
Upvotes: 2
Reputation: 627
You can't output HTML directly from Python. You need to use print
or better still, a templating library of some sort.
Upvotes: 1