Redirection Issue

  • Hi there,

    Its been a disaster to me. Long time i am not able to redirect my website from www to non www.

    when ever i type only it opens to… BUT

    when i enter, the site doesnt open …. and i tried everything even to rewrite in htaccess but cant help myself.

    Please help me to redirect the www and non-www versions of URL to the same site.i.e

    Below is my .htaccess content#########

    # BEGIN WordPress
    # The directives (lines) between BEGIN WordPress and END WordPress are
    # dynamically generated, and should only be modified via WordPress filters.
    # Any changes to the directives between these markers will be overwritten.
    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteCond %{HTTP_HOST}
    RewriteRule (.*)$1 [R=301,L]
    RewriteBase /
    RewriteRule ^index\.php$ – [L]
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php [L]

    # END WordPress

    # Wordfence WAF
    <IfModule LiteSpeed>
    php_value auto_prepend_file ‘/home/upayportal/public_html/wordfence-waf.php’
    <IfModule lsapi_module>
    php_value auto_prepend_file ‘/home/upayportal/public_html/wordfence-waf.php’
    <Files “.user.ini”>
    <IfModule mod_authz_core.c>
    Require all denied
    <IfModule !mod_authz_core.c>
    Order deny,allow
    Deny from all

    # END Wordfence WAF

    <IfModule mod_expires.c>
    ExpiresActive On
    AddType application/ .eot
    AddType application/x-font-ttf .ttf
    AddType application/x-font-opentype .otf
    AddType application/x-font-woff .woff
    AddType image/svg+xml .svg
    ExpiresByType application/ “access 1 year”
    ExpiresByType application/x-font-ttf “access 1 year”
    ExpiresByType application/x-font-opentype “access 1 year”
    ExpiresByType application/x-font-woff “access 1 year”
    ExpiresByType image/svg+xml “access 1 year”
    ExpiresByType image/webp “access 1 year”
    ExpiresByType image/gif “access 1 year”
    ExpiresByType image/jpg “access 1 year”
    ExpiresByType image/jpeg “access 1 year”
    ExpiresByType image/png “access 1 year”
    ExpiresByType image/x-icon “access 1 year”
    ExpiresByType text/css “access 3 month”
    ExpiresByType text/javascript “access 3 month”
    ExpiresByType text/html “access 3 month”
    ExpiresByType application/javascript “access 3 month”
    ExpiresByType application/x-javascript “access 3 month”
    ExpiresByType application/xhtml-xml “access 3 month”
    ExpiresByType application/pdf “access 3 month”
    ExpiresByType application/x-shockwave-flash “access 3 month”
    ExpiresDefault “access 3 month”

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

The ticket ‘Redirection Issue’ is closed to new replies.