Post by xmanux » Tue May 03, 2016 2:27 am

Hello, I'm here with question. When I go to my site with www, it's everything ok.. But if I don't write www in address, my template don't load perfectly.. Why? Thank you :)

Newbie

Posts

Joined
Sat Apr 09, 2016 11:14 pm

Post by EvolveWebHosting » Tue May 03, 2016 4:00 am

Place this under 'RewriteEngine On' in your .htaccess file:

RewriteCond %{HTTP_HOST} ^yourdomain.com [NC]
RewriteRule ^(.*)$ http://www.yourdomain.com/$1 [L,R=301]

Make sure both config files include www. in the HTTP and HTTPS sections.

Image
https://www.evolvewebhost.com
$10.49 .com Registration and $9.99 .com Transfers in now
Guaranteed top level opencart performance and support. Risk free 30 day money back guarantee & free transfers.
Image


User avatar
Active Member

Posts

Joined
Fri Mar 27, 2015 11:13 pm
Location - Denver, Colorado, USA

Post by viethemes » Tue May 03, 2016 11:38 pm


http://www.viethemes.com - OpenCart turtorials, news, tips and stricks, extension

Our extensions:
Visual Theme Editor - Powerful tool for customizing style of any theme visually
Live Theme Editor - Customize layout, colors, backgrounds, fonts of the default theme
Theme Animation - Animation Editor for any theme

Extra Positions PRO, Custom JavaScript, Custom CSS and others


User avatar
Active Member

Posts

Joined
Thu Jan 08, 2015 12:17 pm


Post by doktorek » Thu May 05, 2016 7:00 am

and then do a 301 redirect of non.www to www.

New member

Posts

Joined
Thu Apr 28, 2016 8:40 pm

Post by IP_CAM » Thu May 05, 2016 9:08 am

and just to tell you why:
FONT AWESOME GRAFIC PIC's will not function, in both way's, for some to me unknown reason.
either, you have:
http: // yourshop
or:
http: // www. yourshop
defined in your config.php files, then, this will be the way, Font Awesome will be visible in full, including it's built in grafic pics.

Therefore, to make sure, in OC v.2.x, you are required to place a rerouting Command line into the .htaccess file (as shown above!), to make sure, that oc2-technically 'irregular' Site Call's are redirected to the correct VALUE, i.e., /www.yourshop, automatically, if your config.php Link setting is /www.yourshop.
Or then, if you have http: // yourshop as Setting, the opposite way of doing this, would be the case!

One Way out would be, to link Font Awesome, in full, from a well powered external Site. Then, it (usually) works both ways. Just likely a little 'slower', this 'thing' uses a lot of ressources, as I found out!
Good Luck! ;)
Ernie

I'm rarely still active at the OC Forum. To reach me, contact: jti@jacob.ch
A Demoversion of my free OpenCart LIGHT v.1.5.6.5 Software Edition
can be seen in real Action here: http://www.jti.li/shop/
---
1'000+ FREE OC Extension-Repositories - from OC v.1.5.x up,
on the world's largest OC-related Github Site: https://github.com/IP-CAM
---
Image


User avatar
Legendary Member

Posts

Joined
Tue Mar 04, 2014 1:37 am
Location - Switzerland
Who is online

Users browsing this forum: No registered users and 48 guests