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 8599983
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T01:30:57+00:00 2026-06-12T01:30:57+00:00

I am having more than 9 params in my url to be mapped into

  • 0

I am having more than 9 params in my url to be mapped into particular php file. Url is

http://abc.com/USA/NY/male/NY/all-status/all-religion/all-ethnicity/all-cast/all-professions/all-educations/recent_posted

and my htaccess rule is

RewriteRule
^USA/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/?$
search.php?counrty=USA&state=$1&gender=$2&r_city=$3&r_mstatus=$4&r_religion=$5&r_ethnicity=$6&r_cast=$7&r_profession=$8&r_education=$9&sort_by=$10
[NC]

It is not working

Can please anybody sort out this issue? I need proper regex rule and URL

  • 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-06-12T01:30:59+00:00Added an answer on June 12, 2026 at 1:30 am

    Creating such rule is restricted and bad practice & even worse that your passing the parameters to a search script; As your script progresses your most likely going to want other parameters passed other then USA, meaning your need a new rewrite for each route.

    Really you should pass the entire url to your php script to handle the route.

    RewriteEngine On
    Options -Indexes
    RewriteBase /
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteRule ^search/(.*)$ search.php?route=$1 [L,QSA]
    

    This way you can explode('/',$_GET['route']) within your script, giving you an array of all your route parameters.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

What is the purpose of having more than one class in a Java file
I encountered a problem after having more than one texture in my engine. My
I am creating an application for the iPhone which involves having more than one
Okay, mysql indexing. Is indexing nothing more than having a unique ID for each
I am having a facebook fan page with more than 12 tabs added but
I am having a look af a big C++ project with more than 100
I am having a thirty of notes databases. Each database has more than 20
I am having a strange problem, maybe something to do with Apache more than
I am having number of images with in my application. ( images more than
All, What is a really simple way of having a program do more than

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.