Revision 361 is a pre-publication revision. (Viewing current revision instead.)

Force www via htaccess using a WordPress plugin (Redirection)

Really all that is necessary is this: Go Settings -> General: WordPress Address (URL) Site Address (URL) And set both of them to www.yoursite.com (instead of yoursite.com), wordpress automagically takes care for setting all the urls to www.yoursite.com and that's it. If that isn't enough: Install the Redirection plugin and you can just set the options to *.mydomain.com/* to redirect to www.mydomain.com/* with a 301, and that will take care of your htaccess as long as you keep the plugin active. It is a good idea to use the Redirection plugin instead of directly editing your htaccess plugin, as anytime you save or reload your permalink settings, WordPress will overwrite your .htaccesss (some plugins may do that as well).

Revisions

  • February 18, 2013 @ 23:16:47 [Current Revision] by PeterLugg
  • February 18, 2013 @ 23:16:42 by PeterLugg
  • February 18, 2013 @ 23:13:24 by PeterLugg

Revision Differences

February 18, 2013 @ 23:13:24Current Revision
Content
 Added: Really all that is necessary is this:
 Added: Go Settings -> General: WordPress Address (URL) Site Address (URL)
 Added: And set both of them to www.yoursite.com (instead of yoursite.com), wordpress automagically takes care for setting all the urls to www.yoursite.com and that's it.
Deleted: Added: If that isn't enough:
 Added: Install the Redirection plugin and you can just set the options to *.mydomain.com/* to redirect to www.mydomain.com/* with a 301, and that will take care of your htaccess as long as you keep the plugin active.
 Added: It is a good idea to use the Redirection plugin instead of directly editing your htaccess plugin, as anytime you save or reload your permalink settings, WordPress will overwrite your .htaccesss (some plugins may do that as well).

Note: Spaces may be added to comparison text to allow better line wrapping.

Tags: , ,

No comments yet.

Leave a Reply