Author |
Topic |
|
ProductivePC
VP-CART New User
USA
199 Posts |
Posted - April 01 2004 : 00:51:36
|
Hey Everyone,
This is probably a question that vpasp support will need to answer however if someone else knows the answer please let me know.
I know in the developers manual there is a way to add to cart from outside the shopping cart. I would like to do something similar. I would like the linking code to be able to send someone to a page within the shopping cart that is dynamically generated. Something that I can put in the URL that will allow that page not to come up with an error.
(E.G. when you click on a category that takes you to a page that is linkable such as http://www.worldfamousgiftbaskets.net/shopping/shopdisplayproducts.asp?id=4&cat=Gourmet however when you scroll through that category by clicking the next page button you get http://www.worldfamousgiftbaskets.net/shopping/shopdisplayproducts.asp?page=2 and this page is not linkable. You cannot send someone to that 2nd dynamically generated page.)
What do I have to put in the URL? What sessions do I have to start, how do I set that up in order to accomplish this?
Thanks for any help.
Wayne www.WorldFamousGiftBaskets.net
Edited by - ProductivePC on April 01 2004 00:55:11 |
|
support
Administrator
4679 Posts |
Posted - April 01 2004 : 01:14:58
|
Vp-ASp needs to "remember" what generated the page (the sql). So you cannot bookmark a second page (or any page with a page=x) since when the person comes back to the site, the original SQl is long gone and there is no way to determine what products were being displayed.
VP-ASP Support
|
|
|
ProductivePC
VP-CART New User
USA
199 Posts |
Posted - April 01 2004 : 02:14:51
|
Is there a way to force that remembering that we can type into the URL? As in.... when they click on a category... there are so many things that happen at that point in time... is there a way to force this via the URL.
Is there a way to incorporate this into future versions.. this would be extremely important for when submitting to search engines, sending links out to people for certain products?
I would not mind hiding the code in a link that looks like this here in order to get it to that point where I can now submit even if the url was 100 characters long, hell 200 characters long. I wouldn't care how long it was if it is possible.
Your shopping cart would be the hottest shopping cart on the market when people find out that you could link your pages to other dynamically generated pages so that the search engines could walk your dynamically generated website. Something to think about if you can make this possible. As it is right now, most search engines will not walk your dynamics... they get as far as that first page and then leave your page.
This is a definite need that could make someone a LOT of money. I would use the shopping cart if I knew it was capable of letting the search engines walk the dynamically generated pages. I would probably pay a pretty penny for that cart.
Wayne www.WorldFamousGiftBaskets.net |
|
|
support
Administrator
4679 Posts |
Posted - April 01 2004 : 03:01:58
|
We have "solved" this issue already by providing a facility to dynamically generate all the product pages as "static" HTML which search engines will walk. On the static pages which are template driven, you have links to the real dynamic page of your shop.
This static generation is part of VP-ASP 5.0 Option Package
Howard Kadetz Vp-ASP
|
|
|
IfOnly
VP-CART New User
United Kingdom
90 Posts |
Posted - April 01 2004 : 07:23:20
|
Related to this possibly does this mean that drop down java script menus with the categories for the URL's in the drop downs will not work. I thought of buying the menu software below and using them to replace the left text category menu that VP-ASP provides.
http://www.likno.com/index.html
Regards
Phil |
|
|
ProductivePC
VP-CART New User
USA
199 Posts |
|
rrold1
Starting Member
48 Posts |
Posted - April 12 2004 : 15:05:39
|
You can link to internal pages with some code changes. Since "SQL" is no longer remembered, you presently get redirected to the message "No products matched your search"
What you need to do is re-create sql and then redirect back so the page runs again with the sql created. Since there is a page number in the desired "bookmark" url, VPASP assumes that SQL has been created. Since it has not, you need to alter things so things process to just before the first page is generated and then rerun to display the numbered page.
I have done a lot of recoding, page renaming, and sub additions so line numbers wouldn't be much help. You may also have to add some code to get the category id and page ( I called it bookpagerefer)from the url. Be sure to add lines to protect from SQL injection where required. Hopefully you can get an idea from the partial code below and get it working. Again this is partial but it should send you in the right direction.
In shopdisplayproducts.asp look for the point where VPASP checks for a valid SQL session variable sql=GetSess("sqlquery")
I created an if then statement where a new sub is called. The sub includes part of the code that is called if no page is requested (search your code for the comment " first time through " to see this)
NOTE: I basically "hacked this together" so I am sure that there is room for improvement if someone wants to invest the time.
sql=GetSess("sqlquery") if sql="" then ' *******new code directbookmarklink ' *******new code end if ' *******new code
Sub directbookmarklink ' *****new sub ProcessFirst CreateSql setsess "sqlquery",sql dim booksend booksend= "shopdisplayproducts.asp?" & "ID=" & cat_id & "&page=" & bookpagerefer response.redirect booksend end sub
I also had an issue where the Mod would not work when a second "bookmark" link was clicked. I fixed this by adding a line that compares the current ID to the requested ID. If they do not match, the new sub is called. You may or may not need this. Due to my other modifications, I can not say for sure.
Good Luck,
Steve
Edited by - rrold1 on April 12 2004 15:11:20 |
|
|
ProductivePC
VP-CART New User
USA
199 Posts |
Posted - April 15 2004 : 02:59:34
|
Wow,
Thanks Steve. Unfortunately, I myself am not that confident that I know ASP well enough to debug anything that I might screw-up in modifying the existing code without step by step... lol however; I do have a programmer that is very astute in ASP so I will hand this over to him and see what he thinks....
Thank you again.
Wayne www.WorldFamousGiftBaskets.net |
|
|
|
Topic |
|