Print Page | Close Window

Modifying viewCat_h.asp

Printed From: ProductCart E-Commerce Solutions
Category: ProductCart
Forum Name: Customizing ProductCart
Forum Description: Exchange messages with other users that are customizing ProductCart.
URL: https://forum.productcart.com/forum_posts.asp?TID=63
Printed Date: 27-November-2024 at 3:05am
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: Modifying viewCat_h.asp
Posted By: Dean
Subject: Modifying viewCat_h.asp
Date Posted: 01-December-2005 at 1:06am
As you can see from the photshop'd screen capture I am trying to add the additional page pointer to the top of the screen.  The problem with the current situation is our customers are not clicking on the second page because they fail to see it even exists.   I've identified that veiwCat_h.asp is the file that most needs to be changed.  I've found the code and  when I cut and paste it into the most likely looking place in the table, well lets just say the results are not what I'm looking for.    The modified page loses its nice arrangement and no amount of fiddling with <table> <tr> <td> tags seems to fix the problem.  It looks like a simple thing to change, but I'm stummped.  For what it is worth I'm using Dreamweaver MX.






Replies:
Posted By: Nothing
Date Posted: 01-December-2005 at 3:32pm
hi dean
i had the same issues. the beolw code worked for me.
it's from the product support pages i believe.

----------------------------------------------------------
Yes, but you will have to modify the asp source code on
the page. For example, this is the code that would be used towards the top of
viewCat_h.asp.

uploaded_files/Nothing/2005-12-06_164542_Forward-Back-Buttons.txt - 2005-12-06_164542_Forward-Back-Buttons.txt

----------------------------------------------------------

i'm using ProductCart v2.75g12a16 and all works great here.
hope it helps.

nothing


Posted By: Dean
Date Posted: 04-December-2005 at 8:42pm
Thanks for the pointer.  Thats just what I needed to get started.  For anyone else that wants to make the change to viewCat_h.asp shown in my screen shot above here is detailed instructions.

On line 226 you will find this line:

            next %></b></font></td></tr>

Insert the code below between the </b> and the </font> tags

           next %></b> Put the code here </font></td></tr>

<% If iPageCount>1 then 'If Page count is more then 1 show page navigation %>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &n bsp;         
<font face="<%=FFType%>" color="<%=FColor%>" size="2"><b>
<% If iPageCurrent > 1 Then %>
<a href="viewCat_h.asp?ProdSort=<%=ProdSort%>&am p;idCategory=<%=mIdCategory%>&page=<%=iPageCurr ent -1 %>"><img src="<%=rsIconObj("previousicon")%>" border="0">&l t;/a>
<% End If
For ICount=1 To iPageCount
If ICount=iPageCurrent Then %>
<%= ICount %>
<% Else %>
<a class=privacy href="viewCat_h.asp?ProdSort=<%=ProdSort%& gt;&idCategory=<%=mIdCategory%>&page=<%=ICo unt%>"><font color="<%=Link%>"><%=ICou nt%></font></a>
<% End If
Next
If iPageCurrent < iPageCount Then %>
<a href="viewCat_h.asp?ProdSort=<%=ProdSort%>&am p;idCategory=<%=mIdCategory%>&page=<%=iPageCurr ent + 1%>"><img src="<%=rsIconObj("nexticon")%>" border="0"></a >
<% End If %>
</b></font>           
<% end if 'end of page navigation %>



Posted By: Nothing
Date Posted: 05-December-2005 at 4:53am
your code has formatting issues. the code supplied by product cart should paste into your space without errors.

nothing


Posted By: Dean
Date Posted: 05-December-2005 at 8:47am
The code supplied by Early Imapact has formating issues as well.  I'm no expert when it comes to formating <tables> <tr> and <td> tags. But, I do know what I see, and when I posted Early Impacts code into that spot it put the next page pointer down one row.  I wanted it right next to the catagory. 

I am up for learning though, what formatting issues do you see?


Posted By: Nothing
Date Posted: 05-December-2005 at 5:33pm

Hello

I haven’t actually tried your code, but from what I see at the end of line 5 “&l t;/a>“ should be “</a>” and mid way through line 12 “<%=ProdSort%& gt;” should be “<%=ProdSort%>”. I’m sure it’s just a formatting issue, but I believe the code would error if I were to copy and paste it.


nothing



Posted By: Dean
Date Posted: 05-December-2005 at 10:34pm
Good eye, you're right, the code as displayed is junk.

When I cut and paste from DreamWeaver or Notepad the code gets scrambled.  Heck I even cut and pasted from your post and it got scrambled. 


Posted By: Nothing
Date Posted: 06-December-2005 at 1:33am
the html text editor for posting messages on this form is corrupting the code. the more i edit the code i posted the worse it gets.

oh well.


nothing



Posted By: ComputerJack
Date Posted: 06-December-2005 at 8:40am
You can try wraping your code with [ CODE ]    code here    [ / CODE ] (without all the spaces) and the forum should display it properly.


Posted By: Dean
Date Posted: 06-December-2005 at 10:35am
Thanks for the [ code ] hint.


Posted By: Nothing
Date Posted: 06-December-2005 at 4:43pm
I tried the [ code ] trick without any luck. the forum is still messing up the code.

maybe a text file will work better?
uploaded_files/Nothing/2005-12-06_164132_Forward-Back-Buttons.txt - 2005-12-06_164132_Forward-Back-Buttons.txt


thanks
nothing


Posted By: ProductCart
Date Posted: 07-December-2005 at 2:23am

We didn't develop this application. So we are still learning how to use it ourselves too. It's a shame if you can't post ASP code. Did you try this?

Rich Text Editor (WYSIWYG) posting issues

If you are using Internet Explorer 5+ (windows only), Netscape 7.1, Mozilla 1.3+, Mozilla Firebird 0.6.1+, and if the forum administrator has enabled it you should have a Rich Text (WYSIWYG) Editor to type your messages with. If you find that you are having problems posting using the WYSIWYG editor then you can disable this WYSIWYG Editor by simply editing your profile and selecting to turn off the WYSIWYG Posting Editor.

Maybe it helps.



-------------
The ProductCart Team

Home of ProductCart http://www.productcart.com" rel="nofollow - shopping cart software


Posted By: Nothing
Date Posted: 07-December-2005 at 4:49am
Thansk for the tip.
Yes, i disabled the WYSIWYG editor in the settings options, tried to edit the code and no luck. I’ve cut and pasted from text documents, ms word, hand typed it and no difference.

I also un-checked the “Enable Forum Codes to format post” option. didn't help.

I don’t mind uploading the text documents, but if I were to leave this forum (delete my account on this site) would the files I’ve uploaded be deleted? Does searching the forum also search attached files?

I’m using win2k server with firefox 1.5 and IE 6.0 and also
winXP with firefox 1.1 and  IE 6.0

test

<a  href="viewCat_h.asp?ProdSort=<%=ProdSort%>&idCatae gory=<%=mIdCategory%>&page=<%=iPageCurrent  -1 %>">
<a href="viewCat_h.asp?ProdSort=<%=ProdSort%>&idCatae gory=<%=mIdCategory%>&page=<%=iPageCurrent -1 %>">
<a href="viewCat_h.asp?ProdSort=<%=ProdSort%>&idCatae gory=<%=mIdCategory%>&page=<%=iPageCurrent -1 %>">
<a href="viewCat_h.asp?ProdSort=<%=ProdSort%>&idCatae gory=<%=mIdCategory%>&page=<%=iPageCurrent -1 %>">
<a href="viewCat_h.asp?ProdSort=<%=ProdSort%>&idCatae gory=<%=mIdCategory%>&page=<%=iPageCurrent -1 %>">


<a  href="viewCat_h.asp?ProdSort=<%=ProdSort%>&idCatae gory=<%=mIdCategory%>&page=<%=iPageCurrent  -1 %>">
<a href="viewCat_h.asp?ProdSort=<%=ProdSort%>&idCatae gory=<%=mIdCategory%>&page=<%=iPageCurrent -1 %>">
<a href="viewCat_h.asp?ProdSort=<%=ProdSort%>&idCatae gory=<%=mIdCategory%>&page=<%=iPageCurrent -1 %>">


<% If iPageCount>1 then 'If Page count is more then 1 show page navigation %>
<table width="<%=scprdTableWidth%>" border="0" cellspacing="0" cellpadding="3">
<tr>
<td>
<div align="right">
<font face="<%=FFType%>" color="<%=FColor%>" size="2"><b>
<% If iPageCurrent > 1 Then %>
<a href="viewCat_h.asp?ProdSort=<%=ProdSort%>&idCatae gory=<%=mIdCategory%>&page=<%=iPageCurrent -1 %>">
<img src="<%=rsIconObj("previousicon")%>" border="0"></a>
<% End If
For ICount=1 To iPageCount
If ICount=iPageCurrent Then %>
<%= ICount %>
<% Else %>
<a class=privacy href="viewCat_h.asp?ProdSort=<%=ProdSort%>&idCatae gory=<%=mIdCategory%>&page=<%=ICount%>">
<font color="<%=Link%>"><%=ICount%></font>< ;/a>
<% End If
Next
If iPageCurrent < iPageCount Then %>
<a href="viewCat_h.asp?ProdSort=<%=ProdSort%>&idCatae gory=<%=mIdCategory%>&page=<%=iPageCurrent +1%>">
<img src="<%=rsIconObj("nexticon")%>" border="0"></a>
<% End If %>
</b></font></div>
</td>
</tr>
</table>
<% end if 'end of page navigation %>


____________________________
<a  href="viewCat_h.asp?ProdSort=<%=ProdSort%>&idCatae gory=<%=mIdCategory%>&page=<%=iPageCurrent+1%&g t;">
<a href="viewCat_h.asp?ProdSort=<%=ProdSort%>&idCatae gory=<%=mIdCategory%>&page=<%=iPageCurrent+1%&g t;">
<img src="<%=rsIconObj("nexticon")%>" border="0"></a><img src="<%=rsIconObj("nexticon")%>" border="0"></a>
____________________________





Posted By: BlazingPepper
Date Posted: 09-December-2005 at 10:32am
Would it be possible for EarlyImpact to post a new viewCat_h.asp code with the page links at the top?  This is something I really could use too and I'm not having any luck with the tweaking the ASP code either.  Sounds like a lot of others would like this feature as well.  It would be beneficial to everyone.  Thanks in advance for your consideration about this.


Posted By: ProductCart
Date Posted: 09-December-2005 at 11:42am

There is an article in the knowledge base that might be helpful:

http://www.earlyimpact.com/faqs/afmviewfaq.asp?faqid=321 - http://www.earlyimpact.com/faqs/afmviewfaq.asp?faqid=321

Remember to check the knowledge base for answers to questions. We regularly update it with new FAQ's. We'll edit the interface of this forum soon to place a link to the knowledge base for here too.



-------------
The ProductCart Team

Home of ProductCart http://www.productcart.com" rel="nofollow - shopping cart software


Posted By: BlazingPepper
Date Posted: 13-December-2005 at 8:31pm
Thanks EarlyImp -- that worked for me. 


Posted By: blackdesk
Date Posted: 09-June-2006 at 10:09pm
works great once you fix all the extra spaces & junk :o]

anyone know where exactly i would paste this into the
viewcat & viewcat_Brands to achieve the same result?

thanx!


Posted By: netprofits
Date Posted: 10-June-2006 at 8:00am

For any of the list pages where you want to add paging at the top, the best bet is to look for code like the following which leaves some blank space after the breadcrumbs on the top of the page:

[
<tr>
  <td><img src="images/spacer.gif" width="1" height="15" alt=""></td>
</tr>
]

Add a new table row right after this section and then put your page navigation in that new row. Remember that you need to change the name of the ASP page from the sample code to use the page you are working on, i.e. viewcat.asp, viewCat_Brands.asp, etc.

If you are pretty comfortable with ASP, we actually recommend creating a generic PageNavigation subroutine with all the parameters you need and put it in an include file. (We pass the URL and the total record count.) Then include that file in any page where you want to have page navigation and just call the subroutine at the top and bottom of each category or product list.



-------------
NetProfits Internet Consulting

Certified ProductCart Developer

http://www.nicwebdesign.com" rel="nofollow - Our Site


Posted By: netprofits
Date Posted: 10-June-2006 at 8:10am

Another idea...if you are really adventuresome...you can create one ASP page to replace the Featured Products, Best Sellers, New Arrivals and Specials pages. The pages are almost identical except for the SQL code used to generate the list of products. Then just pass a querystring to the new ASP page to show which products you want to display and use the query string to determine which SQL code to use. The advantage of this is that you can define the page navigation and custom view of products on one ASP page vs. 4 pages. That makes managing changes much simpler.

If you want to see a sample of this, check out http://www.poshera.com - www.poshera.com and look at the hyperlink for any of the 4 pages on the left navbar that I mention above. They all use the same page to display products and just pass in the pagetype. The top and bottom navigation use a subroutine so the code isn't duplicated which makes any changes easier to manage.



-------------
NetProfits Internet Consulting

Certified ProductCart Developer

http://www.nicwebdesign.com" rel="nofollow - Our Site



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net