Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

Coding Forum


You are currently viewing our Coding Forum as a guest. Please register to participate.
Login



Reply
Day = NoImage. Night = YesImage. . . Possible?
Old 11-08-2003, 12:40 PM Day = NoImage. Night = YesImage. . . Possible?
wbstein's Avatar
Super Talker

Posts: 122
Location: Maryland, USA
Trades: 0
Hey,

I need to find a way, to make certain code appear at night, and the code dissappear in the day.

In other words.
picture.jpg only appears on my website at night time.

any suggestions?
wbstein is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 11-08-2003, 04:25 PM
wbstein's Avatar
Super Talker

Posts: 122
Location: Maryland, USA
Trades: 0
I think I should have been a little more specific.

In the day, I want to keep my site looking clean, and modest. But at night, I don't mind the traffic to see banner ads.

Here is the code I want to be valid at night.




Code:
<table width="500" border="0" cellspacing="0" cellpadding="0"> 
  
  <tr> 
    <td><a href="http://www.BannersGoMLM.com/cgi-bin/ads/left/ads_nonssi.pl?advert=NonSSI&page=willstein.146866" target="_blank"> 
      <img src="http://www.BannersGoMLM.com/cgi-bin/ads/left/ads_nonssi.pl?ID=bgmlm&page=willstein.146866" width="250" height="72" border="0"></a></td> 
    <td><a href="http://www.BannersGoMLM.com/cgi-bin/ads/right/ads_nonssi.pl?advert=NonSSI&page=willstein.146866" target="_blank"> 
      <img src="http://www.BannersGoMLM.com/cgi-bin/ads/right/ads_nonssi.pl?ID=bgmlm&page=willstein.146866" width="250" height="72" border="0"></a></td> 
  </tr> 
  <tr> 
    <td colspan="2"><a href="http://BannersGoMLM.com/cgi-bin/ref/index.cgi?dist=willstein" target="_blank"> 
      <img src="http://BannersGoMLM.com/images/codebottom.gif" width="500" height="19" border="0"></a></td> 
  </tr> 
</table> 


<div align="left"> 
  <SCRIPT LANGUAGE="JavaScript"> 
banner = '<TABLE CELLSPACING=0 CELLPADDING=0><TR><TD><A HREF="http://www.1800banners.com/cgi-bin/bpwork2.cgi?advert=NonSSI&page=44">' 
banner += '<IMG SRC="http://www.1800banners.com/cgi-bin/bpwork2.cgi?ID=willstein&page=44" ALT="1800Banners.com – Free Banner Exchange" BORDER=0 width=468 height=60></a></TD>' 
banner += '</TR><TR><TD><A HREF="http://www.1800banners.com"><IMG BORDER=0 SRC="http://www.1800banners.com/logo.gif" ALT="1800Banners.com – Free Banner Exchange"></A></TD></TR></TABLE>' 
document.write(banner) 
// --> 
</SCRIPT> 
  <NOSCRIPT> 
  <TABLE CELLSPACING=0 CELLPADDING=0> 
    <TR> 
      <TD><A HREF="http://www.1800banners.com/cgi-bin/bpwork2.cgi?advert=NonSSI&page=44"><IMG SRC="http://www.1800banners.com/cgi-bin/bpwork2.cgi?ID=willstein&page=44" ALT="1800Banners.com – Free Banner Exchange" BORDER=0 width=468 height=60></a></TD> 
    </TR> 
    <TR> 
      <TD><A HREF="http://www.1800banners.com"><IMG BORDER=0 SRC="http://www.1800banners.com/logo.gif" ALT="1800Banners.com – Free Banner Exchange"></A></TD> 
    </TR> 
  </TABLE> 
  </NOSCRIPT> 
</div> 
<iframe src="http://rfbe.com/iframe/?id=1793&bn=1&pg=1295" width=468 height=60 marginwidth=0 marginheight=0 scrolling=no frameborder=0><a href="http://rfbe.com/href/?id=1793&bn=1&pg=1295" target="_top"><img src="http://rfbe.com/banner/?id=1793&bn=1&bt=0&pg=1295" alt="Relmax Flash Banner Exchange" width=468 height=60 border=0></a></iframe> 
<p> </p> 
<div align="left"> 
  <iframe src="http://leader.linkexchange.com/X1720316/showiframe?" width=468 height=60 marginwidth=0 marginheight=0 hspace=0 vspace=0 frameborder=0 scrolling=no> 
  <a href="http://leader.linkexchange.com/X1720316/clickle" target="_top"><img width=468 height=60 border=0 ismap alt="" src="http://leader.linkexchange.com/X1720316/showle?"></a></iframe> 
  <br> 
  <a href="http://leader.linkexchange.com/X1720316/clicklogo" target="_top"><img src="http://leader.linkexchange.com/X1720316/showlogo?" width=468 height=16 border=0 ismap alt=""></a><br> 
</div>


This might be hard for a script to do, but if not, is there some sort of way to "auto upload" an html document?

Is there some program that might do it?

Thanks.
wbstein is offline
Reply With Quote
View Public Profile
 
Old 11-11-2003, 12:55 PM
scottfree's Avatar
Extreme Talker

Posts: 234
Location: Hamburg
Trades: 0
Just one thing you should consider, it isn´t night time at the same time everywhere on the internet so an autoupload or similar would only work if you want it changed according to the time in a certain timezone.
I am not a whizz but I think this will be possible to do with php or perl if you use the localtime function to check the time and then produce the page. I may be wrong as the localtime may just check the time on the server and not on the user´s computer. Maybe someone else can help.
Good luck.
__________________
I think, therefore I am..... I think.
scottfree is offline
Reply With Quote
View Public Profile Visit scottfree's homepage!
 
Old 11-16-2003, 06:26 PM
Experienced Talker

Posts: 31
Location: Redondo Beach, CA
Trades: 0
If you only care about a limited area like the US, you can use the server time which will be accessible through any server sided application language (php, perl, asp, coldfusion, C, Java, whatever).

To get the local time you will absolutely need a client side programming language like javascript.

I didn't really check this out, but found this quickly from google.

http://martin.f2o.org/php/localtime

Even then it won't be perfect as many people have their clocks way off on their computers.
__________________
Myrealtypage - Real Estate Web Design
myrealtypage is offline
Reply With Quote
View Public Profile Visit myrealtypage's homepage!
 
Reply     « Reply to Day = NoImage. Night = YesImage. . . Possible?
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.33507 seconds with 12 queries