Shopping cart and other virtual pages redirecting

Hi all,

I'm on WP 3.0.5 and BP 1.2.7 with a multisite install. I've searched and read all related posts but am still stuck.

I've installed marketpress and can't get the shopping cart, products or order status pages to load. When I click on a link for one of those pages, it sends me to the site home page. I can see the shopping cart widget, I can add products to the cart, and I can clear the cart, but I can't check out - it just sends me to the home page.

Per other support postings, I've tried the following:
- changed the shopping cart slug in the Presentation tab of Store Settings and saved several times
- de-activated and activated marketpress plugin (both in network and non-network modes)
- de-activated multi-domain and domain mapping plugins

Interestingly, I couldn't load the Store page until I followed the "Edit Page" link in the Messages tab and then published the page.

Is there something simple I'm missing? Could really use your help as I'm operating on a deadline.

Much Thanks

  • Ron
    • WPMU DEV Initiate

    Hi guys,

    Since then I've reset the permalinks and even changed the permalink structure on the site to no avail. I've deactivated many of my plugins in the hunt for a misbehaving plugins but no luck so far. I even deactivated the membership plugin.

    On the hunch it had to do with some other aspect of loading virtual pages I found a virtual pages plugin, loaded it, and am able to generate virtual pages that way. But still no marketpress virtual pages.

    I'll continue to deactivate plugins that could be misbehavior. Any other ideas? Appreciate your replies and willingness to sort this out quickly.

  • Ron
    • WPMU DEV Initiate

    Me again...

    I went through the following in trying to get these virtual pages to load:

    Set/reset permalinks
    Change virtual page slugs
    Activate/deactivate marketpress plugin
    Reinstall marketpress
    Deactivate all plugins - (I deactivated every single one)
    Htaccess - compare to default WP file - OK
    Remove and related shopping links from top nav
    Upgrade to WP 3.1

    It's late, I'm tired and none of the above has worked, although I am now upgraded to 3.1. Please, please help me understand how to resolve this. From what I can glean from googling similar problems, is that it may be a rewrite issue? Here's an article I found where the author was trying to generate a virtual page and it kept defaulting to the home page:

    http://wordpress.stackexchange.com/questions/9870/how-do-you-create-a-virtual-page-in-wordpress

    Not the same problem for sure, but perhaps directionally correct? I have a BIG deadline looming and need to get this shopping cart working. I really appreciate any brain power you can throw at it!

  • Philip John
    • DEV MAN’s Apprentice

    Hiya,

    Okay, I've had a look at your install and tried to find where the issue is. In doing so I hit some made up URLs, such as;

    /shop/foobar
    /shop/barfoo
    /foobar

    Each of these non-existent pages were redirected to the home page in exactly the same way as the Cart and other MarketPress pages.

    The message returned from WordPress was "Moved temporarily" whereas they should all have returned "Page not found".

    This suggests there is a rule in your .htaccess somewhere which is redirecting these pages.

    Can you print the contents of your .htacess here, or e-mail it to me?

    Thanks,
    Phil

  • Ron
    • WPMU DEV Initiate

    Here is the htaccess file. Thanks for giving it a look.

    RewriteEngine On
    RewriteBase /

    #uploaded files
    RewriteRule ^(.*/)?files/$ index.php [L]
    RewriteCond %{REQUEST_URI} !.*wp-content/plugins.*
    RewriteRule ^(.*/)?files/(.*) wp-includes/ms-files.php?file=$2 [L]

    # add a trailing slash to /wp-admin
    RewriteCond %{REQUEST_URI} ^.*/wp-admin$
    RewriteRule ^(.+)$ $1/ [R=301,L]

    RewriteCond %{REQUEST_FILENAME} -f [OR]
    RewriteCond %{REQUEST_FILENAME} -d
    RewriteRule . - [L]
    RewriteRule ^([_0-9a-zA-Z-]+/)?(wp-.*) $2 [L]
    RewriteRule ^([_0-9a-zA-Z-]+/)?(.*\.php)$ $2 [L]
    RewriteRule . index.php [L]

    <IfModule mod_security.c>
    <Files async-upload.php>
    SecFilterEngine Off
    SecFilterScanPOST Off
    </Files>
    </IfModule>

  • Ron
    • WPMU DEV Initiate

    Ok, I think I figured it out.

    There is a line in the wp-config.php file that was uncommented:

    define( 'NOBLOGREDIRECT', 'http://mydriving4life.com' );

    Once I commented it, everything appears to be working. I think the reason for uncommenting this line is in the case registration is turned off, then it redirects you to a page of your choosing if you try to visit a non-existent location. Here's the blurb from the Settings admin screen where registration is turned on or off:

    "If registration is disabled, please set NOBLOGREDIRECT in wp-config.php to a URL you will redirect visitors to if they visit a non-existent site."

    You may want to include a note in your installation instructions that this setting may foil the virtual pages from loading. Hopefully this saves someone else a little time and sleep!

    Cheers,
    driving4

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.