Paths relative to root

15 views
Skip to first unread message

Karen

unread,
Feb 27, 2012, 5:43:43 AM2/27/12
to Flux Users
This isn't really related to Flux but as I've learned about it here, I
thought this group would be a good place to get some advice. I've
googled but still not getting anywhere.

Basically I really like using paths relative to root option together
with MAMP locally. However, when I want to upload to my development
server, I put all the files in a subdirectory. But it's not working
properly there as I need to 'temporarily' change the root directory.
What are the different ways to achieve this? I've spent the last few
hours looking at achieving virtual domains with htaccess but I don't
think I'm going in the right direction.

Thanks for any input!

David Miers

unread,
Feb 27, 2012, 7:15:28 AM2/27/12
to flux...@googlegroups.com
I'm not quite sure I understand what you mean here. However one tip I might offer about mamp is through preferences/apache/ you can change it to any folder on your computer. Thus any folder with site files in it can become the root of the server. This way there is no 'moving' the files to the development server as they are already there.

Don't quote me on this but I believe mamp pro allows you to set multiple directories at once. However it only takes a second to do the switch.

Karen Cheah

unread,
Feb 27, 2012, 7:23:03 AM2/27/12
to flux...@googlegroups.com
Thanks for your response, David. Sorry I wasn't very clear.

With MAMP on local, that's what I've been doing, changing the path in the preferences for each different site.

Our development server is hosted and I normally place sites I've worked on, in subdirectories there for preview/feedback. Previously, I didn't use path relative to root so it didn't matter where I put the files. But now, if I didn't place them in the web root, the links are broken.

Is there a way to specify the root for each of these subdirectories? That's why I was wondering if subdomain with htaccess will work.

Hope I've explained my situation better.

> --
> You received this message because you are subscribed to the Google Groups "Flux Users" group.
> To post to this group, send email to flux...@googlegroups.com.
> To unsubscribe from this group, send email to fluxusers+...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/fluxusers?hl=en.
>

Dave

unread,
Feb 27, 2012, 8:22:54 AM2/27/12
to flux...@googlegroups.com
Ok, now I get your problem. If you had access to the hosts cpanel it would be easy,like zip bam boom but guessing you don't have this access. I googled it a bit and its over my head I can tell you that. It may be possible but my impression is it's not advisable. I would contact the server admin, but wouldn't get my hopes to high especially if this is a school or something.

When I was in college many students found themselves in this situation and decided to get their own hosting. I already had my hosting at the time, yeah I was one of those 'old' people in college. It doesn't cost that much and then you have complete control. My current recommendation for hosting would be hostgator especially if you don't want contracts and would like to just pay monthly. There are cheaper solutions, but somewhat depending on how server savvy you are there are many trails of tears.

mirmir

unread,
Feb 27, 2012, 9:54:56 AM2/27/12
to Flux Users
Could the base tag be of any use to you?

http://www.w3schools.com/tags/tag_base.asp

Karen Cheah

unread,
Feb 27, 2012, 5:28:37 PM2/27/12
to flux...@googlegroups.com
Ok, thanks. I'm contacting the server admin to see what options I have. It's not on cpanel so not that straightforward but it's not a school either.

mirmir, I thought about the base tag too but that will mean that I have to put that on just for the preview and then later take it out again for the live site.

Thanks for the advice.

Reply all
Reply to author
Forward
0 new messages