Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

wordpress admin area #1

Closed
miziomon opened this issue Jun 8, 2012 · 5 comments
Closed

wordpress admin area #1

miziomon opened this issue Jun 8, 2012 · 5 comments
Assignees

Comments

@miziomon
Copy link

miziomon commented Jun 8, 2012

I can't work in admin area...

http://test-domanin/wp/wp-login.php load css from root and when a try to login wordpress redirect to http://test-domanin/wp-login.php (not in subdirectory)

is there a workaround?

@miziomon
Copy link
Author

miziomon commented Jun 8, 2012

...resolved adding this line

define( 'WP_SITEURL', 'http://' . $_SERVER['SERVER_NAME'] . '/wp/');

@markjaquith
Copy link
Owner

You just need to follow the normal process of moving WP into a subdirectory. But perhaps I should put the constants in wp-config.php to assist with initial install.

@iandunn
Copy link

iandunn commented Aug 9, 2012

My approach to this was a bit different. I renamed the wp directory to wordpress (because I'm anal-retentive like that) and didn't want to have to type example.com/wordpress/wp-admin every time I wanted to visit the admin panel, so I setup rewrite rules to rewrite wordpress/wp-admin requests as just wp-admin.

With this approach, you don't need to change the site_url at all.

@WraithKenny
Copy link

Ian, I think that hack breaks get_home_path(), the RELOCATE constant, and maybe other things. WordPress compares 'siteurl' against $_SERVER['SCRIPT_FILENAME'] for somethings. I'm not sure what effect it'd have on the cookie constants in multisite either. Just a heads up in case you have these issues in the future. You probably won't run MS, relocate via the constant, or erase your htaccess so you might be fine with that set up.

@WraithKenny
Copy link

http://core.trac.wordpress.org/ticket/22772 would provide a constant that'd clean up any issues I mentioned.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants