Go Back   Webmaster Malaysia Forum » Website Design & Development » Website Design

Reply
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
  #1 (permalink)  
Old 07-01-2004, 05:56 AM
New kid on the block
 
Join Date: Jan 2004
Location: United Kingdom
Posts: 2
Rep Power: 0
kampungboy is on a distinguished road
Send a message via Yahoo to kampungboy
Unhappy How to make this date center

Hi guys...can somebody help me please...how to make this date center and move little bit down from its original position...at this moment it appears on the left side of my homepage..it can be viewed at this site:

www.geocities.com/mdaidi/index.html

actually i copied this html code from dynamicdrive.com..

Body tag script

<body onLoad="goforit()">


body script

<script>

/*
Live Date Script-
© Dynamic Drive (www.dynamicdrive.com)
For full source code, installation instructions, 100's more DHTML scripts, and Terms Of Use,
visit http://www.dynamicdrive.com
*/


var dayarray=new Array("Sunday","Monday","Tuesday","Wednesday","Thu rsday","Friday","Saturday")
var montharray=new Array("January","February","March","April","May"," June","July","August","September","October","Novem ber","December")

function getthedate(){
var mydate=new Date()
var year=mydate.getYear()
if (year < 1000)
year+=1900
var day=mydate.getDay()
var month=mydate.getMonth()
var daym=mydate.getDate()
if (daym<10)
daym="0"+daym
var hours=mydate.getHours()
var minutes=mydate.getMinutes()
var seconds=mydate.getSeconds()
var dn="AM"
if (hours>=12)
dn="PM"
if (hours>12){
hours=hours-12
}
if (hours==0)
hours=12
if (minutes<=9)
minutes="0"+minutes
if (seconds<=9)
seconds="0"+seconds
//change font size here
var cdate="<small><font color='000000' face='Arial'><b>"+dayarray[day]+", "+montharray[month]+" "+daym+", "+year+" "+hours+":"+minutes+":"+seconds+" "+dn
+"</b></font></small>"
if (document.all)
document.all.clock.innerHTML=cdate
else if (document.getElementById)
document.getElementById("clock").innerHTML=cdate
else
document.write(cdate)
}
if (!document.all&&!document.getElementById)
getthedate()
function goforit(){
if (document.all||document.getElementById)
setInterval("getthedate()",1000)
}

</script>
<span id="clock"></span>

so can anybody tell me how to adjust it...my background is purely accounting...

thank you..

Last edited by kampungboy; 07-01-2004 at 05:55 PM.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 07-01-2004, 07:41 AM
Senior Webmaster
 
Join Date: Oct 2001
Location: Melbourne, AU
Posts: 456
Rep Power: 95
sufyan is on a distinguished road
Hi,

Easiest way to do it is by changing:

Code:
var cdate="<small><font color='000000' face='Arial'><b>"+dayarray[day]+", "+montharray[month]+" "+daym+", "+year+" "+hours+":"+minutes+":"+seconds+" "+dn
+"</b></font></small>"
to

Code:
var cdate="<center><small><font color='000000' face='Arial'><b>"+dayarray[day]+", "+montharray[month]+" "+daym+", "+year+" "+hours+":"+minutes+":"+seconds+" "+dn
+"</b></font></small></center>"
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 07-01-2004, 10:57 AM
Ben-davis's Avatar
Senior Webmaster
 
Join Date: Jan 2002
Location: SoObHanG JhaYa
Posts: 501
Rep Power: 93
Ben-davis is on a distinguished road
Send a message via ICQ to Ben-davis Send a message via Yahoo to Ben-davis
also, you can use :

Quote:
<div align="center">Your code</div>
instead of

Quote:
<center>Your code</center>
__________________
<form name="jump">
<select name="menu" onChange="location=document.jump.menu.options[document.jump.menu.selectedIndex].value;" style="border:1px #393F31 solid;color:#393F31;font:10px Verdana;font-weight:bold;" >
<option value="0" style="background: #9CC8FE" selected>*SELECT-LINKS</option>
<option value="http://www.gengturbo.org/" style="background: #FF0000">GENGTURBO</option>
<option value="http://www.phixelgrafix.com/" target="new" style="background: #C6D607">PHIXELGRAFIX</option>
<option value="http://dailydigital.phixelgrafix.com/" style="background: #FCBC45">OLD-BLOG</option>
<option value="http://www.mesrahosting.net/" style="background: #FF99CC">WEBHOSTING</option>
</select>
</form>
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4 (permalink)  
Old 07-01-2004, 11:10 PM
ardiles's Avatar
Senior Webmaster
 
Join Date: Mar 2003
Location: Kamunting, Perak
Posts: 640
Rep Power: 81
ardiles is on a distinguished road
Send a message via MSN to ardiles Send a message via Yahoo to ardiles
2 working and functional solutions for you... understand it, and use it right!

p/s: it looks like that you have missed the tiny part of HTML that do the BIG part of layout and design... over-looked, heh?
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #5 (permalink)  
Old 07-01-2004, 11:29 PM
mysticmind's Avatar
Super Moderator
 
Join Date: Jun 2001
Location: Mystic Kingdoms
Posts: 2,633
Rep Power: 142
mysticmind will become famous soon enough mysticmind will become famous soon enough
Send a message via Yahoo to mysticmind
tuh laa..
suruh belajar HTML tak mau.
kan dah susah.. huhuhu
:mode-kejam-mula:

soooo.. STUDY THE ROOT! .. la la laaa
__________________
Personal's Blog! - Malaysian Artist!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #6 (permalink)  
Old 09-01-2004, 12:27 PM
white_neck's Avatar
Senior Webmaster
 
Join Date: Jan 2003
Location: dreamland
Posts: 240
Rep Power: 74
white_neck is on a distinguished road
Send a message via Yahoo to white_neck
Quote:
Originally posted by mysticmind
tuh laa..
suruh belajar HTML tak mau.
kan dah susah.. huhuhu
:mode-kejam-mula:

soooo.. STUDY THE ROOT! .. la la laaa
skali lagi..

btul tuh kater abang mysticmind..

blaja html dulu...
blaja basic dulu...

huahhahrhahhahgh
__________________
^_^ <== stay happy
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #7 (permalink)  
Old 09-01-2004, 04:51 PM
Ben-davis's Avatar
Senior Webmaster
 
Join Date: Jan 2002
Location: SoObHanG JhaYa
Posts: 501
Rep Power: 93
Ben-davis is on a distinguished road
Send a message via ICQ to Ben-davis Send a message via Yahoo to Ben-davis
hohoho.... teringat masa mula2 blaja html... kena buat tables guna notepad.... arghhhh...... tapi takpe.... terima kasih netscape composer!!!!
__________________
<form name="jump">
<select name="menu" onChange="location=document.jump.menu.options[document.jump.menu.selectedIndex].value;" style="border:1px #393F31 solid;color:#393F31;font:10px Verdana;font-weight:bold;" >
<option value="0" style="background: #9CC8FE" selected>*SELECT-LINKS</option>
<option value="http://www.gengturbo.org/" style="background: #FF0000">GENGTURBO</option>
<option value="http://www.phixelgrafix.com/" target="new" style="background: #C6D607">PHIXELGRAFIX</option>
<option value="http://dailydigital.phixelgrafix.com/" style="background: #FCBC45">OLD-BLOG</option>
<option value="http://www.mesrahosting.net/" style="background: #FF99CC">WEBHOSTING</option>
</select>
</form>
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #8 (permalink)  
Old 10-01-2004, 09:13 AM
pjal_studio's Avatar
Senior Webmaster
 
Join Date: Jun 2003
Location: Papar, Sabah
Posts: 266
Rep Power: 71
pjal_studio is on a distinguished road
Send a message via Yahoo to pjal_studio
keh! keh! keh! ni mesti pasal mata dah buta ngan semua javascript yg ada.. semua nak interaktif je.. biasala tu, zaman freashie... dpt buat rollover pun dah kembang hidung!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #9 (permalink)  
Old 12-01-2004, 10:15 AM
white_neck's Avatar
Senior Webmaster
 
Join Date: Jan 2003
Location: dreamland
Posts: 240
Rep Power: 74
white_neck is on a distinguished road
Send a message via Yahoo to white_neck
hahahahhaa...
btul 2...

ader freeshies tu.. baru tau skit... blagak dier mcm hustler php jer..

aper2 pun...
jangan malu bertanya kalau tak tau...

biar tanya soalan bodoh..
tp paham aper benda yg kiter tanya tuh...
daripada tak tau, pastu malu nak btanya...
pastu berlagak cam tau...

hahahhahaha....
__________________
^_^ <== stay happy
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #10 (permalink)  
Old 12-01-2004, 01:35 PM
pjal_studio's Avatar
Senior Webmaster
 
Join Date: Jun 2003
Location: Papar, Sabah
Posts: 266
Rep Power: 71
pjal_studio is on a distinguished road
Send a message via Yahoo to pjal_studio
heheheh! aku menyampah sangat ngan org gitu! baru je belajar, dah nak belagak show-off hasil dia.. sekali kritik terus melenting.. ceh! camana nak maju..?
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #11 (permalink)  
Old 13-01-2004, 03:22 AM
mysticmind's Avatar
Super Moderator
 
Join Date: Jun 2001
Location: Mystic Kingdoms
Posts: 2,633
Rep Power: 142
mysticmind will become famous soon enough mysticmind will become famous soon enough
Send a message via Yahoo to mysticmind
aku ingat dulu masa aku belajar HTML..
ada tag < blink> </blink>

jadikan teks berkelip˛ kat netscape.. kat ie tak valid.
skang tag tuh tah laku ke tak tak tau..

pehtuh buat <marquee> ek eleh... rasa cam best jer bila paham guna tag tuh.. wakakakaka

tak kisah la walau apapun pengalaman korang dengan HTML.. yang penting studylah HTML.
__________________
Personal's Blog! - Malaysian Artist!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #12 (permalink)  
Old 14-01-2004, 10:34 AM
ardiles's Avatar
Senior Webmaster
 
Join Date: Mar 2003
Location: Kamunting, Perak
Posts: 640
Rep Power: 81
ardiles is on a distinguished road
Send a message via MSN to ardiles Send a message via Yahoo to ardiles
ha ha ha.... aku ingat aku sorang je memula terpegun dek blink dgn marquee ni...

blink dah deprecated dah... tag zaman jepun punya tu
marquee still working, tapi x digalakkan (buruk & nampak x pro)
kalau utk demo & syok2, bole la try atribut2 marquee yg lain tu kasik power mcm scrolldelay, scrollamount, behavior bgcolor dll...

namun yg paling x dilupakan ialah anti-right click script... inilah benda yg mendorong aku utk kenal & belajar HTML & _Javascript, siap ada collection dr script tahap bodo sampai tahap power! Flash pun ada AS utk script mcm ni jugak kan, ke amik dr JS?
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

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 On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
PHP programmer area Center Malaysia shukri Advertise Your Services 0 21-09-2006 12:43 AM
between 2 date meiji Website Programming 2 29-04-2005 09:44 AM
Date question ngaisteve1 Website Programming 0 11-04-2004 09:07 PM
Dedicated Server in Netmyne Data Center WebHour Other Webmaster-related Services and Promotion 0 09-12-2003 12:42 AM
make ur site dynamic, up to date and informative zumaidi Other Internet Marketing Methods 1 04-05-2003 01:11 AM



All times are GMT +8. The time now is 03:38 AM. Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO 3.1.0 vBulletin skin by ForumMonkeys.com.


WebmasterMalaysia.com is Proudly Hosted by Exabytes Semi Dedicated Server.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59