% @Language=VBScript %> <% Option Explicit %> <% PreventPageCaching dim sArea, sTipo, sSearch,sLocalita if request("area") <> "" then sArea = request("area") end if if not dDescArea.Exists(sArea) then response.Redirect("home.asp") sSearch = request("sSearch") dim nRegione, nProvincia, nComune if request("nRegione") <> "" then nRegione = request("nRegione") if nRegione = "" or not isNumeric(nRegione) or sSearch = "NEW" then nRegione = RegioneEmiliaRomagna if request("nProvincia") <> "" then nProvincia = request("nProvincia") if nProvincia = "" or not isNumeric("nProvincia") or sSearch = "NEW" then nProvincia = ProvinciaParma if request("nComune") <> "" then nComune = request("nComune") if nComune = "" or not isNumeric(nComune) or sSearch = "NEW" then nComune = ComuneParma if sLocalita = "" or sSearch = "NEW" then sLocalita = "EMILIA ROMAGNA - PARMA [PARMA]" if nRegione = "0" then nProvincia = "0" nComune= "0" end if if request("bFromForm") = "1" then dim bContinue : bContinue = false dim VENDO, NOME, COGNOME, TELEFONO, E_MAIL, TIPOLOGIA dim INDIRIZZO, LOCALITA, PREZZO, NR_VANI, NOTE, MQ VENDO = request.Form("VENDO") NOME = uCase(request.Form("NOME")) COGNOME = uCase(request.Form("COGNOME")) TELEFONO = uCase(request.Form("TELEFONO")) E_MAIL = uCase(request.Form("E_MAIL")) TIPOLOGIA = uCase(request.Form("TIPOLOGIA")) nRegione = request.Form("nRegione") nProvincia = request.Form("nProvincia") nComune = request.Form("nComune") if nRegione <> "" and isNumeric(nRegione) and nRegione <> "0" and _ nProvincia <> "" and isNumeric(nProvincia) and nProvincia <> "0" and _ nComune <> "" and isNumeric(nComune) and nComune <> "0" then dim REGIONE, PROVINCIA, COMUNE sSQL = "SELECT tblRegioni.sRegione, tblProvince.sProvincia, tblComuni.sComune"&_ " FROM (tblComuni INNER JOIN tblProvince ON tblComuni.codProvincia = tblProvince.sSigla) INNER JOIN tblRegioni ON tblProvince.IDReg = tblRegioni.ID"&_ " WHERE tblRegioni.ID = "&nRegione&" AND tblProvince.ID = "&nProvincia&" AND tblComuni.IdComune = "&nComune&"" set oRS = getRS(sSQL, connstring) if not oRS.eof then REGIONE = uCase(oRS("sRegione")) PROVINCIA = uCase(oRS("sProvincia")) COMUNE = uCase(oRS("sComune")) bContinue = true end if set oRS = Nothing end if INDIRIZZO = uCase(request.Form("INDIRIZZO")) PREZZO = uCase(request.Form("PREZZO")) NR_VANI = uCase(request.Form("NR_VANI")) NOTE = uCase(request.Form("NOTE")) if bContinue then session("sMsgBody") = "
VENDO: | "&uCase(VENDO)&" |
NOME: | "&NOME&" |
COGNOME: | "&COGNOME&" |
TELEFONO: | "&TELEFONO&" |
E_MAIL: | "&E_MAIL&" |
TIPOLOGIA: | "&TIPOLOGIA&" |
REGIONE: | "®IONE&" |
PROVINCIA: | "&PROVINCIA&" |
COMUNE: | "&COMUNE&" |
INDIRIZZO: | "&INDIRIZZO&" |
PREZZO: | "&PREZZO&" € |
NR. VANI: | "&NR_VANI&" |
MQ: | "&MQ&" |
NOTE: | "&NOTE&" |