<% set con = Server.CreateObject("ADODB.Connection") con.Open strCon %> <% if Request.QueryString("step") = "" then sql1 = "select * from category1 where parentcatid = -1 and active=1 and langFlag = 'E' order by sort" set rscat = server.CreateObject("ADODB.Recordset") set rscat = con.execute(sql1) %> <% if rscat.EOF then %> <% else dim ctr ctr = 0 %> <% end if %>
Sorry no Category found.
<% while not rscat.EOF %> <% if ctr mod 3 = 0 and ctr <> 0 then response.write"
" end if ctr=ctr+1 '*************Start of Code to calculate height and width of image************* img = rscat("image1") Set objFSO = CreateObject("Scripting.FileSystemObject") path = server.MapPath("products.asp") path1 = left(path,InStr(path,"\html_en\products.asp")) Set objF = objFSO.GetFolder(path1 &"media\catimg\") Set objFC = objF.Files For Each f1 in objFC if f1.Name = img then fname = f1.name fpath = f1.path end if next if not (fpath = "") then strWH=gfxSpex(fPath) arrwh=Split(strWH,",") width=int(arrwh(0)) height=int(arrwh(1)) if (width > 165) then width = 165 end if end if '*************End of Code to calculate height and width of image************* %> <% rscat.MoveNext wend rscat.Close() set rscat = nothing %>
<%if rscat("imagedisplay") = true and rscat("image1") <> "" then%> <%else%> <% end if %>
&pstring=<%=rscat("catid")%>"><%= rscat("name") %>
&pstring=<%=rscat("catid")%>">" align="top" border="0" width="<%=width%>">
 
<%= rscat("catdescription")%>
<% else %> <% if cint(Request.QueryString("step")) = 2 then catid = cint(Request.QueryString("id")) sql1 = "select * from category1 where parentcatid = "& catid&" and active = 1 and langFlag = 'E' order by sort" set rscat = server.CreateObject("ADODB.Recordset") set rscat = con.execute(sql1) if not rscat.eof then parentstring = Request.QueryString("pstring") & "," &rscat("catid") else parentstring = Request.QueryString("pstring") end if %> <% dim i, flag temparr = split(Request.QueryString("pstring"),",",-1) set temprs = server.CreateObject("ADODB.Recordset") Response.Write ("") temprs.Close() set temprs = nothing if rscat.EOF then flag = 0 %> <% else flag = 1 dim ctr1 ctr1 = 0 %> <% end if %> <% set rsestmt = server.CreateObject("ADODB.Recordset") sql3 = "select * from item where catid = "& catid &" and active = 1 order by sort" set rsestmt = con.execute(sql3) if not rsestmt.eof then flag = 1 dim ctr2 ctr2=0 %> <% end if %> <% if flag = 0 then %>

<% end if rscat.Close() set rscat = nothing rsestmt.Close() set rsestmt = nothing %>
") for i= 0 to ubound(temparr) sql2 = "select catid, name from category1 where catid = "& temparr(i)&" and langFlag = 'E' order by sort" set temprs = con.execute(sql2) Response.Write("" &temprs(1)& "" &" > ") catname=temprs(1) next Response.Write ("
Sub-Categories under the category : <%=catname%>
<% while not rscat.EOF if ctr1 mod 3 = 0 and ctr1 <> 0 then response.write"
" end if ctr1=ctr1+1 '*************Start of Code to calculate height and width of image************* img = rscat("image1") Set objFSO = CreateObject("Scripting.FileSystemObject") path = server.MapPath("products.asp") path1 = left(path,InStr(path,"\html_en\products.asp")) Set objF = objFSO.GetFolder(path1 &"media\catimg\") Set objFC = objF.Files For Each f1 in objFC if f1.Name = img then fname = f1.name fpath = f1.path end if next if not (fpath = "") then strWH=gfxSpex(fPath) arrwh=Split(strWH,",") width=int(arrwh(0)) height=int(arrwh(1)) if (width > 165) then width = 165 end if end if '*************End of Code to calculate height and width of image************* %> <% rscat.MoveNext wend %>
<% if rscat("imagedisplay") = true and rscat("image1") <> "" then %> <%else%> <% end if %>
&pstring=<%=parentstring%>"><%= rscat("name") %>
&pstring=<%=parentstring%>">" align="top" border="0" width="<%=width%>">
 
Image not available
<%= rscat("catdescription") %>

<% while not rsestmt.eof if ctr2 mod 3 = 0 and ctr2 <> 0 then response.write"
" end if ctr2=ctr2+1 '*************Start of Code to calculate height and width of image************* img = rsestmt("imagefile") Set objFSO = CreateObject("Scripting.FileSystemObject") path = server.MapPath("products.asp") path1 = left(path,InStr(path,"\html_en\products.asp")) Set objF = objFSO.GetFolder(path1 &"media\products\") Set objFC = objF.Files For Each f1 in objFC if f1.Name = img then fname = f1.name fpath = f1.path end if next if not (fpath = "") then strWH=gfxSpex(fPath) arrwh=Split(strWH,",") width=int(arrwh(0)) height=int(arrwh(1)) if (width > 165) then width = 165 end if end if '*************End of Code to calculate height and width of image************* %> <% rsestmt.movenext wend %>
<%if rsestmt("imagefile") <> "" then %> <%end if %>
" class="gen"><%= rsestmt("namez") %>
" class="gen">" align="top" border="0" width="<%=width%>">
Sorry no Subcategory or Product found.


Back to previous Page


Back to main listing
<% end if %> <% end if %>
Please select the Search Criteria
( Tips : You can add Category Name, Description, Product Name, Product Descrition as the Keyword, please put comma(,) between two or more Keywords )