<%@LANGUAGE="VBSCRIPT" CODEPAGE="65001"%> <% 'Make a transaction dispatcher instance Dim tNGs: Set tNGs = new tNG_dispatcher tNGs.Init "" %> <% ' Start trigger Dim formValidation: Set formValidation = new tNG_FormValidation formValidation.Init formValidation.addField "first_name", true, "text", "", "", "", "Please enter your first name." formValidation.addField "last_name", true, "text", "", "", "", "Please enter your last name." formValidation.addField "email", true, "text", "email", "", "", "Please enter a valid email address." formValidation.addField "phone", true, "regexp", "/^\d{10}$/", "", "", "Please enter a 10 digit phone number." formValidation.addField "booking_date", true, "date", "date", "", "", "Please enter a valid date." formValidation.addField "guests", true, "numeric", "int", "0", "", "Please enter the number of guests." tNGs.prepareValidation formValidation ' End trigger %><% 'start Trigger_SendEmail trigger 'remove this line if you want to edit the code by hand Function Trigger_SendEmail (ByRef tNG) Dim emailObj: Set emailObj = new tNG_Email emailObj.Init tNG emailObj.setFrom "{email}" emailObj.setTo "info@lornehotel.com.au" emailObj.setCC "" emailObj.setBCC "" emailObj.setSubject "Online Bistro Booking" 'FromFile method emailObj.setContentFile "email_blank_bistro.html" emailObj.setEncoding "ISO-8859-1" emailObj.setFormat "HTML/Text" emailObj.setImportance "Normal" Set Trigger_SendEmail = emailObj.Execute() End Function 'end Trigger_SendEmail trigger %> <% ' Make an insert transaction instance Dim ins_tblbistrobooking: Set ins_tblbistrobooking = new tNG_insert ins_tblbistrobooking.init MM_lorne_hotel_STRING tNGs.addTransaction ins_tblbistrobooking ' Register triggers ins_tblbistrobooking.registerTrigger Array("STARTER", "Trigger_Default_Starter", 1, "POST", "KT_Insert1") ins_tblbistrobooking.registerTrigger Array("BEFORE", "Trigger_Default_FormValidation", 10, formValidation) ins_tblbistrobooking.registerTrigger Array("END", "Trigger_Default_Redirect", 99, "thankyou.htm") ins_tblbistrobooking.registerTrigger Array("AFTER", "Trigger_SendEmail", 40) ' Add columns ins_tblbistrobooking.setTable "tblbistrobooking" ins_tblbistrobooking.addColumn "first_name", "STRING_TYPE", "POST", "first_name", "" ins_tblbistrobooking.addColumn "last_name", "STRING_TYPE", "POST", "last_name", "" ins_tblbistrobooking.addColumn "email", "STRING_TYPE", "POST", "email", "" ins_tblbistrobooking.addColumn "phone", "STRING_TYPE", "POST", "phone", "" ins_tblbistrobooking.addColumn "booking_date", "DATE_TYPE", "POST", "booking_date", "" ins_tblbistrobooking.addColumn "guests", "NUMERIC_TYPE", "POST", "guests", "" ins_tblbistrobooking.addColumn "message", "STRING_TYPE", "POST", "message", "" ins_tblbistrobooking.addColumn "date_submitted", "DATE_TYPE", "POST", "date_submitted", "{NOW}" ins_tblbistrobooking.setPrimaryKey "booking_id", "NUMERIC_TYPE", "", "" %> <% 'Execute all the registered transactions tNGs.executeTransactions %> <% 'Get the transaction recordset Dim rstblbistrobooking Dim rstblbistrobooking_numRows Set rstblbistrobooking = tNGs.getRecordset("tblbistrobooking") rstblbistrobooking_numRows = 0 %> Lorne Hotel


 

   
<% Response.Write tNGs.displayValidationRules()%>
Make a booking


The simplest way to book is to call the Lorne Hotel on (03) 5289 1409 or complete the form below and submit it to us.
We'll get back to you by phone or email within 24 hours.

<% Response.Write tNGs.getErrorMsg() %>

" size="35" /> <%=(tNGs.displayFieldHint("first_name"))%> <%=(tNGs.displayFieldError("tblbistrobooking", "first_name"))%>
" size="35" /> <%=(tNGs.displayFieldHint("last_name"))%> <%=(tNGs.displayFieldError("tblbistrobooking", "last_name"))%>
" size="35" /> <%=(tNGs.displayFieldError("tblbistrobooking", "email"))%>
" size="15" /> <%=(tNGs.displayFieldHint("phone"))%> <%=(tNGs.displayFieldError("tblbistrobooking", "phone"))%>
" size="15" wdg:mondayfirst="true" wdg:subtype="Calendar" wdg:mask="<%= KT_screen_date_format %>" wdg:type="widget" wdg:singleclick="true" wdg:restricttomask="no" /> <%=(tNGs.displayFieldHint("booking_date"))%> <%=(tNGs.displayFieldError("tblbistrobooking", "booking_date"))%>
" size="15" /> <%=(tNGs.displayFieldError("tblbistrobooking", "guests"))%>
<%=(tNGs.displayFieldHint("message"))%> <%=(tNGs.displayFieldError("tblbistrobooking", "message"))%>
" />

 

Please phone after 48 hours if your booking has not been acknowledged or confirmed.



© Copyright 2008 Lorne Hotel          Mountjoy Parade, Great Ocean Road. Lorne 3232          Phone: 03 5289 1409
 

Contact LocationRSA program Bottle Shop Functions Accommodation Virtual Tours What's On Bistro Home