Monday, October 3, 2022
Htaccess

Cara membuat redirect domain dari non www. ke www.

Caranya adalah sebagai berikut :

  • Login ke akun hosting anda.
  • Masuk ke menu file manager dan masuk ke folder public_html
  • Scroll halaman kebawah dan perhatikan pada textbox create new file
  • Pada textbox masukkan nama file .htaccess (titik htaccess) pastikan ada tanda titik didepan kemudian create file
  • masukan kode berikut : misal dari non www.  ke  www.
RewriteEngine On 
RewriteBase / 
RewriteCond %{HTTP_HOST} ^yourdomain.com [NC] 
RewriteRule ^(.*)$ http://www.yourdomain.com/$1 [L,R=301]
(Visited 34 times, 1 visits today)
Klik untuk berbagi dengan orang lain
Baca Juga :  Proteksi direktori web dengan .htaccess

Similar Posts


Warning: Trying to access array offset on value of type bool in /home/des1gn/hendro-wibiksono.web.id/wp-content/plugins/floating-related-posts/floating-related-posts-pro.php on line 270

Warning: Trying to access array offset on value of type bool in /home/des1gn/hendro-wibiksono.web.id/wp-content/plugins/floating-related-posts/floating-related-posts-pro.php on line 270

Warning: Trying to access array offset on value of type bool in /home/des1gn/hendro-wibiksono.web.id/wp-content/plugins/floating-related-posts/floating-related-posts-pro.php on line 270

Warning: Trying to access array offset on value of type bool in /home/des1gn/hendro-wibiksono.web.id/wp-content/plugins/floating-related-posts/floating-related-posts-pro.php on line 270

Warning: Trying to access array offset on value of type bool in /home/des1gn/hendro-wibiksono.web.id/wp-content/plugins/floating-related-posts/floating-related-posts-pro.php on line 270

Warning: Trying to access array offset on value of type bool in /home/des1gn/hendro-wibiksono.web.id/wp-content/plugins/floating-related-posts/floating-related-posts-pro.php on line 270

Warning: Trying to access array offset on value of type bool in /home/des1gn/hendro-wibiksono.web.id/wp-content/plugins/floating-related-posts/floating-related-posts-pro.php on line 270

Warning: Trying to access array offset on value of type bool in /home/des1gn/hendro-wibiksono.web.id/wp-content/plugins/floating-related-posts/floating-related-posts-pro.php on line 270

Warning: Trying to access array offset on value of type bool in /home/des1gn/hendro-wibiksono.web.id/wp-content/plugins/floating-related-posts/floating-related-posts-pro.php on line 270