Your Ad Here Your Ad Here
Results 1 to 4 of 4

Thread: How to make a page with daily updated image?

  1. #1
    100%'s Avatar ╚════╩═╬════╝
    Join Date
    Jan 2003
    Posts
    13,671
    I would like to make a webpage - which hotlinks the images
    from other sites. These images change every day.....

    I basically want to do the same as what this guy has done http://miette.develooper.com/~ask/comics/ but with my own choice.

    for example
    http://images.ucomics.com/comics/nq/2005/nq050129.gif

    but tommorrow it will be: nq050130.gif
    etc etc

    the image for example is taken from this page - http://www.ucomics.com/nonsequitur/

    is there any trick so it will automatically find the latest image eg "*.gif"?


    thanx

    Code:
    <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
    <html>
    <HEAD>
    <P><BR><FONT FACE="Arial, sans-serif">Nonsequitur -
    </FONT><A HREF="http://www.ucomics.com/nonsequitur/" TARGET="_blank"><FONT FACE="Arial, sans-serif">http://www.ucomics.com/nonsequitur/</FONT></A><BR>
    <img src="http://images.ucomics.com/comics/nq/2005/nq050129.gif">
    </center>
    </body>
    </html>
    Last edited by 100%; 01-29-2005 at 09:31 AM.

  2. Internet, Programming and Graphics   -   #2
    vivitron 15's Avatar Poster
    Join Date
    Jan 2003
    Location
    North East England, UK
    Posts
    1,772
    a php script will do this nicely:
    Code:
    <?php
    $year=date("Y"); $month=date("m"); $day=date("j"); $time=date("H"); 
    
    print("<img src=\"http://images.ucomics.com/comics/nq/2005/" .$year . $month . $day . ".gif alt=\"weathermap\" />");
    
    ?>
    thats off the top of my head, but should work
    <insert signature here>

  3. Internet, Programming and Graphics   -   #3
    100%'s Avatar ╚════╩═╬════╝
    Join Date
    Jan 2003
    Posts
    13,671
    thanx
    do i save that as a php or html? is that finished or do in need to put that under html header etc
    im dont know much about php.

  4. Internet, Programming and Graphics   -   #4
    vivitron 15's Avatar Poster
    Join Date
    Jan 2003
    Location
    North East England, UK
    Posts
    1,772
    put all the headers etc on that you would for html, and put my code in the <body> then save as php, should work
    <insert signature here>

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •