Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7700361
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T22:41:26+00:00 2026-05-31T22:41:26+00:00

I am working on a 301 redirect for an old OsCommerce website. The problem

  • 0

I am working on a 301 redirect for an old OsCommerce website. The problem is it is hosted on a IIS/Windows server so htaccess modrewrite is not an option.

At this point I have redirected as follows

Header( "HTTP/1.1 301 Moved Permanently" );
Header( "Location: http://www.site.org.au/store/default.asp" ); 
exit();

However because the old shop URls are dynamic I am trying to redirect based on the cPath=something to the corrisponding page on the new site. So far I have

if (isset ($_GET['cPath']))
{
$cPath = $_GET['cPath'];

if ($cPath == 22_33) { $goto = "http://www.store.org.au/store/shop_clothing/shop_clothing_summer_adults_ladies"; }

if ($cPath == 21) {$goto = "http://www.cancervic.org.au/store/shop_shade"; }

header("HTTP/1.1 301 Moved Permanently");
header("Location: " . $goto);
exit();
}

problem is with this I get an error:

Parse error: syntax error, unexpected T_STRING in E:\inetpub\esvc001202\index.php

I’d appreciate any tips on getting this to work.

Thanks

Cheers
Laurence

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-31T22:41:28+00:00Added an answer on May 31, 2026 at 10:41 pm

    Quote this string:

    if ($cPath == "22_33")
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am trying to redirect a page via my .htaccess, but it does not
Trying to set 301 redirect in .htaccess file and here is what i am
I have the following redirects in my htaccess file Redirect 301 /communityed/index.htm http://www.domain.com/community_education Redirect
I moved a WordPress installation to a new folder on a Windows/ IIS server.
I tried putting this code Redirect 301 /pagename http://www.example.com/pagename.html in my .htaccess file; but
I'm looking to 301 redirect an URL from a old version of a site
I'm trying to redirect my old pages to new pages but this is not
Hi guys trying to get a 301 redirect working and having trouble. I need
So my .htaccess file looks like this RewriteBase / Redirect 301 /page.html http://www.yoursite.com/newpage.html Redirect
The curl Command is working on one server and does not work on other.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.