pinto
12 February 2009 08:12
17
I’m having a little issue/trouble mainly with my mind and a little with the script. Trying to do an am/pm log and for now using the poor man’s method of using the web address to update the log. I’ve made two fc-configs, one am one pm with corresponding logs and uploaded them. This morning’s upload went smoothly but this afternoon’ wiped this mornings data and said 'this forecast has already been run". I did run a new WXSIM forecast which now shows in both charts as 2:35pm.
So am I calling the script incorrectly? Here is a snippet of the code I’m using;
$_REQUEST['config'] = 'fc-configam.php'; // It will default to this one if this isn't included
$_REQUEST['lang'] = 'en'; // This will default to English if not included
include("forecast-compare-include.php");
$_REQUEST['config'] = 'fc-configpm.php'; // It will default to this one if this isn't included
$_REQUEST['lang'] = 'en'; // This will default to English if not included
include("forecast-compare-include.php");
So am I improperly calling the script or improperly calling the wrong web addresses?
Thanks,
Jack
Here is where the script is running…http://stillweather.com/nuforecast_compare.php
I’m testing this with am and pm.
notice, when you are running the latest version(1.1), you have to call the script with the allowed config-files.
in forecast-compare-include is the folowing(whitch you can edit)
$allowed = array ( // You can add additional configuration file names here
'am' => 'fc-configAM.php',
'pm' => 'fc-configPM.php'
);
so, I’m calling the script like this:
forecast-compare-include.php?log&config=am
forecast-config-compare.php?log&config=pm
if you don’t do it like this, you end up using fc-config.php, and not with the configurations you want.
you can call the different logs with:
$_REQUEST['config'] = 'pm';
$_REQUEST['lang'] = 'en';
include("forecast-compare-include.php");