Viewing 8 replies - 1 through 8 (of 8 total)
  • When you moved WP, did you also remember to move the .htaccess file to the new sub-folder?

    Thread Starter mpahlmann

    (@mpahlmann)

    Yes, I moved the .htaccess file to the new subfolder.

    The .htaccess file on my root folder contains this:

    RewriteEngine on

    AddHandler server-parsed .html

    ErrorDocument 404 /index.html

    The server-parsed line is there for my server side includes. I also added the 404 error line to redirect the 404’s to the home page. This is my temporary solution to this problem.

    Why is there a RewriteEngine on entry?

    Thread Starter mpahlmann

    (@mpahlmann)

    That was leftover from a previous htaccess file I used to create this one from. I’ve removed that line, unfortunately it didn’t resolve the 404 issue.

    Could there be an unrelated problem with your email subscription form?

    Thread Starter mpahlmann

    (@mpahlmann)

    My email subscription functions through a simple php file. Here are its contents:

    <?php

    if(isset($HTTP_POST_VARS[‘realname’])) {
    foreach($HTTP_POST_VARS as $item => $value) {
    if($value != “”) {
    $value = stripslashes($value);
    $value = ereg_replace(‘”‘, ”, $value);
    switch ($item) {
    case ’email’:
    # if(preg_match(‘/^[^@\s]+@([-a-z0-9]+\.)+[a-z]{2,}$/i’, $value)) {
    $in_email = $value;
    # }
    break;
    case ‘realname’:
    if($value != “”) {
    $in_name = $value;
    }
    break;
    }
    }
    }
    $in_name = trim($in_name);
    $in_email = trim($in_email);
    $in_str = “”;
    if(($in_name != “”) || ($in_email != “”)) {
    if(!file_exists(“log/subscribers.txt”)) {
    $in_str = “\”Name\”,\”Email\”\n”;
    }
    $in_str .= “\”$in_name\”,\”$in_email\”\n”;
    $FH = fopen(“log/subscribers.txt”, “a”);
    fputs($FH, $in_str);
    fclose($FH);
    }
    include “Thank_You.html”;
    exit;
    }
    include “index.html”
    ?>

    Thread Starter mpahlmann

    (@mpahlmann)

    esmi, the problem is resolved. Not sure how this happened. Could have been the .htaccess. I’ve reloaded my 404 page and it’s displaying now.

    Thanks for your time, I like your avatar.

    You’re welcome. Glad to hear that you got it sorted.

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘Moved WP to subfolder – html’s are 404 in root directory’ is closed to new replies.