<%@ Language = 'VbScript' LCID=1049 CodePage=1251 EnableSessionState=True%> <% Option Explicit %> <% Response.CharSet = "windows-1251" %> <% cnn.Open Application("ConnectionString") Randomize 'defining the global variables dim site_id, page_id, strSQL site_id=51 page_id=250 Dim QP_IsInStageMode QP_IsInStageMode = False 'define response properties Response.AddHeader "publisher", "Quantum Art's Q-Publishing 7.6 Wed, 16 Sep 2009 11:27:34 GMT" Response.Expires = -1000 Response.CacheControl = "Private" Response.AddHeader "Pragma", "no-cache" Response.AddHeader "cache-control", "no-cache, no-store, must-revalidate" dim upload_url, base_upload_url, published_status_type_id, object_call_depth Dim AbsUploadURL, UploadURLPrefix, PublishedStatusName Dim QP_IsInFrontend QP_IsInFrontend = True dim object_call_stack(20) upload_url = "/eng/upload/images" site_url = "/eng/live/" base_upload_url = "/eng/upload/" object_call_depth = 0 published_status_type_id=GetMaximumWeightStatusTypeId(51) PublishedStatusName=GetMaximumWeightStatusTypeName(51) FillValues Private Sub object1127O() err.clear %><% Server.ScriptTimeout = 10000 dim connection, SQL, RS, contentName Set connection = Server.CreateObject("ADODB.Connection") connection.ConnectionString = "DSN=akdal_db;" connection.Open contentName = "Кассы агентств" SQL = "select * from List1" 'SQL = "select count(*) as total from [List1]" Set RS = connection.Execute(SQL) While not(RS.EOF) Response.Write RS.Fields("agency") & " - " Response.Write RS.Fields("city") & " - " Response.Write RS.Fields("street") & " - " & vbNewLine AddValue FieldName(contentName,"Агентство"), RS.Fields("agency") AddValue FieldName(contentName,"Город"), RS.Fields("city") AddValue FieldName(contentName,"Местонахождение"), RS.Fields("street") AddFormToContent contentName, "Published" Response.Write Value("content_item_id") & vbNewLine RS.MoveNext Wend RS.Close Set RS = Nothing connection.Close Set connection = Nothing %><% If Err.Number <> 0 Then Response.write("Unable to display object 'управление' correctly!
Details
: " & err.description) End If End Sub Private Sub CallStackOverflow() Response.Write "Object Call Stack Overflow
Call Stack:
" dim i for i=1 to 20 Response.Write object_call_stack(i)&"
" next Response.End End Sub Private Function ObjectNS(name) Object(name) End Function Private Function Object(name) object_call_depth = object_call_depth + 1 if object_call_depth > 20 then CallStackOverflow object_call_stack(object_call_depth) = name Select Case Trim(lCase(name)) Case Trim("управление") object1127O Case Else Response.Write "Object " & name & " not found.
" End Select object_call_depth = object_call_depth - 1 End Function Function LangObject (objectName) Dim lang lang = Value ("lang") if ( lang = "en" or lang = "am" ) then Object (objectName & "_" & lang) else Object (objectName) end if End Function %> <% Object("Управление") %> <% DisposeValues cnn.Close %>