bene! direi che ci siamo quasi ma forse ho sbagliato qualcosa...

mi carica il null nella casella nomeitinerario ma contemporaneamente mi dà questo errore

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /var/www/netsons.org/itinerarimondo/itinerari.php on line 317


in pratica qui sotto hai il codice dall linea 316 alla 322:

<?php
mysql_free_result($rs_nomeitinerario);

mysql_free_result($rs_nazioni);

mysql_free_result($rs_nomecontinente);
?>

per sicurezza ti ricopio nuovamente il codice di tutta la pagina con le modifiche suggerite da te, sperando di averle ben recepite:

<?php require_once('Connections/server.php'); ?>
<?php
if (!function_exists("GetSQLValueString")) {
function GetSQLValueString($theValue, $theType, $theDefinedValue = "", $theNotDefinedValue = "")
{
$theValue = get_magic_quotes_gpc() ? stripslashes($theValue) : $theValue;

$theValue = function_exists("mysql_real_escape_string") ? mysql_real_escape_string($theValue) : mysql_escape_string($theValue);

switch ($theType) {
case "text":
$theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL";
break;
case "long":
case "int":
$theValue = ($theValue != "") ? intval($theValue) : "NULL";
break;
case "double":
$theValue = ($theValue != "") ? "'" . doubleval($theValue) . "'" : "NULL";
break;
case "date":
$theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL";
break;
case "defined":
$theValue = ($theValue != "") ? $theDefinedValue : $theNotDefinedValue;
break;
}
return $theValue;
}
}

if (!function_exists("GetSQLValueString")) {
function GetSQLValueString($theValue, $theType, $theDefinedValue = "", $theNotDefinedValue = "")
{
$theValue = get_magic_quotes_gpc() ? stripslashes($theValue) : $theValue;

$theValue = function_exists("mysql_real_escape_string") ? mysql_real_escape_string($theValue) : mysql_escape_string($theValue);

switch ($theType) {
case "text":
$theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL";
break;
case "long":
case "int":
$theValue = ($theValue != "") ? intval($theValue) : "NULL";
break;
case "double":
$theValue = ($theValue != "") ? "'" . doubleval($theValue) . "'" : "NULL";
break;
case "date":
$theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL";
break;
case "defined":
$theValue = ($theValue != "") ? $theDefinedValue : $theNotDefinedValue;
break;
}
return $theValue;
}
}

mysql_select_db($database_server, $server);
if($_GET['IDnazione'] && $_GET['IDnazione'] > 0)
{
$query_rs_nomeitinerario = "SELECT itinerarioID, nomeitinerario, nazioni FROM tbl_itinerari WHERE nazioni = $_GET[IDnazione] ORDER BY nomeitinerario ASC";
$rs_nomeitinerario = @mysql_query($query_rs_nomeitinerario, $server) or die(mysql_error());
$row_rs_nomeitinerario = @mysql_fetch_assoc($rs_nomeitinerario);
$totalRows_rs_nomeitinerario = @mysql_num_rows($rs_nomeitinerario);
}

mysql_select_db($database_server, $server);
$query_rs_nazioni = "SELECT nazioneID, nomenazione FROM tbl_nazioni ORDER BY nomenazione ASC";
$rs_nazioni = mysql_query($query_rs_nazioni, $server) or die(mysql_error());
$row_rs_nazioni = mysql_fetch_assoc($rs_nazioni);
$totalRows_rs_nazioni = mysql_num_rows($rs_nazioni);

mysql_select_db($database_server, $server);
$query_rs_nomecontinente = "SELECT continenteID, nomecontinente FROM tbl_continenti ORDER BY nomecontinente ASC";
$rs_nomecontinente = mysql_query($query_rs_nomecontinente, $server) or die(mysql_error());
$row_rs_nomecontinente = mysql_fetch_assoc($rs_nomecontinente);
$totalRows_rs_nomecontinente = mysql_num_rows($rs_nomecontinente);
?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">

<head>

<title>Itinerari</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<link rel="stylesheet" href="mm_travel2.css" type="text/css" />
<script language="JavaScript" type="text/javascript">
//--------------- LOCALIZEABLE GLOBALS ---------------
var d=new Date();
var monthname=new Array("Gennaio","Febbraio","Marzo","Aprile","Maggi o","Giugno","Luglio","Agosto","Settembre","Ottobre ","Novembre","Dicembre");
//Ensure correct for language. English is "1 Gennaio, 2004"
var TODAY = d.getDate() + " " + monthname[d.getMonth()] + " " + d.getFullYear();
//--------------- END LOCALIZEABLE ---------------
</script>
<style type="text/css">
<!--
@import url("mm_travel3.css");
.ws22 {font-size: 29px;}
.Stile23 {font-size: 24px}
#menuverticale {
position:absolute;
width:178px;
height:256px;
z-index:1;
left: 1px;
top: 192px;
border-top-width: 0px;
border-right-width: 0px;
border-bottom-width: 0px;
border-left-width: 0px;
border-top-style: none;
border-right-style: none;
border-bottom-style: none;
border-left-style: none;
}
#Layer2 {
position:absolute;
width:750px;
height:20px;
z-index:2;
left: 200px;
top: 200px;
}
#Layer3 {
position:absolute;
width:750px;
height:39px;
z-index:1;
top: 20px;
}
#Layer4 {
position:absolute;
width:200px;
height:115px;
z-index:3;
left: 196px;
top: 473px;
}
#menuorizzontale {
position:absolute;
width:727px;
height:23px;
z-index:2;
left: 237px;
top: 162px;
background-color: #e6f3ff;
}
.Stile54 {
font-size: 14px;
font-family: Geneva, Arial, Helvetica, sans-serif;
}
#itinerario {
position:absolute;
width:795px;
height:907px;
z-index:3;
left: 185px;
top: 192px;
border: 0px none #CCCCCC;
list-style-image: none;
list-style-type: none;
padding-right: 5px;
padding-left: 5px;
}
#Layer7 {
position:absolute;
width:200px;
height:144px;
z-index:4;
left: 964px;
top: 195px;
}
#listamappe {
position:absolute;
width:200px;
height:808px;
z-index:4;
left: 1003px;
top: 193px;
text-indent: 2px;
display: inline;
letter-spacing: normal;
border: 2px solid #CCCCCC;
padding-top: 5px;
padding-right: 5px;
padding-bottom: 5px;
padding-left: 8px;
}
#contactus {
position:absolute;
width:1239px;
height:24px;
z-index:5;
left: 1px;
top: 804px;
border-top-width: 1px;
border-right-width: 1px;
border-bottom-width: 1px;
border-left-width: 1px;
border-top-style: solid;
border-right-style: none;
border-bottom-style: none;
border-left-style: none;
border-top-color: #CCCCCC;
border-right-color: #CCCCCC;
border-bottom-color: #CCCCCC;
border-left-color: #CCCCCC;
padding-top: 5px;
padding-right: 5px;
padding-bottom: 5px;
padding-left: 8px;
}
.Stile56 {
font-family: Verdana, Arial, Helvetica, sans-serif;
color: #0033CC;
font-size: 18px;
font-style: normal;
}
-->
</style>
</head>
<body bgcolor="#C0DFFD">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr bgcolor="#3366CC">
<td colspan="3" rowspan="2">[img]mm_travel_photo.jpg[/img]</td>
<td height="63" colspan="3" align="center" valign="bottom" nowrap="nowrap" id="logo"><div align="center"><span class="pageName Stile8"><span class="pageName Stile10"><span class="pageName Stile8"><span class="pageName Stile14"><span class="pageName Stile16"><span class="pageName Stile14"><span class="pageName Stile8 Stile23"> Itinerari nel Mondo </span></span></span></span></span></span></span></div></td>
<td width="252"></td>
</tr>

<tr bgcolor="#3366CC">
<td height="55" colspan="3" id="tagline" valign="top" align="center"></td>
<td width="252"></td>
</tr>

<tr>
<td colspan="7" bgcolor="#003366">[img]mm_spacer.gif[/img]</td>
</tr>

<tr bgcolor="#CCFF99">
<td colspan="7" id="dateformat" height="25"><script language="JavaScript" type="text/javascript">
document.write(TODAY); </script> </td>
</tr>
<tr>
<td colspan="7" bgcolor="#003366">[img]mm_spacer.gif[/img]</td>
</tr>

<td width="380"></span></td>
</tr> <tr>
<td></td>
</tr>
</table>
<div class="navText Stile54" id="menuorizzontale">
<p align="center" class="bodyText"> Home / I Nostri Viaggi / Forum / Guestbook / Newsgroup / Utilink</p>
</div>
<div id="contactus">
<p class="subHeader">Contact Us | 2007 Marco &amp; Gabriella </p>
</div>


</p>
<table width="27%" border="0" align="center" cellpadding="3" cellspacing="0">
<tr>
<th height="27" valign="middle" scope="col"><span class="Stile56">Cerca l'itinerario </span></th>
</tr>
</table>


</p>


</p>
<table width="95%" border="1" align="center" cellpadding="3" cellspacing="0">
<tr>
<td width="41%">Per Continente </td>
<td width="59%"><form id="frm_percontinente" name="frm_percontinente" method="post" action="">

funzione attualmente non disponibile
</form> </td>
</tr>
<tr>
<td>Per Nazione o Regione italiana </td>
<td><select name="nomenazione" id="nomenazione" onchange="window.location = ('<?php echo $_SERVER['PHP_SELF']; ?>?IDnazione=+nomenazione.options[this.selectedIndex].value')">
<?php
do {
?>
<option value="<?php echo $row_rs_nazioni['nazioneID']?>"><?php echo $row_rs_nazioni['nomenazione']?></option>
<?php
} while ($row_rs_nazioni = mysql_fetch_assoc($rs_nazioni));
$rows = mysql_num_rows($rs_nazioni);
if($rows > 0) {
mysql_data_seek($rs_nazioni, 0);
$row_rs_nazioni = mysql_fetch_assoc($rs_nazioni);
}
?>
</select></td>
</tr>
<tr>
<td>Scegli tra tutti gli itinerari </td>
<td><form id="frm_peritinerario" name="frm_peritinerario" method="post" action="itinerari_dettagli.php">
<select name="nomeitinerario" id="nomeitinerario">
<option value="null">-------</option>
<?php
do {
?><option value="<?php echo $row_rs_nomeitinerario['itinerarioID']?>"><?php echo $row_rs_nomeitinerario['nomeitinerario']?></option>
<?php
} while ($row_rs_nomeitinerario = mysql_fetch_assoc($rs_nomeitinerario));
$rows = mysql_num_rows($rs_nomeitinerario);
if($rows > 0) {
mysql_data_seek($rs_nomeitinerario, 0);
$row_rs_nomeitinerario = mysql_fetch_assoc($rs_nomeitinerario);
}
?>
</select>
<input name="Invia" type="submit" id="Invia" value="Invia" />
</form> </td>
</tr>
</table>
</body>
</html>
<?php
mysql_free_result($rs_nomeitinerario);

mysql_free_result($rs_nazioni);

mysql_free_result($rs_nomecontinente);
?>

grazie molte per la pazienza!