Single WordPress With SubDirectory
set $dir "";
if ($request_uri ~ ^/([^/]*)/.*$ ) {
set $dir1 /$1;
}
location / {
try_files $uri $uri/ $dir1/index.php?$args;
}
@dettlee
just my worth of 2cents comment, when creating in subdirectory it should allow to create another subdirectory under other name
I'm not understand your question, I'm assuming you have single wordpress website called example.com at /var/www/example.com/htdocs and you want to create subdirectory called dir1 and dir2 right ?
yes i had move 1 single wordpress to subdirectory from above changes:) so i had:
example.com/dir1 ( path = /var/www/example.com/htdocs/v1/ )
i would like to make another dir2 under example.com it would look like
example.com/dir2 ( path = /var/www/example.com/htdocs/v2/ )
is that possible now? thank you for you reply
@dettlee
Yes its works. You have to create subdirectory v1 and v2 and add index.php inside those direcrory.
but when i run ee site create example.com --wpfc example.com already exist, exit status = 1 got the error above
@dettlee example.com alredy exist in your ssystem. cross check this
ls /etc/nginx/sites-available/example.com
ls /var/www/example.com
ok, silly me. i think this mean i have to manually create v1 & v2. not using ee site. am i right?
yes
Linked #66
Can we get an update on this item?
Single Install Site on a sub Directory....
how does one accomplish it?
i'm using the most recent EE ..
Partially related, but I really like the way Cliff Seal is going about it on the WordPress side of things here: https://youtu.be/pUGrDdvkwtk?t=19m36s
Will be handled in https://github.com/EasyEngine/easyengine/issues/66