Coding Errors, Ways To Make Code Shorter etc.
-
- Dungeoneer
- Posts: 27
- Joined: 22 Oct 2005, 15:51
Coding Errors, Ways To Make Code Shorter etc.
OK, I'll just edit this post later with some results I find.
Anyways, I've created this thread for a two reasons:
1) To make coding smaller to save...small space.
2) To spot errors in coding on the Knightmare site.
Anyways, I've created this thread for a two reasons:
1) To make coding smaller to save...small space.
2) To spot errors in coding on the Knightmare site.
- TheBrollachan
- Knight
- Posts: 643
- Joined: 08 May 2004, 21:49
- Location: Cambridgeshire
- Contact:
Re:Coding Errors, Ways To Make Code Shorter etc.
Ah, the good old W3 validator:
http://validator.w3.org/
Just a quick example...
http://validator.w3.org/check?uri=http% ... htmare.com
In terms of coding etc I go by the rule of create for Firefox then adapt to get Internet Explorer to behave itself. As I use Firefox I have the following extension/addon installed, which allows me to check my websites fairly thoroughly...
https://addons.mozilla.org/extensions/m ... g=10&id=60
Edit: Link is now working again this morning, the file/page has reappeared.
http://validator.w3.org/
Just a quick example...
http://validator.w3.org/check?uri=http% ... htmare.com
In terms of coding etc I go by the rule of create for Firefox then adapt to get Internet Explorer to behave itself. As I use Firefox I have the following extension/addon installed, which allows me to check my websites fairly thoroughly...
https://addons.mozilla.org/extensions/m ... g=10&id=60
Edit: Link is now working again this morning, the file/page has reappeared.
Last edited by TheBrollachan on 26 Oct 2005, 07:16, edited 1 time in total.
Twitter: https://twitter.com/SmokeHits
Keeper of the original modellers' cast of the Brollachan.
Keeper of the original modellers' cast of the Brollachan.
-
- Knight
- Posts: 633
- Joined: 11 Jan 2002, 03:01
- Location: Corridor of Blades
- Contact:
Re:Coding Errors, Ways To Make Code Shorter etc.
Thanks for raising this, Devanté.
I am aware that there are literally hundreds of coding errors throughout the site. This is mostly because the bulk of the original pages were made using rubbish HTML editors many years ago.
I'd love to re-do the whole site, clean up the coding, re capture images and video at higher quality, but unfortunatly finding the time to do it will be extremely difficult.
I am aware that there are literally hundreds of coding errors throughout the site. This is mostly because the bulk of the original pages were made using rubbish HTML editors many years ago.
I'd love to re-do the whole site, clean up the coding, re capture images and video at higher quality, but unfortunatly finding the time to do it will be extremely difficult.
You're on the edge of a ledge...
-
- Dungeoneer
- Posts: 27
- Joined: 22 Oct 2005, 15:51
Re:Coding Errors, Ways To Make Code Shorter etc.
Speaking of which, what software did you use?
-
- Knight
- Posts: 633
- Joined: 11 Jan 2002, 03:01
- Location: Corridor of Blades
- Contact:
Re:Coding Errors, Ways To Make Code Shorter etc.
First I used HotMetal Pro, then FrontPage. Now I use 1st Page 2000.
You're on the edge of a ledge...
-
- Dungeoneer
- Posts: 27
- Joined: 22 Oct 2005, 15:51
Re:Coding Errors, Ways To Make Code Shorter etc.
Ah, OK.
I use Dreamweaver 2004, but I can't be bothered getting 8 because you can do a lot with the current one you have rather than getting a new one...
Also, here is the code for 'The Eye Shield' page which hasn't been shortened but has had some unnecessary spacing removed.
Of course it doesn't have all spacing removed but I'll get to that later.
I use Dreamweaver 2004, but I can't be bothered getting 8 because you can do a lot with the current one you have rather than getting a new one...
Also, here is the code for 'The Eye Shield' page which hasn't been shortened but has had some unnecessary spacing removed.
Code: Select all
<html><head><title>The Eye Shield</title></head>
<body background="shieldbak.jpg">
<p align="center"><img src="teslogo.gif" alt="teslogo.gif (4352 bytes)" width="402"
height="124"></p>
<p align="center"><font size="5" face="Roman"><img src="kaclogo2.gif"
alt="kaclogo2.GIF (5275 bytes)" width="199" height="90"></font></p>
<p align="center"><font face="Arial"><strong>Editors:</strong> Paul McIntosh/Jake Collins<br>
<font size="2"><b>Webmaster:</b> Illusion<br>
</font><a href="email.htm">Contact us</a> </p>
<p align="center"><a href="issues.htm"> Issue Contents</a> : <a
href="bbk.htm">Bring Back Knightmare</a></p>
<p align="center"><b>July 2001: <a href="newissues.htm">New issues</a> of TES now online!</b></p>
<p><font color="#FF0000" face="Arial"><strong>The Eye Shield</strong></font> was a quarterly printed Knightmare fanzine, launched in December 1995. The
magazine was produced by life-long Knightmare fan - <font color="#FF0000"
face="Arial">Paul McIntosh</font><font face="Arial">. He was disappointed to see
Knightmare fade away, and so set up 'The Eye Shield', originally intended to be an
independent 'fanzine', separate from Broadsword Television (who were keen on the idea).</font></p>
<p><font face="Arial">Paul kept in contact with Broadsword Television, and eventually the
fanzine became ' The Official Knightmare Magazine', and they did their part by passing on
all Knightmare mail onto him, and helping out wherever possible.</font></p>
<p><font face="Arial"><em>"But I never heard about 'The Eye Shield!'"</em></font></p>
<p><font face="Arial">It is likely that you did not hear about the magazine. It was going
to be mentioned in the last edition of 'The Quest', but there was a slight hiccup, and it
was missed out. All remaining copies of 'The Quest' were therefore sent out to as many
people as possible with a leaflet advertising the new fanzine. </font>So well done if you were one of the lucky ones!</p>
<p><font face="Arial">TES was packed full with news, competitions, reader letters, games,
puzzles and artwork. Not forgetting exclusive interviews with </font><font
color="#FF0000" face="Arial">David Learner</font><font face="Arial"> (Pickle), </font><font
color="#FF0000" face="Arial">Hugo Myatt</font><font face="Arial"> (Treguard), </font><font
color="#FF0000" face="Arial">Tim Child</font><font face="Arial"> (Creator/Producer) and </font><font
color="#FF0000" face="Arial">Jason Karl</font><font face="Arial"> (Winner, Series
2). TES was also mentioned on the Sci-Fi channel after an repeat episode of
Knightmare in February 1996. A 15-second address card brought in lots of new readers!</font></p>
<p><font face="Arial">Part of The Eye Shield's role was to start a '</font><font
color="#FF0000" face="Arial">Bring Back Knightmare</font><font face="Arial">' campaign.
Indeed many readers wrote in to CITV and other channels demanding Knightmare's return, but
they were not interested. </font></p>
<p><font face="Arial">The magazine's last issue was in December 1997, two years after its
launch. Unfortunately, there were fewer and fewer readers each issue so Paul decided it
was time for a break from producing the magazine, in order to devote his spare time and
resources to get a bigger fan base for the magazine, and in particular - the BBK campaign.
It would then be re-launched.</font></p>
<p> After I set this site up in January 1999, I have managed
to contact Paul and it was agreed that this was the perfect opportunity to re-launch the
magazine and the Bring Back Knightmare Campaign. Paul sent me all the issues,
except Issue 9 which was sent to me by <font color="#FF0000">Jake Collins</font>.
You can now find all the issues on this site.</p>
<p>And thanks to Jake, TES was re-launched in July 2001 and new issues are
now available on the site! However, the BBK campaign has now been taken over by <font color="#FF0000">Alan
Boyd</font>. See <a href="http://www.bringbackknightmare.co.uk" target="_blank">http://www.bringbackknightmare.co.uk</a>
for more details. </p>
<p><font face="Arial">If you have any comments, questions, ideas or contributions
regarding TES, you can e-mail the Editor using the address at the top of this page.</font></p>
<p align="center"><a href="issues.htm"> Issue Contents</a> : <a
href="bbk.htm">Bring Back Knightmare</a><br>
<a href="../page1.htm"> Knightmare Home</a></p></body></html>
Last edited by Devanté on 28 Oct 2005, 21:29, edited 1 time in total.
-
- Level 2 Dungeoneer
- Posts: 202
- Joined: 16 Oct 2005, 20:16
- Location: Carlisle
Re:Coding Errors, Ways To Make Code Shorter etc.
Hmmm, I've used Dreamweaver, it's pretty easy to use but I've gotten rid of it now. The code looks good to me so far. I can't really make any suggestions with this though, I'm not smart enough. ![Wink ;)](./images/smilies/wink.gif)
![Wink ;)](./images/smilies/wink.gif)
Whereever you go, there you are
-
- Dungeoneer
- Posts: 27
- Joined: 22 Oct 2005, 15:51
Re:Coding Errors, Ways To Make Code Shorter etc.
I just quickly typed this out so there will probably be a mistake or two, this is just an estimate of what the HTML for the Eye Shield page is.
Last edited by Devanté on 29 Oct 2005, 08:15, edited 1 time in total.
-
- Level 1 Dungeoneer
- Posts: 65
- Joined: 17 Nov 2002, 22:53
- Location: West Midlands
Re:Coding Errors, Ways To Make Code Shorter etc.
You could always do what's known as "content wrapping", your current host supports this.Illusion wrote: Thanks for raising this, Devanté.
I am aware that there are literally hundreds of coding errors throughout the site. This is mostly because the bulk of the original pages were made using rubbish HTML editors many years ago.
I'd love to re-do the whole site, clean up the coding, re capture images and video at higher quality, but unfortunatly finding the time to do it will be extremely difficult.
Uses technology called PHP. At a very simple level, all you do is make one file for the top half of each page (for example, the headers and site links) and one for the bottom of each page (copyright and contact details for example).
Then you just make separate pages for the bits in between and have a little script that sticks them all together and puts them on the screen for the visitors.
Benefits of all this is, saves time in the long run as once you've converted the pages once, no need to do it again as if or when you decide to change the layout/colours/design, just alter the wrappers and everything else will take care of itself.
You could always throw some of the work out to the community as well, I suppose.
Yes I'm still here. Do you know who I am?
-
- Level 1 Dungeoneer
- Posts: 65
- Joined: 17 Nov 2002, 22:53
- Location: West Midlands
Re:Coding Errors, Ways To Make Code Shorter etc.
Something like this:
Open a new file in Notepad, save it as index.php and put this in it:
Now make another file called header.inc and put this in it:
Finally, make another file called footer.inc and put this in it:
Upload all three files to a folder on the server, ensure that they're all in the same folder together and then go to that page on the server.
That's all there is to it. Can be made as simple or as complicated as you like.
Open a new file in Notepad, save it as index.php and put this in it:
Code: Select all
<?php
include("header.inc");
?>
<h3>This is the main content of your page</h3>
<p>If you right click me and choose View Source, you'll see that I've stuck three bits of HTML together to make a web page!</p>
<?php
include("footer.inc");
?>
Code: Select all
<html>
<head>
<title>Test Page Type Thing</title>
</head>
<body>
Code: Select all
</body>
</html>
That's all there is to it. Can be made as simple or as complicated as you like.
Yes I'm still here. Do you know who I am?
Who is online
Users browsing this forum: No registered users and 11 guests