0

I have a wordpress site set up domian.com Now i made a folder called scheduler and installed a laravel application. Inside my laravel application i have a .htaccess with the following inside the scheduler folder

<IfModule mod_rewrite.c>
<IfModule mod_negotiation.c>
    Options -MultiViews
</IfModule>

RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule .* public/index.php [QSA,L]

</IfModule>

and the following htaccess is the main server folder where the wordpress site lives

 # BEGIN WordPress
 <IfModule mod_rewrite.c>
 RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>

 # END WordPress

what i need to happen is domian.com/scheduler or domain.com/scheduler/..... should point to the scheduler directory and run the laravel app what am i doing wrong what do i need to add into the main directory htaccess

4
  • Where does it redirect to now? Commented Jul 31, 2016 at 16:21
  • it goes to wp-login.php when i go to mydomain.com/scheduler Commented Jul 31, 2016 at 16:21
  • Is the .htaccess you've shared in the /scheduler folder? Commented Jul 31, 2016 at 16:22
  • updated the question to include both htaccess info one for the /scheduler folder and one in the main wordpress app Commented Jul 31, 2016 at 16:25

2 Answers 2

1

Add another rewrite rule with last L flag:

# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^scheduler($|/) - [L]
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
# END WordPress
Sign up to request clarification or add additional context in comments.

Comments

0

In cpanel or your hosting provider , go to domains, then click on create a new domain, after clicking on this in domain field write your subdomain and in document root field , write public html/scheduler , now you can use this subdomain to access our routes.

1 Comment

Your answer could be improved with additional supporting information. Please edit to add further details, such as citations or documentation, so that others can confirm that your answer is correct. You can find more information on how to write good answers in the help center.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.