Dear all - i have something i am trying to achieve...would like to place calendar monthly list page on Dashboard - and it works fine - but when i add code snippet to have month/year selector - it transfers me from dashboard to regular claendar lisst pag. Is there any way to stay on the dashboard page and from there to see another month
i was using this code
$today = getDatePart( db2time( now() ) );
$days=$_SESSION["days"];
$mon=$_SESSION["mon"];
$yr=$_SESSION["yr"];
$selectDate = array($yr, $mon, $days, 0, 0, 0);
$yr1 = addyears($selectDate,-1);
$yr2 = addyears($selectDate,1);
$mon1 = addmonths($selectDate,-1);
$mon2 = addmonths($selectDate,1);
$todayYearFrom = addyears($today,-10);
$todayYearTo = addyears($today,10);
echo "<div class=calendar_navigation >";
if( $yr1[0] >= $todayYearFrom[0]){
echo "<a href=\"Kalendar_dashboard.php?mon=".$mon1[1]."&yr=".$mon1[0]."\"><img src=\"images/arrow-left.png\" alt=prev></a> ";
}
echo "<select id=mselect onchange=\"window.location.href='Kalendar_dashboard.php?mon='+$('#mselect').val()+'&yr='+$('#yselect').val()\">";
for($i=1;$i<=12;$i++)
{
$s="";
if($i==$mon)
$s=" selected";
echo "<option style=\"color:#000;\" value=" . $i . " " . $s . ">" . getMonthNameByNumber ($i, "MMMM") . "</option>";
}
echo "</select> ";
echo "<select id=yselect onchange=\"window.location.href='Kalendar_dashboard.php?mon='+$('#mselect').val()+'&yr='+$('#yselect').val()\">";
for($i=$todayYearFrom[0]; $i<=$todayYearTo[0]; $i++ )
{
$s="";
if($i==$yr)
$s=" selected";
echo "<option style=\"color:#000;\" value=" . $i . " " . $s . ">" . $i . "</option>";
}
echo "</select>";
if( $yr2[0] <= $todayYearTo[0]){
echo " <a href=\"Kalendar_dashboard.php?mon=".$mon2[1]."&yr=".$mon2[0]."\"><img src=\"images/arrow-right.png\" alt=next></a>";
}
echo "</div>";
i replaced only links from calmonthly_list.php - to Kalendar_dashboard php - which is the name of my dashboard...i understansd why this is not working but do not know how to access calmonthly_list page part on dashboard if this is possible.