• JS

    (@jsylvia90)


    I have a creativeplayschoolnb.com and is also has an alias thenephewsrestaruanct.com that we have been using for a second site in a subdirectory here thenephewsrestaurant.com/thenephewsrestaurant/. We used a javascript redirect for over 10 years when both sites were HTML.

    The creativeplayschoolnb.com new wp site is fine, and we are trying to use an .htaccess to redirect thenewphewsrestaurant.com.

    We’ve tried several different suggested .htaccess rewrite codes the closest being:

    rewritecond %{http_host} ^thenephewsrestaurant.com [nc]
    rewriterule ^(.*)$ https://www.thenephewsrestaurant.com/thenephewsrestaurant/$1 [r=301,nc]

    The problem is that it only works for thenephewsrestaurant.com but does not for https://www.thenephewsrestaurant.com.

    I am waiting on my host support for suggestions, but thought I would try here in the mean time. Any suggestions would be appreciated. Thanks!

Viewing 1 replies (of 1 total)
  • Thread Starter JS

    (@jsylvia90)

    OK! I searched and searched and finally found the correct code that works across the board on our server. I tired several variations from different sources, but this is the one that worked… Just in case anyone is interested :

    RewriteEngine On
    RewriteCond %{HTTP_HOST} ^(www.)?thenephewsrestaurant.com$
    RewriteRule ^(/)?$ thenephewsrestaurant [L]
Viewing 1 replies (of 1 total)
  • The topic ‘Another redirect issue…’ is closed to new replies.