RSS

LuxCal Forum

The place for questions, suggestions and news about the LuxCal Event Calendar

User:   Password:   Remember Me?   
LuxCal Forum / General / Problems / Another 2.7.1 Problem, Day View (Could just be me)
Posted:  30 Oct 2012 23:05
When using a calendar in a iframe  ?hdr=1&cP=6 in day view there seems to be some days that you can't scroll to.
Here is my code:

<!DOCTYPE html>
<html>

<head>
<meta content="text/html; charset=utf-8" http-equiv="Content-Type">
<meta content="text/html; charset=windows-1252" http-equiv="Content-Type">
<title>Untitled 1</title>
</head>

<body>
<iframe src="cal1/?hdr=1&cP=6" width="100%" height="890px" scrolling="no"></iframe>
</body>

</html>


Example #1: set your calendar to day view go to November 4, 2012 then press the -> and it will stay on Nov 4, 2012 and not go to Nov 5, 2012,
Example #2: Go to November 3, 2013 then click on the -> to go to  November 4, 2013 and it doesnt work.
Example #3: Go to November 2, 2014 then click on the -> to go to November 3, 2014 and it doesn't work.
Example #4: Go to November 1, 2015 then click on the -> to go to November 2, 2015 and it doesn't work.
Example #5: Go to November 5, 2016 then click on the -> to go to November 6, 2016 and it doesn't work.

and so on. (I have only tested November could be happening in other months also)

here is the code from Example #1 arrow buttons
<h4 class="floatC"><a class="noPrint" href="index.php?cD=2012-11-03"><img src="images/arrowl.png" alt="back"/></a><span class="viewHdr">Sunday, November 4, 2012</span><a class="noPrint" href="index.php?cD=2012-11-04"><img src="images/arrowr.png" alt="forward"/></a></h4>


This is where I think the problem is but I don't know how to fix it.

<a class="noPrint" href="index.php?cD=2012-11-04"><img src="images/arrowr.png" alt="forward"/></a>

It should be tomorrow date in thr href not todays date.

it should look like this I think: <a class="noPrint" href="index.php?cD=2012-11-05"><img src="images/arrowr.png" alt="forward"/></a>

It seems like this only happends in the day view and each year the date that doesn't work changes.
Posted:  30 Oct 2012 23:58
I think i fixed it, I changed the views/days.php file

I changed the $nextday =date( "Y-m-d", $tcDate + 86400 ); to $nextday =date( "Y-m-d", $tcDate + 99455 ); so its 1.15 days
and button now works. Maybe has something to do with leap year?
Posted:  31 Oct 2012 18:23
Strange, I don't have this problem on our four test sites.
A leap year shouldn't make any difference; all real date calculations are done through PHP functions. Ok, but one never knows, maybe some rounding.
I will further investigate this, and maybe copy your solution in the next LuxCal version. It certainly doesn't harm.
Posted:  31 Oct 2012 22:20
I am starting to think your software just hate me. This is the second problem that I only have.

Just curious what type of servers are these four test sites (Linux or Windows)? PHP version? Apache or IIS?

I am running Windows Server 2008 R2 Apache 2.4.2 and PHP 5.4.8
Posted:  01 Nov 2012 11:36
LuxCal is very friendly software and loves all users equallysmile

Our test sites are hosted on a Linux server, Apache 2.2.11 and PHP 5.4.0.