LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
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
 
LinkBack Search this Thread
Old 03-01-2013, 09: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, 02:14 AM   #2
bathory
Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 10,771

Rep: Reputation: 1283Reputation: 1283Reputation: 1283Reputation: 1283Reputation: 1283Reputation: 1283Reputation: 1283Reputation: 1283Reputation: 1283
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
Trackbacks are Off
Pingbacks are On
Refbacks are Off


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


All times are GMT -5. The time now is 05:26 AM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration