Two questions...

liunx

Guest
Hi, i am buildin a site and need to position a logo over half of a table, but i dont know how to go about this, also does ne one know the code to get the date to update daily, e.g. 11th May 2002 <-- updates each day, <br />
Thanx in advance, Wimbo:)<!--content-->yes its java script. heres the code:<br />
<br />
<script><br />
var dayarray=new Array("Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday")<br />
var montharray=new Array("January","February","March","April","May","June","July","August","September","October","November","December")<br />
<br />
function getthedate(){<br />
var mydate=new Date()<br />
var year=mydate.getYear()<br />
if (year < 1000)<br />
year+=1900<br />
var day=mydate.getDay()<br />
var month=mydate.getMonth()<br />
var daym=mydate.getDate()<br />
if (daym<10)<br />
daym="0"+daym<br />
var hours=mydate.getHours()<br />
var minutes=mydate.getMinutes()<br />
var seconds=mydate.getSeconds()<br />
var dn="AM"<br />
if (hours>=12)<br />
dn="PM"<br />
if (hours>12){<br />
hours=hours-12<br />
}<br />
if (hours==0)<br />
hours=12<br />
if (minutes<=9)<br />
minutes="0"+minutes<br />
if (seconds<=9)<br />
seconds="0"+seconds<br />
//change font size here<br />
var cdate="<small><font color='000000' face='Arial'><b>"+dayarray[day]+", "+montharray[month]+" "+daym+", "+year+" "+hours+":"+minutes+":"+seconds+" "+dn<br />
+"</b></font></small>"<br />
if (document.all)<br />
document.all.clock.innerHTML=cdate<br />
else if (document.getElementById)<br />
document.getElementById("clock").innerHTML=cdate<br />
else<br />
document.write(cdate)<br />
}<br />
if (!document.all&&!document.getElementById)<br />
getthedate()<br />
function goforit(){<br />
if (document.all||document.getElementById)<br />
setInterval("getthedate()",1000)<br />
}<br />
<br />
</script><br />
<span id="clock"></span><br />
<body onLoad="goforit()"><!--content-->Make the logo's image the size of the table and make half of it transparent. Then set it as the tables background.<br />
<br />
Warning! Netscrap 4 does odd things with table backgrounds, like tiling them per cell. I think there are ways round it but I don't know them off the top of my head. If you get this problem then post in the Cross Platform Layout forum and Scoutt (the NS lover) will come along and help out.<!--content-->Thanx both of u, helped a lot:D<!--content-->
 
Back
Top