يمكنك استخدام ال Alias
التوجيه لتعيين جميع الطلبات التي تطابق النمط / custom-slug / * مع تطبيق Symfony. سيتم تقديم جميع عناوين URL الأخرى من وورد.
عينة vhost:
<VirtualHost *:80>
ServerName www.example.com
ServerAdmin [email protected]
DocumentRoot /your_web_root/www_example_com/wordpress/
# All URLs begining with /custom-slug will be fetched from the symfony app
Alias "/custom-slug" "/your_web_root/www_example_com/symfonyApp/web/"
<Directory /your_web_root/www_example_com/wordpress/>
Options Indexes FollowSymLinks MultiViews
AllowOverride All
Order allow,deny
allow from all
</Directory>
<Directory /your_web_root/www_example_com/symfonyApp/web/>
AllowOverride None
Order Allow,Deny
Allow from All
<IfModule mod_rewrite.c>
Options -MultiViews
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^(.*)$ app.php [QSA,L]
</IfModule>
</Directory>
</VirtualHost>