<% if Request.Form("submit") = "Build Your Page" then sRestrict = "" for i = 2 to 4 if Request.Form("restrictions" + cStr(i)) = "" then sRestrict = sRestrict + "0" else sRestrict = sRestrict + "1" end if NEXT sRestrict = sRestrict + Request.Form("restrictions1") if Request.Form("contact") = "yes" then sContact = "1" else sContact = "0" end if if Request.Form("orders") = "yes" then sContact = "2" end if if (not Request.Form("website") = "") and (not instr(Request.Form("website"), "http://") > 0) then sURL = "http://" + Request.Form("website") end if if Request.Form("expires") = "monthly" then sExpires = cStr(DateAdd("m", cInt(Request.Form("count_month")), Date)) else sExpires = Request.Form("month") + "/" + Request.Form("day") + "/" + cStr(DatePart("yyyy", Date)) if not isDate(sExpires) then sExpires = cStr(Date) else if DateDiff("d", Date,sExpires) < 0 then sExpires = cStr(DateAdd("yyyy", 1, sExpires)) end if end if end if SET DbObj = Server.CreateObject("ADODB.CONNECTION") DbObj.Open "DSN=CommunityRebates;"+application("SQLQuery") SQL = "INSERT INTO hosting (name, user_pwd, address, address2, city, state, zip_code, phone, fax, email, website, category1, category2, category3, contact, slogan, specials, expires, comment, restrictions, title_font, page_font, font_color, background_color, finder_rec_id, merchant_type, active) VALUES ('"+Replace(Request.Form("name"), "'", "''")+"', '"+Request.Form("password")+"', '"+Request.Form("address")+"', '"+Request.Form("address2")+"', '"+Request.Form("city")+"', '"+Request.Form("state")+"', '"+Request.Form("zip_code")+"', '"+Request.Form("phone")+"', '"+Request.Form("fax")+"', '"+Request.Form("email")+"', '"+sURL+"', '"+Request.Form("category1")+"', '"+Request.Form("category2")+"', '"+Request.Form("category3")+"', '"+sContact+"', '"+Replace(Request.Form("slogan"), "'", "''")+"', '"+Replace(Request.Form("specials"), "'", "''")+"', '"+sExpires+"', '"+Replace(Request.Form("comment"), "'", "''")+"', '"+Replace(sRestrict, "'", "''")+"', '"+Request.Form("title_font")+"', '"+Request.Form("page_font")+"', '"+Request.Form("font_color")+"', '"+Request.Form("background_color")+"', '0', '"+Request.Form("merchant_type")+"', '1')" SET oRs = DbObj.Execute(SQL) SQL = "SELECT rec_id, name FROM hosting WHERE replace(name, ' ', '') = '"+Replace(Replace(Request.Form("name"), " ", ""), "'", "''")+"' and user_pwd = '"+Request.Form("password")+"'" SET oRs = DbObj.Execute(SQL) if not oRs.EOF then Response.Cookies("UI") = oRs.Fields("rec_id") Response.Cookies("UN") = oRs.Fields("name") end if set oRs = Nothing DbObj.close set DbObj = Nothing Response.Redirect(Replace(Request.Form("name"), " ", "")) end if if Request.Form("submit") = "Click To Continue" then if Request.Form("password") = Request.Form("re-password") then SET DbObj = Server.CreateObject("ADODB.CONNECTION") DbObj.Open "DSN=CommunityRebates;"+application("SQLQuery") SQL = "SELECT rec_id from hosting WHERE replace(name, ' ', '') = '"+Replace(Replace(Request.Form("name"), "'", "''"), " ", "")+"'" SET oRs = DbObj.Execute(SQL) if not oRs.EOF then sUserError = "*Sorry this business name is aready in use." bError = TRUE else sUser = Request.Form("name") end if set oRs = Nothing DbObj.close set DbObj = Nothing else bError = TRUE sPassError = "*Passwords do not match." end if end if %> Setup Business Directory Page
<%if sUser = "" then%> <%else%>
Setup Business Directory Page<%if sUser = "" then%> Step 1<%else%> Step 2<%end if%>

Business Name/Login:
" style="width=200"> <% if sUserError = "" then%>  *Enter name as you want it
  to appear on your web page.
<%else%>  <%=sUserError%> <%end if%>
Password: <%=sPassError%>
Re-Type Password:

Choose Business Type
Retail Business e.g. Flower shop, Toy Store, etc. $30 for 6 months and agree to honor 10% rebates from participating customers.
 
Professional Business (non-retail) e.g. attorney, accountant, physician, etc. $40 for 6 months but do not offer rebates.
Address 1:
Address 2:
City:
State:
Zip code:
Phone:
Fax:
(optional)
Email:
(optional)
Existing Website:
(optional)

Website Setup
<%end if%>
<%if Request.Form("merchant_type") = "0" then%><%else%><%end if%>
Primary Category:  Can't find the category you want?
Second Category:
(optional)
Third Category:
(optional)
Contact Box:
Provide Contact Box
Accept Orders Via Email
*Merchant is responsible for monitoring email orders.
Slogan/Motto:
(optional)
Specials:
(optional)
Expires: Month(s)
Month: Day:
Comments:
(optional)
Restrictions:
(optional)

 Not valid in conjunction with any other offer.
 Applies to purchases of $10 or more.
 Coupon invalid for sales over 50% off.
Contact Box:
Provide Contact Box
Accept Appointments Via Email
*Business is responsible for monitoring emails.
Slogan/Motto:
(optional)
Specialties:
(optional)
Degrees:
(optional)

Title Font:
 
<%=sUser%>
Page Font:
 
Body Font Example
Font Color:
  
Background Color:
 
  
">



 Copyright or other proprietary statement goes here.
For problems or questions regarding this Web site contact [ProjectEmail].
Last updated: 02/28/09.