Problem with extra query strings

ISAPI_Rewrite is Apache mod_rewrite compatible URL rewriter for Microsoft IIS
User avatar
Posts: 7
Joined: 18 Oct 2012, 17:16

Problem with extra query strings

18 Oct 2012, 17:20

On our product landing pages we have a facebook like button which posts to facebook a direct link to the page.

It used to work fine, but now facebook is sending all sorts of query strings along with it something like this.

http://www.ourwebsite.com/parts/FBFCH08 ... 1481237582

we currently have this as a rewrite rule.
RewriteRule ^/parts/([^/]+)\.htm$ /catalog/part/part-static.asp\?PCode=$1 [NC,L,U]

I need someway for it to totally ignore the extra query strings. Please help.

User avatar
Posts: 1264
Joined: 07 Mar 2012, 10:16

Re: Problem with extra query strings

18 Oct 2012, 20:18

Hello,

Try using the following:

Code: Select all
RewriteCond %{QUERY_STRING} .*
RewriteRule ^/parts/([^/]+)\.htm$ /catalog/part/part-static.asp\?PCode=$1? [NC,L,U]


Regards
Andrew

User avatar
Posts: 16
Joined: 19 Nov 2012, 22:21

Re: Problem with extra query strings

20 Nov 2012, 23:50

I hope this works. Thanks.

User avatar
Posts: 7
Joined: 18 Oct 2012, 17:16

Re: Problem with extra query strings

25 Nov 2012, 19:59

I'm not sure if it's working or not... for some reason I dont think the updated .htaccess file is being read. I'm using version 3.1.0.68

and the modification you presented along with some other changes that I made are not working at all. When I open Helicon Manager in IIS7 I can see the changes that I made in the file, but they aren't active (for lack of a better word)

I've even recycled our application pools.

Any Advice?

User avatar
Posts: 1264
Joined: 07 Mar 2012, 10:16

Re: Problem with extra query strings

25 Nov 2012, 23:05

Hello,

First, check of you have full or LITE version of ISAPI_Rewrite. As lite version has certain limitations.

Second, please, provide a rewrite.log for the testing request.
Logging issues described in FAQ

Regards
Andrew

User avatar
Posts: 7
Joined: 18 Oct 2012, 17:16

Re: Problem with extra query strings

25 Nov 2012, 23:23

I have a full version... and looking in the installation directory I do not see any logs.

Do I need to reboot the entire server for these changes to take effect?

User avatar
Posts: 7
Joined: 18 Oct 2012, 17:16

Re: Problem with extra query strings

26 Nov 2012, 01:20

Ok, did find this log, it's full of thousands of lines like this, no errors.

[11/25/2012 15:55:22] [LicenseManager] Credentials for {OurCompanyName} are valid

I guess I'll just reboot the server later tonight when fewer users are on.

User avatar
Posts: 1264
Joined: 07 Mar 2012, 10:16

Re: Problem with extra query strings

26 Nov 2012, 02:27

That was a line from error.log. the one we need is rewrite.log - it has processing order of the requests.

To ease the work:
- have logging disabled at all times.
- enter the rewrite.log, erase it's content, save and close
- enable logging
- run testing request
- disable logging
- see what's inside the rewrite.log and send it to us.

Regards
Andrew

User avatar
Posts: 7
Joined: 18 Oct 2012, 17:16

Re: Problem with extra query strings

26 Nov 2012, 22:59

Well that's the odd part. I cannot locate the rewrite.log at all. Anywhere on the server, yet it's running, just not updating with the new .htaccess file. I should note that this is running on IIS 7. Infact, I cannot locate the httpd.conf file. There is a file called httpd.conf.bak located in the installation directory. When I open the manager it shows that the file should be there and even gives me the option to edit, but that file does not exist on the server that I can find. I did a full server search for it.

I guess I'm going to have to ask for help on this matter from my server hosting provider and see what the heck they did when setting this up in the last upgrade.

User avatar
Posts: 1264
Joined: 07 Mar 2012, 10:16

Re: Problem with extra query strings

27 Nov 2012, 01:15

After that you may create a ticket at the Helicon helpdesk and ask for remote assistance.

Regards
Andrew

User avatar
Posts: 7
Joined: 18 Oct 2012, 17:16

Re: Problem with extra query strings

28 Nov 2012, 05:31

Thank you, we did get it worked out. They'd set the file to hidden and basically 3.0 was reading the httpd.conf as well as the .htaccess file and was over riding each other at points....

Thanks for your help and patience.

Return to ISAPI_Rewrite 3.0

Who is online

Users browsing this forum: No registered users and 0 guests