HEX
Server: Microsoft-IIS/10.0
System: Windows NT ITPWINWEBSVR22 10.0 build 20348 (Windows Server 2022) AMD64
User: www.conferencesearch.co.uk (0)
PHP: 8.3.30
Disabled: NONE
Upload Files
File: D:/web/homefly/vsadmin/inc/incproductbody2.asp
<%	prodoptions=""
	saveLCID = Session.LCID
	productdisplayscript(noproductoptions<>true) %>
			<table width="<%=innertablewidth%>" border="0" cellspacing="<%=innertablespacing%>" cellpadding="<%=innertablepadding%>" bgcolor="<%=innertablebg%>">
<%	if productcolumns="" then productcolumns=1
	if IsEmpty(showcategories) OR showcategories=true then %>
			  <tr>
				<td colspan="<%=productcolumns%>">
				  <table width="100%" border="0" cellspacing="0" cellpadding="0">
					<tr>
					  <td align="<%=headeralign%>"><b><a href="<%=xxHomeURL%>"><%=xxHome%></a> &raquo; <% if tsName <> "" then response.write "<a href='categories.asp?id="&tsID&"'>" & tsName & "</a> &raquo; "%><% =sectionName %></b></td>
					  <td align="right">&nbsp;<% if nobuyorcheckout<>true then %><a href="cart.asp"><img src="images/checkout.gif" border="0"></a><% end if %></td>
					</tr>
				  </table>
				</td>
			  </tr>
<%	end if
Session.LCID = 1033
sSQL = "SELECT DISTINCT cpnWorkingName FROM coupons LEFT OUTER JOIN cpnAssign ON coupons.cpnID=cpnAssign.cpaCpnID WHERE ("
addor = ""
if tsID<>"" then
	sSQL = sSQL & addor & "(cpnSitewide=0 AND cpaType=0 AND cpaAssignment='"&tsID&"')"
	addor = " OR "
end if
if catid<>"" then
	sSQL = sSQL & addor & "(cpnSitewide=0 AND cpaType=1 AND cpaAssignment='"&catid&"')"
	addor = " OR "
end if
tdt = Date()
sSQL = sSQL & addor & "(cpnSitewide=1 OR cpnSitewide=2)) AND cpnNumAvail>0 AND cpnEndDate>="&datedelim&DatePart("m",tdt) & "/" & DatePart("d",tdt) & "/" & DatePart("yyyy",tdt)&datedelim&" AND cpnIsCoupon=0"
Session.LCID = saveLCID
rs2.Open sSQL,cnn,0,1
if NOT rs2.EOF then
%>
			  <tr>
				<td align="left" colspan="<%=productcolumns%>">
				  <p><b><%=xxDsProd%></b><br><font color="#FF0000" size="1">
				  <%	do while NOT rs2.EOF
							response.write rs2("cpnWorkingName") & "<br>"
							rs2.MoveNext
						loop %></font></p>
				</td>
			  </tr>
<%
end if
rs2.Close
		If iNumOfPages > 1 AND pagebarattop=1 Then 
%>
			  <tr>
				<td colspan="<%=productcolumns%>" align="center"><%
					Response.Write writepagebar(CurPage, iNumOfPages) & "<BR>" %><img src="images/clearpixel.gif" width="350" height="1"></td>
			  </tr>
<%
		end if
netnav = true
if instr(Request.ServerVariables("HTTP_USER_AGENT"), "compatible") > 0 OR instr(Request.ServerVariables("HTTP_USER_AGENT"), "Gecko") > 0 then netnav = false
function atb(size)
	if netnav then
		atb = CInt(size / 2 + 1)
	else
		atb = size
	end if
end function
	Do While Not rs.EOF And Count < rs.PageSize
		if Trim(rs("pLongDescription"))<>"" OR NOT (Trim(rs("pLargeImage"))="" OR IsNull(rs("pLargeImage")) OR Trim(rs("pLargeImage"))="prodimages/") then
			startlink="<a href='proddetail.asp?prod="&Server.URLEncode(rs("pId"))&"'>"
			endlink="</a>"
		else
			startlink=""
			endlink=""
		end if
		Session.LCID = 1033
		tdt = Date()
		sSQL = "SELECT DISTINCT cpnWorkingName FROM coupons LEFT OUTER JOIN cpnAssign ON coupons.cpnID=cpnAssign.cpaCpnID WHERE cpnSitewide=0 AND cpnNumAvail>0 AND cpnEndDate>="&datedelim&DatePart("m",tdt) & "/" & DatePart("d",tdt) & "/" & DatePart("yyyy",tdt)&datedelim&" AND cpnIsCoupon=0 AND ((cpaType=2 AND cpaAssignment='"&rs("pID")&"')"
		if catid="" then
			sSQL = sSQL & " OR (cpaType=1 AND cpaAssignment='"&rs("pSection")&"')"
			if subCats AND tcatid="" then sSQL = sSQL & " OR (cpaType=0 AND cpaAssignment='"&rs("topSection")&"')"
		end if
		sSQL = sSQL & ")"
		Session.LCID = saveLCID
		alldiscounts = ""
		rs2.Open sSQL,cnn,0,1
		do while NOT rs2.EOF
			alldiscounts = alldiscounts & rs2("cpnWorkingName") & "<br>"
			rs2.MoveNext
		loop
		rs2.Close
%>
              <% if Count MOD productcolumns = 0 then response.write "<tr>" %>
				<td width="<%=Int(100 / productcolumns)%>%" align="center" valign="top">
				  <table width="100%" border="0" cellspacing="4" cellpadding="4">
			  <% if showproductid=true then response.write "<tr><td><b>" & xxPrId & ":</b> " & rs("pID") & "</td></tr>" %>
				    <tr>
					  <td width="100%" align="center" valign="middle">
						<% if Trim(rs("pImage"))="" or IsNull(rs("pImage")) or Trim(rs("pImage"))="prodimages/" then %>
						  &nbsp;
						<% else %>
						  <%=startlink%><img src="<%=rs("pImage")%>" border="0" alt="<%=Replace(rs("pName"),"""","&quot;")%>"><%=endlink%>
						<% end if %>
					  </td>
					</tr>
<% updatepricescript(noproductoptions<>true) %>
	<form method="POST" name="tForm<%=Count%>" action="cart.asp" onSubmit="return formvalidator<%=Count%>(this)">
					<tr>
					  <td width="100%">
					    <p><strong><%=startlink & rs("pName") & endlink & xxDot%></strong><% if alldiscounts<>"" then response.write "<br><font color=""#FF0000""><strong>"&xxDsApp&"</strong><br><font size=""1"">" & alldiscounts & "</font></font>" %><br>
						<%=rs("pDescription")%><br>
<%
if IsArray(prodoptions) AND noproductoptions<>true then
	response.write "<table border='0' cellspacing='1' cellpadding='1' width='100%'>"
	for rowcounter=0 to UBOUND(prodoptions,2)
		index=0
		gotSelection=false
		do while index < (maxprodopts-1) AND aOption(0,index)<>0
			if aOption(0,index)=Int(prodoptions(0,rowcounter)) then
				gotSelection=true
				exit do
			end if
			index = index + 1
		loop
		if NOT gotSelection then
			sSQL="SELECT optID,optName,optGrpName,optPriceDiff,optType FROM options INNER JOIN optionGroup ON options.optGroup=optionGroup.optGrpID WHERE optGroup="&prodoptions(0,rowcounter)&" ORDER BY optID"
			rs2.Open sSQL,cnn,0,1
			if NOT rs2.EOF then
				if Abs(Int(rs2("optType")))=3 then
					fieldHeight = cInt((cDbl(rs2("optPriceDiff"))-Int(rs2("optPriceDiff")))*100.0)
					aOption(1,index) = "<tr><td align='right' width='30%'><b>"&rs2("optGrpName")&":</b></td><td> <input type='hidden' name='optnPLACEHOLDER' value='"&rs2("optID")&"'>"
					if fieldHeight<>1 then
						aOption(1,index) = aOption(1,index) & "<textarea wrap='virtual' name='voptnPLACEHOLDER' cols='"&atb(Int(rs2("optPriceDiff")))&"' rows='"&fieldHeight&"'>"
						aOption(1,index) = aOption(1,index) & rs2("optName")&"</textarea>"
					else
						aOption(1,index) = aOption(1,index) & "<input maxlength='255' type='text' name='voptnPLACEHOLDER' size='"&atb(Int(rs2("optPriceDiff")))&"' value="""&Replace(rs2("optName"),"""","&quot;")&""">"
					end if
					aOption(1,index) = aOption(1,index) & "</td></tr>"
				else
					aOption(1,index) = "<tr><td align='right' width='30%'><b>"&rs2("optGrpName")&":</b></td><td> <select onChange='updatepricePLACEHOLDER();' name='optnPLACEHOLDER' size='1'>"
					if Int(rs2("optType"))>0 then aOption(1,index) = aOption(1,index) & "<option value=''>"&xxPlsSel&"</option>"
					do while not rs2.EOF
						aOption(1,index) = aOption(1,index) & "<option value='"&rs2("optID")&"'>"&rs2("optName")
						if cDbl(rs2("optPriceDiff"))<>0 then
							aOption(1,index) = aOption(1,index) & " ("
							if cDbl(rs2("optPriceDiff")) > 0 then aOption(1,index) = aOption(1,index) & "+"
							aOption(1,index) = aOption(1,index) & FormatEuroCurrency(rs2("optPriceDiff"))&")"
						end if
						aOption(1,index) = aOption(1,index) & "</option>"&vbCrLf
						rs2.MoveNext
					loop
					aOption(1,index) = aOption(1,index) & "</select></td></tr>"
				end if
			end if
			aOption(0,index) = Int(prodoptions(0,rowcounter))
			rs2.Close
		end if
		response.write Replace(Replace(aOption(1,index),"optnPLACEHOLDER","optn"&rowcounter),"updatepricePLACEHOLDER","updateprice"&Count,1,1)
	next
	response.write "</table>"
end if
					if noprice<>true then
						if cDbl(rs("pListPrice"))<>0.0 then response.write Replace(xxListPrice, "%s", FormatEuroCurrency(rs("pListPrice"))) & "<BR>"
						if rs("pPrice")=0 AND pricezeromessage<>"" then
							response.write pricezeromessage
						else
							response.write "<b>" & xxPrice & ":</b> <span id=""pricediv" & Count & """ name=""pricediv" & Count & """>" & FormatEuroCurrency(rs("pPrice")) & "</span> "
							if showtaxinclusive=true then response.write Replace(ssIncTax,"%s", "<span id=""pricedivti" & Count & """ name=""pricedivti" & Count & """>" & FormatEuroCurrency(rs("pPrice")+(rs("pPrice")*countryTax/100.0)) & "</span> ")
							response.write "<br>"
							if currencyseparator="" then currencyseparator=" "
							if currRate1<>0 AND currSymbol1<>"" then response.write "<span id=""pricediv1c" & Count & """ name=""pricediv1c" & Count & """>" & FormatNumber(rs("pPrice")*currRate1, checkDPs(currSymbol1)) & " <b>" & currSymbol1 & "</b></span>" & currencyseparator
							if currRate2<>0 AND currSymbol2<>"" then response.write "<span id=""pricediv2c" & Count & """ name=""pricediv2c" & Count & """>" & FormatNumber(rs("pPrice")*currRate2, checkDPs(currSymbol2)) & " <b>" & currSymbol2 & "</b></span>" & currencyseparator
							if currRate3<>0 AND currSymbol3<>"" then response.write "<span id=""pricediv3c" & Count & """ name=""pricediv3c" & Count & """>" & FormatNumber(rs("pPrice")*currRate3, checkDPs(currSymbol3)) & " <b>" & currSymbol3 & "</b></span>"
						end if
					end if %></p>
					  </td>
					</tr>
					<tr>
					  <td align="center"><%
if nobuyorcheckout=true then
	response.write "&nbsp;"
else
	if useStockManagement then
		isInStock = Int(rs("pInStock")) > 0
	else
		isInStock = Int(rs("pSell")) <> 0
	end if
	if isInStock then
%>
<input type="hidden" name="id" value="<%=rs("pID")%>">
<input type="hidden" name="mode" value="add">
<%		if showquantonproduct=true then %><input type="text" name="quant" size="2" value="1"><% end if %><input align="absmiddle" type="image" src="images/buy.gif" border="0"><%
	else
		response.write "<b>"&xxOutStok&"</b>"
	end if
end if%>
					  </td>
					</tr>
					</form>
				  </table>
				</td>
<%
		Count = Count + 1
		rs.MoveNext
		if Count MOD productcolumns = 0 then
			response.write "</tr>"
			if Not rs.EOF And Count < rs.PageSize then
				response.write "<tr>"
				for index=1 to productcolumns
					response.write "<td align=""center""><hr width=""70%"" align=""center""></td>"
				next
				response.write "</tr>"
			end if
		end if
	loop
	if Count MOD productcolumns <> 0 then
		do while Count MOD productcolumns <> 0
			response.write "<td width="""&Int(100 / productcolumns)&"%"" align=""center"">&nbsp;</td>"
			Count = Count + 1
		loop
		response.write "</tr>"
	end if
%>
			  <tr>
				<td colspan="<%=productcolumns%>" align="center"><%
					If iNumOfPages > 1 AND nobottompagebar<>true Then Response.Write writepagebar(CurPage, iNumOfPages) %><br>
				<img src="images/clearpixel.gif" width="350" height="1">
				</td>
			  </tr>
			</table>