webshot on "Changing URL destination folder causes WP to break."

ساخت وبلاگ

webshot
Member
Posted 13 minutes ago #

Right now I have my wp install in a sub folder off the root on my host server. For example http://mysite.com/site. I do not need to or want to move the site to the root or another folder. But what my host does offer is the ability to point my url to a folder essentially making the site appear to be in the root so the user only sees http://mysite.com. But when I do this images and the CSS does not appear to load thus breaking the site. I tried changing the URL settings in the "General" section but that does not work either. By the way my host is 1and1 if this is any help.

Any tips or advice is greatly appreciated.

Yeah, that isn't going to work that way. While you host can make the site appear at example.com your files are still in example.com/site which suddenly WordPress can't find because of what your host did. Basically, there really isn't a way to selectively "lie" to just the visitors about where the site's files are, while also telling WordPress to ignore that. The method works fine for static sites that are just straight HTML files, but not a CMS like WordPress which always needs to know where its resource files are.

If you want to move WordPress up one directory, you only have two options which are supported here:

https://codex.wordpress.org/Moving_WordPress#Moving_Directories_On_Your_Existing_Server

or

https://codex.wordpress.org/Giving_WordPress_Its_Own_Directory#Using_a_pre-existing_subdirectory_install

WordPress ...
ما را در سایت WordPress دنبال می کنید

برچسب : نویسنده : استخدام کار wpss بازدید : 282 تاريخ : دوشنبه 10 خرداد 1395 ساعت: 5:26