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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 1, 20262026-06-01T01:36:26+00:00 2026-06-01T01:36:26+00:00

Im trying to perform a mod rewriting to my web site. And I used

  • 0

Im trying to perform a mod rewriting to my web site. And I used to do this rewriting for quite some time. Of course I am very much upto the task until I met new requirement to create a rewritten URL with query strings after .html
Example – http://kypseli/admin/catagory.html?parent_id=1

I have used this this regex.
RewriteRule ^([A-Za-z0-9-/_]+).([html])/?$ index.php?rt=$1&%{QUERY_STRING}

But the query string value (parent_id) not passing.
This is working with out the .html part for perfection.

http://kypseli/admin/catagory/?parent_id=1
But I want it with .html part, as I have found lots and lots of same technique usage every where in WWW. here is one example
http://www.espncricinfo.com/ci/content/video_audio/559158.html?genre=46

Can someone please help.

  • 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-01T01:36:28+00:00Added an answer on June 1, 2026 at 1:36 am

    If you want to get all query string elements from the first query to be appended on your rewritten query you need to add the [QSA] flag to the rewriteRule, or [qsappend] if you prefer long and descriptive tags.

    RewriteRule ^([A-Za-z0-9-/_]+)/?$ index.php?rt=$1 [qsappend]
    

    Now I do not understand fully what you mean about ‘.html’, but I hope this will be enough.

    EDIT

    your problem is maybe the dot, it should be escaped \. and it should be in the optionnal part if it is optionall so :

    RewriteRule ^([A-Za-z0-9-/_]+)/?$ index.php?rt=$1 [qsappend]
    RewriteRule ^([A-Za-z0-9-/_]+)\.html?$ index.php?rt=$1 [qsappend]
    

    Or if you want only one rule, this should work (untested)

    RewriteRule ^([A-Za-z0-9-/_]+)([\.html|/])?$ index.php?rt=$1 [qsappend]
    

    And it’s unsure you really need the ? in your rewriteRule, you may want to apply it even without query strings.

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

Sidebar

Related Questions

I am trying to perform this AJAX post but for some reason I am
I'm trying to perform a DISTINCT clause on a query like this SELECT DISTINCT
I am trying to perform a search for documents within a SharePoint site, but
I am trying to perform formal auditing of my Spring web services requests/responses. I
Trying to perform a very simple task here. I have an <ol> that contains
I'm trying to perform the following query in LLBL and I'm not having much
I'm trying to perform some offline maintenance (dev database restore from live backup) on
I am trying to perform some generic number manipulation independent of the number type.
I have been trying to perform some OpenGL ES performance optimizations in an attempt
I'm trying to perform a complex issue, I have a query structured like this:

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.