问题描述:

So I am trying to build myself a portfolio page and the way it has been setup at the moment is like so

var/www/html

index.html

css/

js/

images/

portfolio/

projecta/

laravel/

public/

from doing a bit of experimentation I managed to put his together

Options +FollowSymLinks -MultiViews

# Turn mod_rewrite on

RewriteBase /

RewriteEngine On # Turn on the rewriting engine

RewriteRule ^portfolio/projecta?$ portfolio/projecta/laravel/public [L,NC]

I have placed this in my document root

Technically the rewrite is working however the url in the address bar is my issue. It will be something like http://mysite.com.com/portfolio/projecta/laravel/public/ so my question is how would I go about shortening that final url ? is my folder structure complicating the matter ? Ideally I would like to achieve ``http://mysite.com.com/portfolio/projecta`

Also I read about virtualhosts might this be a better solution to my problem ? For my operating system I am using CentOS7

Greatly appreciate any help I can get

相关阅读:
Top