• Say I have a WordPress Page called “life”.

    This would make a URL such as:

    yourdomainhere.com/life/

    Okay, if I wanted to then use zenphoto in a directory called “photos” but wanted the URL to look like:

    yourdomainhere.com/life/photos/

    then I have to create an actual directory called “life”. But I still want to keep that “life” page as the page you see when going to yourdomainhere.com/life/ – but instead MediaTemple kicks up a 403 page because it’s looking for an index page.

    Is there a .htaccess bit of code or some sort of code I can put into an index.php page inside that directory to tell it to look for the WordPress page – but still be able to access the ZenPhoto’s index page when viewing yourdomainhere.com/life/photos/ ?

    Or is this impossible?

    *edit* – I noticed that my subpages work okay, just to point it out. for example, my wordpress page /life/resume/ works fine — just not /life/

Viewing 4 replies - 1 through 4 (of 4 total)
  • Thread Starter spitstatic

    (@spitstatic)

    Hmmm. I guess this is not possible then?

    Thread Starter spitstatic

    (@spitstatic)

    Okay – if it’s not possible, does anyone have any suggestions for me as to a way I could do a regular .php page outside of WordPress, that isn’t a WordPress page, but will use my theme’s header and footer? I’d rather not have to keep up with two different headers/footers.

    Thread Starter spitstatic

    (@spitstatic)

    Wow – I found a way to do a wordpress page and a directory together! I experimented with this method, and it works:
    In the directory, create the index page, and then add to the top:

    <?php define('WP_USE_THEMES', true);
    require('./path/to/wordpress/wp-blog-header.php');?>

    Then, install the “include page” plugin. Make that page a template of sorts, by using <?php get_header();?>, etc, along with all your html and such — and where the content would be, replace it with the include page plugin code.

    This way, you have a page in a directory that can still be edited through wordpress. The only downside I know of is that if you want to change your template’s HTML, you have to edit in more than one place.

    Thread Starter spitstatic

    (@spitstatic)

    holy crap. I was wrong. Apparently, all you need is:

    <?php
    /* Short and sweet */
    define('WP_USE_THEMES', true);
    require('./path/to/wordpress/wp-blog-header.php');?>

    That’s it. The page will then appear and act normally without all that other stuff. Is this normal?

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Using Both Directories and WordPress Pages?’ is closed to new replies.