728x90

 

 

 

  • Steven Stern (sterndata) 

    (@sterndata)

    Forum Moderator & Support Team Volunteer

    1 year, 7 months ago

    What’s your .htaccess file for this site?

    Thread Starter

    el_foz 

    (@el_foz)

    1 year, 7 months ago

    Hi Steve,
    Thanks for responding!

    Hmm, I’m on a Windows server. Sorry I should have mentioned that. There is no .htaccess file for IIS as far as I’m aware. Or?

    I’ve checked the default document list and it’s the same as for the working site.

    Moderator

    Steven Stern (sterndata) 

    (@sterndata)

    Forum Moderator & Support Team Volunteer

    1 year, 7 months ago

    When I hit any 404 on your site, it goes to a hosting-supplied 404 page and not the one that should be part of your site, so it’s something related to what would be handled by htaccess. I don’t use Windows so I’m not sure if I can help.

    Thread Starter

    el_foz 

    (@el_foz)

    1 year, 7 months ago

    Ok, you might have pointed me in the right direction here. On the site that works, a random 404 shows me the WordPress “page not found” page, not the hosting company 404 page.

    I don’t suppose you’d be able to provide the part of .htaccess that would usually handle the /feed/ redirect? Then I might be able to figure it out.

    Moderator

    Steven Stern (sterndata) 

    (@sterndata)

    Forum Moderator & Support Team Volunteer

    1 year, 7 months ago

    https://wordpress.org/support/article/htaccess/#basic-wp

    Thread Starter

    el_foz 

    (@el_foz)

    1 year, 7 months ago

    Fixed!
    I took a copy of the web.config file from the working site, changed the reference to the domain in one of the RULE tags so that it referred to the correct domain, and uploaded it to the broken site.
    The 404 handling immediately started being done by WordPress. It took a little while for the RSS feed to sort itself out, but that’s working too now – checked via Google Chrome Feeder extension.

    I haven’t copied the contents of the config file here because I’m not sure which parts, if any, might be sensitive info that could make my site vulnerable if publicly known. Although if the same file works for 2 of my sites, I guess there’s probably nothing sensitive in it…

    Thanks @sterndata for your tips!

Viewing 6 replies - 1 through 6 (of 6 total)

 

 

 

wordpress.org/support/article/htaccess/#basic-wp

+ Recent posts