I got several PHP pages that need a season ID.
The BASIC page checks te season VALUE by this
I use the dymanic script to load the NEXT and the PREVIOUS season, this works fine.PHP Code:if
(isset($_REQUEST['id']))
// is there a POST or GET ?
// if so put it in the needed VAR
{
$Season_ID = $_REQUEST['id'];
}
//if not
elseif
(isset($_SESSION['Season_ID']))
{
// is there a session containing the VAR season_ID ?
// if so read put it is Season_ID' .
$Season_ID = $_SESSION['Season_ID'];
}
//if no session to
else
{
// ... tha we must us de default value for season_ID.
$Season_ID=$af_current_seasonID;
}
But wat if the visitor wants to jump to a 10 or 20 year back, Then the PREVIOUS option is not good.
So I want offer a pulldown menu
http://www.dynamicdrive.com/dynamici...jaxcontent.htm
I can't get it workingHTML Code:<form> <select id=\"ajaxmenu\" size=\"1\"> <option value=''>Season?</option> <option value='external/games.php?id=104'>2008-2009</option> <option value='external/games.php?id=103'>2007-2008</option> <option value='external/games.php?id=102'>2006-2007</option> <option value='external/games.php?id=101'>2005-2006</option> <option value='external/games.php?id=100'>2004-2005</option> <option value='external/games.php?id=99'>2003-2004</option> <option value='external/games.php?id=98'>2002-2003</option> <option value='external/games.php?id=97'>2001-2002</option> <option value='external/games.php?id=96'>2000-2001</option> <option value='external/games.php?id=95'>1999-2000</option> </select> <input type=\"button\" onClick=\"ajaxcombo('ajaxmenu', 'contentarea')\" value=\"oke\" /> </form>";
the recieving page is called games.php and the DIV <CONTENT>
and is this the ONLY
<script type="text/javascript">
/***Combo Menu Load Ajax snippet**/
function ajaxcombo(selectobjID, loadarea){
var selectobj=document.getElementById? document.getElementById(selectobjID) : ""
if (selectobj!="" && selectobj.options[selectobj.selectedIndex].value!="")
ajaxpage(selectobj.options[selectobj.selectedIndex].value, loadarea)
}
</script>



Reply With Quote

Bookmarks