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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T01:39:48+00:00 2026-05-23T01:39:48+00:00

My mod_rewrite code is: Options +FollowSymLinks Options +Indexes RewriteEngine On RewriteCond %{REQUEST_FILENAME} !-d RewriteCond

  • 0

My mod_rewrite code is:

Options +FollowSymLinks
Options +Indexes
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^(.+)?$ index.php?url=$1 [L,NC]

This structure is placed on my server path /beta

When I place the URL http://mydomain.com/beta/download everything works rewriting to the real path http://mydomain.com/beta/index.php?url=download

The problem happens with the relative paths. When I enter the URL http://mydomain.com/beta/download/box the rewriting goes to http://mydomain.com/beta/index.php?url=download/box… but….

All my relative paths, like my css folder, my js folder, image files…. everything with relative path in my index.php page crashes, cuz my relative paths become download/css, download/js, download/images… etc…

I know this problem happens in reason of the slash in the path “download/”, but how can I solve that using the mod_rewrite in .htaccess?

Can I prevent rewriting in relative paths? Or even in internal paths of my own domain?

How can I solve that WITHOUT change my relative paths to absolute paths?

Thanks

  • 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-05-23T01:39:49+00:00Added an answer on May 23, 2026 at 1:39 am

    Add a <base href="yoururl.com/beta/"; /> tag to your HTML head. Also add RewriteBase /beta/ to the htaccess if you’re in that subfolder

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

Sidebar

Related Questions

I wrote the following mod_rewrite: Options +FollowSymLinks RewriteEngine On RewriteBase / RewriteCond %{SCRIPT_FILENAME} !index\.php$
My htaccess have this code # # Apache/PHP settings: # Options -Indexes Options +FollowSymLinks
I have a below code in mod-rewrite.txt RewriteEngine On RewriteRule /\.htaccess$ - [F] RewriteCond
this is the url my application uses http://mydomain.com/index.php http://mydomain.com/video.php?id=29 http://mydomain.com/news.php?id=33 http://mydomain.com/photos.php?albumid=10 http://mydomain.com/archive.php http://mydomain.com/album.php http://mydomain.com/contact.php
i tried this code to hide the php file extension i have this url
Here's the mod_rewrite portion of my .htaccess Options +FollowSymlinks Options -Indexes # Prevent Direct
I use the below mod rewrite code for urls like: www.site.com/play/543 RewriteEngine On RewriteRule
how properly can I hide .php extensions form my url : example: www.example.com/index.php to
I want to allow special charecters in URL my htaccess code is <IfModule mod_rewrite.c>
I know how to make URL's rewrite, for example: www.example.com/index.php?id=1&cat=3 to www.example.com/1/3/ (or whatever).

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.