Hey guys, just a quick update.
I contacted my host and they edited my php settings and now I am able to hold values!
The only field I am not currently able to hold is the area.
Code:
<script type="text/javascript">
var slData = new Array(
new Array("Any", "", "Central", "Central", "Burriana", "Burriana", "Capistrano", "Capistrano", "Torrecilla", "Torrecilla", "Punta Lara", "Punta Lara", "Parador", "Parador", "Carabeo", "Carabeo", "Las Minas", "Las Minas", "La Noria", "La Noria", "Tamango Hill", "Tamango Hill", "Countryside", "Countryside"),
new Array("Any", "", "Beach Front", "Beach Front", "Beach Club", "Beach Club", "Torrox Park", "Torrox Park", "Village", "Village", "Peñoncillo", "Penoncillo", "Countryside", "Countryside", "Frigiliana Road", "Frigi Road", "El Morche", "El Morche"),
new Array("Any", "", "Village", "Village", "La Molineta", "La Molineta", "Los Caracoles", "Caracoles", "San Rafael", "San Rafael", "Los Tablazos", "Los Tablazos", "Pinomar", "Pinomar", "Countryside", "Countryside"),
new Array("Any", "", "Beach Front", "Beach Front")
);
function appendOptionLast(selId, oText, oValue)
{
var elOptNew = document.createElement('option');
elOptNew.text = oText;
elOptNew.value = oValue;
var elSel = document.getElementById(selId);
try {
elSel.add(elOptNew, null); // standards compliant; doesn't work in IE
}
catch(ex) {
elSel.add(elOptNew); // IE only
}
return;
}
function onRegionChange()
{
document.getElementById("REGION").options.length = 0;
for(var a = 0; a != slData[document.getElementById("AREA").selectedIndex].length; a = a + 2)
{
appendOptionLast("REGION", slData[document.getElementById("AREA").selectedIndex][a], slData[document.getElementById("AREA").selectedIndex][a + 1]);
}
return;
}
</script>
But for the other town arrays: Torrox, Frigiliana and Maro, the regions aren't sticking, it's resetting the values back to all.
I managed to hold the value of the areas on to my search page using this crazy code:
but that's not holding the area values over to the property.php page..
May I just take this opportunity to thanks all of you that have helped me out on this thread, you've all been excellent!