<% @ Language="VBScript" %> <% Option Explicit %> Romanian Properties Ltd: Properties in Romania, Investment, Brasov, Black Sea, Transylvania, Bucharest

Newsletter

Shortcuts

Available Properties For Sale

<% 'Response.Write ("Properties between " & Request.Form("minvaluea") & " and " & Request.Form("maxvaluea") & "") 'declare your variables Dim min_value, max_value, area Dim recordset, recordsetwrite,areawrite,propertytypewrite Dim sConnString, sConnStringwrite,connection, connectionwrite, sSQL Const adUseClient = 3 area=Request.QueryString("area") if Request.QueryString("R1")="New" then min_value = -1 max_value = -1 else min_value = -2 max_value = -2 end if propertytypewrite=max_value areawrite=area 'declare SQL statement that will query the database 'sSQL = "INSERT into prop (name, val, email, comments) values ('" & _ 'name & "', '" & val & "','" & email & "', '" & comments & "')" sSQL="SELECT * FROM prop" 'create an ADO connection object Set connection = Server.CreateObject("ADODB.Connection") Set recordset = Server.CreateObject("ADODB.Recordset") 'define the connection string, specify database 'driver and the location of database sConnString="PROVIDER=Microsoft.Jet.OLEDB.4.0;" & _ "Data Source=" & Server.MapPath("cgi-bin/PIYRWLJGDAMBCZ.ASP") 'Open the connection to the database Connection.Open sConnString 'execute the SQL recordset.CursorLocation = adUseClient Recordset.Open sSQL, Connection connection.execute(sSQL) Dim pic Dim counter counter=0 Do while Not recordset.eof if recordset("area") = area and recordset("status")="Available" or area = "Romania" and recordset("status")="Available" then if(max_value=-2) then counter=counter+1 else if(max_value=-1 and recordset("new")="yes" and recordset("status")="Available" ) then counter=counter+1 else if max_value=99999 and recordset("val")>-1 and recordset("val")=<100000 and recordset("status")="Available" Then counter=counter+1 else if max_value=200000 and min_value=100000 and recordset("val")=<200000 and recordset("val")>100000 and recordset("status")="Available" Then counter=counter+1 else if min_value=200001 and recordset("val")>200000 and recordset("status")="Available" Then counter=counter+1 end if end if end if end if end if end if recordset.MoveNext loop if counter < 2 then Response.Write "

Search Result: " & counter & " property found



" else Response.Write "

Search Result: " & counter & " properties found



" end if if counter = 0 Then Response.Write "
Please broaden your search to a larger area or type of property." Response.Write "
Alternatively you can phone us +44(0)870 224 2942 or email us at Sales@RomanianPropertiesLtd.co.uk and we shall be able to find the right property to suit your budget and your needs." Response.Write "

Thank you" Response.Write "

Romanian Properties Ltd" end if 'not supported recordset.Sort = "val" recordset.Movefirst dim truefalse Do while Not recordset.eof truefalse=false if (recordset("area") = area or area = "Romania") and recordset("status")="Available" then if(max_value=-2) then truefalse=true else if(max_value=-1 and recordset("new")="yes") and recordset("status")="Available" then truefalse=true else if recordset("val")=<100000 and recordset("val")>-1 and max_value=99999 and recordset("status")="Available" Then truefalse=true else if recordset("val")=<200000 and recordset("val")>100000 and max_value=200000 and min_value=100000 and recordset("status")="Available" Then truefalse=true else if recordset("val")>200000 and min_value=200001 and recordset("status")="Available" Then truefalse=true end if end if end if end if end if end if if truefalse=true then area=Request.QueryString("area") Response.Write "" Response.Write " " Response.Write " " if recordset("val")=-1 then response.write " " if len(recordset("Picture1"))>2 then pic = "../properties/" & recordset("Picture1") else pic = "../map/" & recordset("county") & ".jpg" end if Response.Write "" Response.Write " " Response.Write "" Response.Write " " Response.Write " " Response.Write " " Response.Write " " Response.Write "
 Price: Contact us - " else Response.Write "  " & recordset("valcoma") & " euros - " end if if recordset("type") = "Villa" or recordset("type") = "Apartment" or recordset("type") = "House" then Response.Write recordset("bedrooms") & " Bedroom " & recordset("type") else Response.Write recordset("type") end if Response.Write " - " & recordset("status") & "" Dim link if recordset("ref")= "1098" then link = "off-plan-bucharest.htm" else if recordset("ref")= "418" then link = "off-plan-black-sea.htm" else if recordset("ref")= "406" then link = "off-plan-brasov.htm" else link = "property.asp?ref=" & recordset("ref") end if end if end if if now() - recordset("dateentry") < 30 then Response.Write " - NEW" end if Response.Write "
" & recordset("town") & "


" Response.Write "

"& recordset("headline") &"

" Response.Write "" Response.Write "" Response.Write "" Response.Write "
More details
" Response.Write "

" End if recordset.MoveNext loop Response.Write "

" ' Done. Close the connection object recordset.Close Set recordset = Nothing connection.Close Set connection = Nothing sConnStringwrite="PROVIDER=Microsoft.Jet.OLEDB.4.0;" & _ "Data Source=" & Server.MapPath("cgi-bin\piyrwljgdambcz.asp") Set connectionwrite = Server.CreateObject("ADODB.Connection") Set recordsetwrite = Server.CreateObject("ADODB.Recordset") connectionwrite.Open sConnStringwrite sSQL="SELECT * FROM search" recordsetwrite.Open sSQL, Connectionwrite,2,2 recordsetwrite.addnew recordsetwrite("date2") = now() recordsetwrite("area2") = areawrite recordsetwrite("propertytype2") = propertytypewrite recordsetwrite.Update recordsetwrite.Close Set recordsetwrite = Nothing connectionwrite.Close Set connectionwrite = Nothing %>
Back to the search page