aris
01-10-2004, 11:09 AM
Hello Papa and All,
I am kind of newbie with scripts and php and have 2 hours that I found Easily Simple Calendar and still trying to make it work.
The demo.php is working fine but I have tried to have the script running in a .php page with other content as well.
The page is working fine and displays correctly the calendar for January 2004 but the links to next and previous months seem not to work!
I just copied the following code from the demo.php and entered it in the .php file (template1.php).
(Please note that the script files are all in the folder "calendar" but I want to display the calendar in other pages outside that folder...)
<div align="center">
<?php require ("http://www.domain.com/calendar/escal.php"); ?>
</div>
<?php
$yb=$yr;
$yf=$yr;
$mb=$mo-1;
if ($mb<1) {$mb=12; $yb=$yr-1;}
$mf=$mo+1;
if ($mf>12) {$mf=1; $yf=$yr+1;}
?>
<table width="175" border="0" cellspacing="0" cellpadding="0" align="center">
<tr>
<td><font face="Verdana, Arial, Helvetica, sans-serif" size="1"><a href="<?php echo "http://www.domain.com/template1.php?mo=$mb&yr=$yb" ?>"><<</a></font></td>
<td align="center"><font face="Verdana, Arial, Helvetica, sans-serif" size="1"><a href="<?php echo "http://www.domain.com/template1.php" ?>">-=-</a></font></td>
<td align="right"><font face="Verdana, Arial, Helvetica, sans-serif" size="1"><a href="<?php echo "http://www.domain.com/template1.php?mo=$mf&yr=$yf" ?>">>></a></font></td>
</tr>
</table>
The problem is that when I click on the Next or Previous month, the calendar still displays (correctly) only January and not the correct month.
Here is the URL displayed for the Next month of January that reloads the page and still displays only January:
http://www.domain.com/template1.php?mo=1&yr=
I guess this should be the problem. I don't use MySQL but the esdates.txt file that is working fine for January (it's the only I can see :( )
I would really appreciate your feedback and let me suggest that you enrich the instructions.htm file for newbies like me :)
Lastly, when I click on the date marked for an event I receive a PageNotFound pop-up window. Could anyone give me more info what is this and how I could turn this feature off?
Thank you so much for your help!!!
Aris
(Athens, Greece)
- The script seems to be really great. Thanks again and continue this excellent work!
I am kind of newbie with scripts and php and have 2 hours that I found Easily Simple Calendar and still trying to make it work.
The demo.php is working fine but I have tried to have the script running in a .php page with other content as well.
The page is working fine and displays correctly the calendar for January 2004 but the links to next and previous months seem not to work!
I just copied the following code from the demo.php and entered it in the .php file (template1.php).
(Please note that the script files are all in the folder "calendar" but I want to display the calendar in other pages outside that folder...)
<div align="center">
<?php require ("http://www.domain.com/calendar/escal.php"); ?>
</div>
<?php
$yb=$yr;
$yf=$yr;
$mb=$mo-1;
if ($mb<1) {$mb=12; $yb=$yr-1;}
$mf=$mo+1;
if ($mf>12) {$mf=1; $yf=$yr+1;}
?>
<table width="175" border="0" cellspacing="0" cellpadding="0" align="center">
<tr>
<td><font face="Verdana, Arial, Helvetica, sans-serif" size="1"><a href="<?php echo "http://www.domain.com/template1.php?mo=$mb&yr=$yb" ?>"><<</a></font></td>
<td align="center"><font face="Verdana, Arial, Helvetica, sans-serif" size="1"><a href="<?php echo "http://www.domain.com/template1.php" ?>">-=-</a></font></td>
<td align="right"><font face="Verdana, Arial, Helvetica, sans-serif" size="1"><a href="<?php echo "http://www.domain.com/template1.php?mo=$mf&yr=$yf" ?>">>></a></font></td>
</tr>
</table>
The problem is that when I click on the Next or Previous month, the calendar still displays (correctly) only January and not the correct month.
Here is the URL displayed for the Next month of January that reloads the page and still displays only January:
http://www.domain.com/template1.php?mo=1&yr=
I guess this should be the problem. I don't use MySQL but the esdates.txt file that is working fine for January (it's the only I can see :( )
I would really appreciate your feedback and let me suggest that you enrich the instructions.htm file for newbies like me :)
Lastly, when I click on the date marked for an event I receive a PageNotFound pop-up window. Could anyone give me more info what is this and how I could turn this feature off?
Thank you so much for your help!!!
Aris
(Athens, Greece)
- The script seems to be really great. Thanks again and continue this excellent work!