%Option Explicit%>
<%
Call PagePrep()
%>
"
' Force header image (it is part of the paid advertisement)
ret_blnHeaderImage = True
Call DisplaySpecificImage(PGLP.HeaderImage, "", "")
If ret_blnLNAV Then
' add some extra uniform padding if we have a left menu so that form doesn't butt up against it
Response.Write "
"
Else
Response.Write "
"
End If
Response.Write PGLP.Body(ret_store_id)
DisplaySpecialPromotions()
Response.Write "
" ' margin
Response.Write "
" ' midCol
BuildMidCol = ""
End Function
Function BuildThirdCol()
Response.Write "
"
Call GetRightHandModules()
Response.Write "
"
End Function
Sub GetRightHandModules()
Dim Clusters, Cluster
Dim html, PromoModule, BannerAd
Dim bIncludePromoModule : bIncludePromoModule = False
Dim bSecureRequest : bSecureRequest = False
Dim bIncludeBrandModuleLink
If SupportsOnlineShopping Or SupportsProductCatalog Then
bIncludeBrandModuleLink = True
Else
' no brand module for basic sites
bIncludeBrandModuleLink = False
End If
If IsNumeric(PromotionID) Then
Set Clusters = Server.CreateObject("LNPromoGenius.Clusters")
Clusters.MPDConnString = PGConnStr
Clusters.WGConnString = WGConnStr
set Cluster = Clusters.GetClusterFromPromoID(PromotionID)
html = Cluster.ModulesHTML(ret_store_id, ret_oid, Request.ServerVariables("SERVER_NAME"), bIncludePromoModule, mscsShopperID, bSecureRequest, bIncludeBrandModuleLink)
Response.Write html
End if
End Sub
Function DisplaySpecialPromotions()
' If Not (SupportsProductCatalog() or SupportsOnlineShopping()) Then
' Exit Function ' this is a basic site
' End If
' here we need code to selectively determine which products to display
' based on which products are tied to the promotion, and which products this retailer supports
If IsNumeric(PromotionID) Then
Set rsProduct=server.CreateObject("ADODB.Recordset")
rsProduct.CursorLocation = adUseClient
rsProduct.CursorType = adOpenStatic
rsProduct.LockType = adLockBatchOptimistic
rsProduct.PageSize = 50 '- hard code this to 50
Set cmdProduct = Server.CreateObject("ADODB.Command")
cmdProduct.ActiveConnection = MSCS
cmdProduct.CommandType = adCmdStoredProc
cmdProduct.Parameters.Append cmdProduct.CreateParameter("@storePK", adInteger, adParamInput, 4, ret_OID)
cmdProduct.Parameters.Append cmdProduct.CreateParameter("@PromotionID", adInteger, adParamInput, 4, PromotionID)
cmdProduct.CommandText = "spPGGetSpecialPromotionProducts"
rsProduct.Open cmdProduct
Set rsProduct.ActiveConnection = nothing
lProductCount = rsProduct.RecordCount
If lProductCount > 0 Then
Response.Write "
" & vbCrLf
Response.Write " Special Promotions | " & vbCrLf
Response.Write "
" & vbCrLf
Response.Write "
" & vbCrLf
Call DisplayResultsBodyPG()
Response.Write " |
" & vbCrLf
End If
End If
End Function
Function DisplayResults()
Dim bUseThumbnail : bUseThumbnail = True
If lProductCount > 0 Then
Call DisplayProductResultsEx(bUseThumbnail)
End If
End Function
' Insert tracking assest for PG Ads
If Not PGLP Is Nothing Then
Response.Write ("
" )
Response.Write PGLP.GetPixelCodeIFrame(Request.ServerVariables("SERVER_NAME"), Request.QueryString("dnr"))
Response.Write (" |
" & vbCrLf)
Set PGLP = Nothing
End If
%>