Jump to content

Day of the year


dad47466

Recommended Posts

I have a php file for each day of the year - 0101.php for Jan 1; 0102.php for Jan 2; 0103.php for Jan 3, etc.

I need to bring up January 1st's page on January 1st within a predesigned template.

The site is http://www.springfieldohio.net - and the features in question are"Birthdays" and "Almanac".  Right now, I'm using Java Script redirects - one to select the month, then a second to select the day.  The results open in a new window. 

I am trying to get the results to open in the content section of the page, but the js redirects are not doing it.

I have tried I-frames, but IE inserts scrollbars within the template, and it looks stupid.

I found this:

<?php
$date = date("md");

$handle=opendir('events');
while (($file = readdir($handle))!==false) {
 
    if ($file >= $date) {
        include("events/$file");
        }
}
closedir($handle);
?>

on webdesigns1.com - it places all 366 files within the template.

And changing the argument to if ($file = $date) produces nothing.  I also tried about a dozen different adjustments but with no positive results.

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.