Forum Moderators: coopster
say you have a div that holds where the includes should go called #includes you could include the following in a script block
$(function(){
$('select #dropdown').change(function(){
var val = $(this).val();
if(val == 1){
$('#includes').load('include1.php');
}
if(val == 2){
$('#includes').load('include2.php');
}
});
});
This is a very simple example and you will have to do some more work to get it working how you want it. One thing you should consider is what if a user doesn't have js enabled. Unless you know for certain that they will always have js on, you could look at doing something with the querystring. You could also use this to drive the ajax style functionality you are after.