Lissa Explains it All:  Web Design Forums  

Go Back   Lissa Explains it All: Web Design Forums > LEIA Archives > Web Site Help > JavaScript/DHTML

Notices

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #1  
Old 12-18-2004, 06:42 AM
11658 11658 is offline
n00bzilla
 
Join Date: Oct 2004
Posts: 5
11658 is an unknown quantity at this point
Exclamation Javascript Includes Coding Problem

Hello. I just started working on Javascript Includes to use on my website. I am trying to use them to place HTML Div layers on my website. I am having a little problem (or big depeding on how you look at it) problem with them. I have posted the coding that i have for both the Javascript file and the HTML file below. I have also given a link to what is created using this coding. What did I do wrong? I know I did or didn't do something but I can't figure what it it is. Please tell me what I did wrong. Is it a coding problem or is it just not possible to place Div layers using JSI? You can post the coding that I need for it to work, but I really don't care. If someone tells me what I did wrong I could probably figure it out myself. Thank you.

HTML file

Code:
<html>
<head>
<title> Games Galore </title>

<script language="JavaScript" src="tp.js"></script>

</head>

<body>

<div id=content style="position:absolute; width:200; height:375; padding:80px; background-color:#000000; overflow:auto;">

<img src="gglogo.jpg" alt="Games Galore">

</div>

</body>
</html>
Javascript Code

Code:
<script language="JavaScript">
document.write('<div id=header style="position:absolute; width:100%; height:75; padding:5px; background-color:#000000; overflow:auto;">');
document.write('<img src="gglogo.jpg" alt="Games Galore">');
document.write('</div>');
document.write('<div id=left style="position:absolute; width:50; height:300; padding:5px; background-color:#000000; overflow:auto;">');
document.write('<img src="gglogo.jpg" alt="Games Galore">');
document.write('</div>');
document.write('<div id=right style="position:absolute; width:50; height:300; padding:5px; background-color:#000000; overflow:auto;">');
document.write('<img src="gglogo.jpg" alt="Games Galore">');
document.write('</div>');
</script>
Result

Result of above code
Sponsored Links
 

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Forum Jump


All times are GMT. The time now is 01:43 AM.


Powered by vBulletin® Version 3.8.3
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.