Just a quick question.
At the moment I have a login script that re-directs to dashboard.php where the user can click a button to retrieve Google Analytics stats for the pre-selected current month and year.
The url for May 2011 is: dashboard.php?month=May&year=2011&submit=Get+Statistics!
So what I am trying to do is have the stats load with the page instead of having to click the button.
The only way I can think to do this is by changing the following line in my login script:
// redirect to secure page
document.location='dashboard.php';
to something like:
// redirect to secure page
document.location='dashboard.php' + <?php echo ?month=currentMonth&year=currentYear&submit=Get+Statistics! ?>';
with the month and year variables set as follows: $currentMonth = date('F'); $currentYear = date('Y');
But this doesn't work, it just goes to dashboard.php as normal.
Any ideas?