LinuxQuestions.org
LinuxAnswers - the LQ Linux tutorial section.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 03-01-2013, 10:40 PM   #1
vishalsamyal
LQ Newbie
 
Registered: Oct 2012
Location: India
Posts: 25
Blog Entries: 3

Rep: Reputation: Disabled
Apache redirection issue


Hello,

I want to redirect a dynamic url but facing some issue with that. Please help to resolve this. Following are the details:

old url :

http://abc.com/?xyz=pq

new url will be :

http://abc.com/


http://abc.com/?xyz=pq url must be redirect to "http://abc.com/"

thanks in advance.
 
Old 03-02-2013, 03:14 AM   #2
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 11,255

Rep: Reputation: 1421Reputation: 1421Reputation: 1421Reputation: 1421Reputation: 1421Reputation: 1421Reputation: 1421Reputation: 1421Reputation: 1421Reputation: 1421
Hi,

You can use mod_rewrite:
Code:
RewriteEngine on

RewriteCond %{QUERY_STRING} ^xyz=pq$
RewriteRule (.*) /? [L]
cheers
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Apache redirection sanketpatel.86 Linux - Software 3 02-25-2013 05:23 AM
traffic redirection issue guillermo Linux - Networking 4 08-04-2008 05:20 PM
redirection in apache ice99 Linux - Networking 3 07-17-2006 01:24 PM
Redirection in Apache gonzo22 Linux - Networking 5 02-12-2005 10:54 AM
Apache redirection question... WeNdeL Linux - Software 2 04-01-2004 11:48 AM


All times are GMT -5. The time now is 06:57 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration