Welcome Guest. Please Login or Register  


You are here: Index > AMPPS > General Support > Topic : Absolute paths with multiple domains



Threaded Mode | Print  

 Absolute paths with multiple domains (6 Replies, Read 3535 times)
matsaukeo
Group: Member
Post Group: Newbie
Posts: 23
Status:
Hi there,

I've created multiple domains (e.g. localhost/mysite )

but I prefer to have all my paths relative to the root (so for example the path to my css file is always /includes/css/style.css

When using multiple domains, my path is always broken. When I used xammp, I edited the config file to set up virtual hosts but from reading around it sounds like I shouldn't edit these files and that there may be a way in the gui to do it

Is there any way to do this? if not, how can I have multiple sites but with absolute paths for all the files?

much appreciated (again!!)

IP: --   

Absolute paths with multiple domains
tidus
Group: Member
Post Group: Super Member
Posts: 1121
Status:
Hi,

Yes. Ampps does create a domain from enduser panel. Don't forget to check the checkbox in Advance seettings to add an entry to host file if you have not configured the DNS
(ignore the red message if it arises, check the checkbox anyway, as we can add the entry manually)

Although if you know how to create virtual hosts, you can create a new file in the same location lets say my-vhosts.conf and include it in the Apache Configuration just like httpd-vhosts.conf


-----------------------
Follow AMPPS on,
Twitter : https://twitter.com/AMPPS_Stack
Facebook :  http://www.facebook.com/softaculousampps
Google+ : https://plus.google.com/+AmppsStack
IP: --   

Absolute paths with multiple domains
matsaukeo
Group: Member
Post Group: Newbie
Posts: 23
Status:
Thanks for the reply but to be honest I think I may be in way over my head!

If I added a host file, can I then use absolute paths? If so, are there some instructions anywhere?...

...Or are you saying that I need to set up a host file for virtual hosts anyway?

In xammps there was a specific file somewhere that I added new entries for and then I had to edit a windows system file somewhere to add the path's to. Is there any tutorial or documentation that I can follow?

Again thanks for your help!

IP: --   

Absolute paths with multiple domains
tidus
Group: Member
Post Group: Super Member
Posts: 1121
Status:
Hi,

What you used to do manually in XAMPP is done by Ampps in the enduser panel. You just need to provide the path and domain name. Yes, hosts file is present in Widows directory(C:\Windows\System32\drivers\etc\hosts). AMPPS even changes that(if he gets the permission)

Check the attached screenshots.

You can check the host file contents in manage domain page if the entry was added or not, add it manually if it wasn't.


-----------------------
Follow AMPPS on,
Twitter : https://twitter.com/AMPPS_Stack
Facebook :  http://www.facebook.com/softaculousampps
Google+ : https://plus.google.com/+AmppsStack
IP: --   

Absolute paths with multiple domains
matsaukeo
Group: Member
Post Group: Newbie
Posts: 23
Status:
thanks - will give that a go. Does it make any difference that all my files are hosted on dropbox? I created a symlink using terminal like this

Code
mv /Applications/AMPPS/www /dropbox/www
ln -s /dropbox/www /Applications/AMPPS/www


Thanks...
IP: --   

Absolute paths with multiple domains
matsaukeo
Group: Member
Post Group: Newbie
Posts: 23
Status:
thanks  - all sorted now. would you mind confirming something for me? When I delete and add domains using the end panel, does it create any files? At this point it's just creating links really isn't it?

Thanks again - this is just what I need at the moment.
IP: --   

Absolute paths with multiple domains
tidus
Group: Member
Post Group: Super Member
Posts: 1121
Status:
Quote From : matsaukeo April 18, 2014, 2:06 pm
would you mind confirming something for me? When I delete and add domains using the end panel, does it create any files? At this point it's just creating links really isn't it?


Hi,

Adding/Deleting Domains from Enduser Panel modifies the vhosts configuration file of Apache.


-----------------------
Follow AMPPS on,
Twitter : https://twitter.com/AMPPS_Stack
Facebook :  http://www.facebook.com/softaculousampps
Google+ : https://plus.google.com/+AmppsStack
IP: --   

« Previous    Next »

Threaded Mode | Print  



Jump To :


Users viewing this topic
1 guests, 0 users.


All times are GMT. The time now is March 28, 2024, 1:09 pm.

  Powered By AEF 1.0.8 © 2007-2008 Electron Inc.Queries: 11  |  Page Created In:0.325