PDA

View Full Version : 1.5 beta 1 - Calendar bug


eon
02-02-2006, 10:24 AM
This bug appears when you enter a pixelpost-site and the owner use the calendar.

Normally the url is like this:
www.test.com

When you try the calendar and press << to go back in history the url is like this:
www.test.com/index.php?curr_month=1&curr_year=2006&showimage=
Notice there is no showimage-number! This will redirect you to the "404 Not Found Don't do that! go back to index.php!"-page for safety reasons.

Solution: calendar.php ~row 204:
$showimage = $_GET['showimage'];

if (empty($showimage)){
$showimage=$image_id;
}

After calendar.php gets the showimage-number, check if the variable ($shownimage) is empty. If it is empty fill it with the current image-id ($image_id).

Joe[y]
02-02-2006, 03:30 PM
this will be fixed in time for the next release. thanks.

se.nsuo.us
03-16-2006, 04:52 AM
slightly safer option

$showimage = (int)$_GET['showimage'];

if ($showimage == 0){
$showimage=$image_id;
}

GeoS
03-16-2006, 11:08 PM
Fixed on CVS.

Topic closed.