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

  • Home
  • SEARCH
  • 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 7913107
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T13:45:58+00:00 2026-06-03T13:45:58+00:00

This should be simple – can’t figure out where I’m going wrong: We have

  • 0

This should be simple – can’t figure out where I’m going wrong:

We have WordPress installed in the following location: http://example.com/gallery/cms
and I want the site to be visible at http://example.com/gallery

I have the WordPress Address set to http://example.com/gallery/cms and the Site Address set to http://example.com/gallery

I copied the .htaccess and index.php to the /gallery folder. The .htaccess contains the following code:

<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /gallery/
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /gallery/index.php [L]
</IfModule>

The index.php contains the following code:

define('WP_USE_THEMES', true);
require('./cms/wp-blog-header.php');

The home page loads up fine, but any interior pages kick of a “Not Found” error: http://playstartshere.com/gallery/specs/ yields The requested URL /gallery/specs/ was not found on this server.

Where am I going wrong? I tried changing index.php to:

define('WP_USE_THEMES', true);
require('./gallery/cms/wp-blog-header.php');

but that broke the site entirely.

EDIT: ANSWER

Apache was indeed incorrectly configured; RewriteEngine was not enabled. However, the .htaccess was also wrong. Correct .htaccess for a configuration like what’s above is:

<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /gallery/cms/
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /gallery/cms/index.php [L]
</IfModule>

Hope that helps someone else.

  • 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-03T13:46:00+00:00Added an answer on June 3, 2026 at 1:46 pm

    /gallery/specs/ is matched by this rule:

    RewriteRule ^index\.php$ - [L]
    

    which block access

    Try /gallery/.htaccess with:

    RewriteEngine On
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule .* index.php [L]
    

    without / prepending index.php, apache will search in current directory

    edit

    Once again with different approach:

    set all wordpress URLs to http://example.com/gallery
    put all wordpress files in /gallery/cms

    put one .htaccess in /gallery/cms

    RewriteEngine On
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule .* index.php [L]
    

    put second .htaccess in /gallery (without index.php)

    RewriteEngine On
    RewriteCond %{REQUEST_URI} !/gallery/cms
    RewriteRule ^(.*)$ /gallery/cms/$1 [L]
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

This should seem simple enough, but can't figure it out. I was porting a
This should be simple but I can't figure it out <?php $testid = 240;
This should be simple, but I can't figure it out For example, lets assume
I feel like this should be simple, but can't figure it out: What's the
This should be simple, but I can't figure out how to do this in
This should be simple, yet I can't get it to work. I have a
I know this should be simple but I can't make it work. I have
This should be simple but I can't find a solution: I have a custom
I feel like this should be simple but i can't work out how to
This should be simple, but I can't get it to work. I have a

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.