Show Dropshop on only Products Page
      Categories
    Sponsors
 brought to you by shayne | 1 CommentLeave a Comment
Last updated: Monday, June 16, 2008 | 407 Views  [Post to Twitter]

So, this fix comes from the WP Ecommerce forums, where people were having issues with the Dropshop module not showing on only the products page as they had chosen in “Shop Settings”. There is an option to show on every page, or to show only on the Products Page, and when “only on Products Page” was selected, it did not function correctly.

Keep in mind this fix is for WP Ecommerce versions 3.6.6 and earlier, as this issue will be fixed in later releases.

So, you will navigate to “wp-content/plugins/wp-shopping-cart/wp_shopping_cart.php”. On line 2256 you will see the following line:

1
if(stristr(get_option('product_list_url'), ($_SERVER['SERVER_NAME'].$_SERVER['REQUEST_URI']))){</blockquote>

You will change that line to look like this:

1
<blockquote>if(stristr(('http://'.$_SERVER['SERVER_NAME'].$_SERVER['REQUEST_URI']), get_option('product_list_url'))){</blockquote>

That’s it!

If you’re using the default page setup that WP Ecommerce sets up on installation, then you’re fine, but if not you will have a problem as this fix will not do anything for you. Upon installtion, WP ECommerce makes a page title “Products Page” and it will be a URL like this: www.yoursite.com/products-page

If you’re using that default setup for your products page, then you’re fine. If you have renamed that page or have made a new page for your products, then this fix will not help you, as it is telling Dropshop to show up on your default products page, which as far as it knows is “www.yourdomain.com/products-page” no matter what you have renamed it to.

So, for that issue, you can edit the “products_list_url” area of the above code to point to your new page or renamed page.

That’s it for now, so until next time…

Other Posts You Might Like

Comments

1 comment
  1.  ShushiLov3r’ DropShop » Blog Archive » Hello world!
    July 14, 2008

    [...] Welcome to my DropShop. This is my first post here [...]

    CommentLeave a reply

Leave a Comment