[wp-hackers] How to make root relative urls work in, , subdomain

Dagan Henderson Dagan.Henderson at epyllion.com
Thu Nov 3 19:33:32 UTC 2011


Marcus,

Don't disagree with much you said. I guess it comes down to your own skill set, experience and comfort level.


-----Original Message-----
From: wp-hackers-bounces at lists.automattic.com [mailto:wp-hackers-bounces at lists.automattic.com] On Behalf Of Marcus Pope
Sent: Thursday, November 03, 2011 11:57 AM
To: wp-hackers at lists.automattic.com
Cc: wp-hackers at lists.automattic.com
Subject: Re: [wp-hackers] How to make root relative urls work in, , subdomain

Given that the first option is only possible before the site has been pushed live and the original question was related to hosting old clients indefinitely let's just agree that it's a one time use option. Flipping public dns entries back and forth is a 48hour process that isn't very responsive. But kuddos for thinking outside the box :)

Your second option would work as well, but it requires two not so simple steps. First it requires you to pinhole your dmz built into your network router so the reverse proxy can accept public traffic. This is something that is blocked on many home-use routers that are provided by internet providers (time warner cable will not support your service if you do this with your own wifi router for example.). And secondly it will require you to setup a reverse proxy, something that is expensive and risky without very strong network security knowledge on the windows os, and difficult to setup for many on unix oses. 

Although it's an option it's a pretty insecure option to open up your dev environment to public traffic unless you adhere to standards and guidelines used on production servers, which most people don't do. 

Even still, those ideas are simple in premise but are often difficult for those without network administration experience and the steps to follow will not be a 5 minute install like the wordpress setup process. 

But sure they do work. 

- Marcus

On Nov 3, 2011, at 11:00 AM, "Dagan Henderson" <Dagan.Henderson at epyllion.com> wrote:

> I don't think testing on mobile devices is as complicated as you make it sound, Marcus. In fact, so long as you have WiFi connectivity to the local network, I can think of a variety of ways, sans jailbreaking (and yes, I know that was originally my suggestion ;-) ).
> 
> Let's say the site will eventually reside at http://mynewsite.com/, but for right now we don't need to have anything there. In that case, store the private network address in the public DNS. If you're within the local network, it works. If you're not, you get a destination-unreachable error.
> 
> If you want a more graceful solution, you could setup the dev.myawesomecompany.com in the same way and configure a reverse proxy internally to translate dev.myawesomecompany.com/myclient to myclient.dev.
> 
> 
> -----Original Message-----
> From: wp-hackers-bounces at lists.automattic.com 
> [mailto:wp-hackers-bounces at lists.automattic.com] On Behalf Of Marcus 
> Pope
> Sent: Thursday, November 03, 2011 8:37 AM
> To: wp-hackers at lists.automattic.com
> Subject: Re: [wp-hackers] How to make root relative urls work in, , 
> subdomain
> 
> Marty - it is a very good solution for a good percentage of people (I 
> hate to say majority because mobile devices are becoming so popular,) 
> but if you have to browse or manage your dev site via your iPhone or 
> Android device you'll find that there are no options for editing your 
> hosts files on those platforms (well, you can on android if you 
> jailbreak/root the device.)
> 
> In those cases you have to rely on a more robust approach using a higher-end wifi router that allows you do make network wide mappings, or customize it with a local network dns address (and then you have to build and manage your own dns server.)  Many home and small business wifi routers do not give you these options, and in this case you are left with pushing to production before you can test any work on a mobile platform.
> 
> But it's a good, quick option indeed when you can get away with it.
> 
> -----Original Message-----
> From: wp-hackers-bounces at lists.automattic.com 
> [mailto:wp-hackers-bounces at lists.automattic.com] On Behalf Of Dagan 
> Henderson
> Sent: Thursday, November 03, 2011 12:08 AM
> To: wp-hackers at lists.automattic.com
> Subject: Re: [wp-hackers] How to make root relative urls work in, , 
> subdomain
> 
> I think that's a pretty typical process, Marty. Nothing wrong with it at all (because it works).
> 
> 
> -----Original Message-----
> From: wp-hackers-bounces at lists.automattic.com 
> [mailto:wp-hackers-bounces at lists.automattic.com] On Behalf Of Marty 
> Fried
> Sent: Wednesday, November 02, 2011 10:04 PM
> To: wp-hackers at lists.automattic.com
> Subject: Re: [wp-hackers] How to make root relative urls work in, , 
> subdomain
> 
> I might be completely off base, and this may not be the best way to do this, but the method I've been using is to make an entry in my hosts file (on my development system) for a URL ending in ".dev" instead of ".com" for sites I'm working on - ie, http://example.dev if the real site is example.com.  Then, I create a virtual domain in Apache to map example.dev to the directory I'm using, and restart Apache.  It may not be the least amount of maintenance, but it takes me almost no time to set it up using cut and paste from a previous entry, and it give me a good simulation of the final site, with the only difference being I use ".dev" instead of ".com".  The standard Wordpress .htaccess file works with this setup.
> 
> If this is a dumb way to do it, I'm open to change, and I apologize.  But if it's not obvious, and is something that anyone is interested in, I could post details of the setup.  I use Ubuntu Linux for both my server and my dev system, fwiw.
> 
> -Marty Fried
> 
> 
> On Mon, Oct 31, 2011 at 8:38 PM, Ryann Micua <ryannmicua at gmail.com> wrote:
> 
>> Hi Marcus,
>> 
>> The rewrite doesn't seem to be working on my local server. But, if 
>> you say that it's the right then I think it's something wrong with my 
>> lamp setup I'll look into it. we came up with almost the same rules 
>> anyway
>> =) save for taking out the domain name and adding flags.
>> 
>> 
> _______________________________________________
> wp-hackers mailing list
> wp-hackers at lists.automattic.com
> http://lists.automattic.com/mailman/listinfo/wp-hackers
> _______________________________________________
> wp-hackers mailing list
> wp-hackers at lists.automattic.com
> http://lists.automattic.com/mailman/listinfo/wp-hackers
> _______________________________________________
> wp-hackers mailing list
> wp-hackers at lists.automattic.com
> http://lists.automattic.com/mailman/listinfo/wp-hackers
> _______________________________________________
> wp-hackers mailing list
> wp-hackers at lists.automattic.com
> http://lists.automattic.com/mailman/listinfo/wp-hackers
_______________________________________________
wp-hackers mailing list
wp-hackers at lists.automattic.com
http://lists.automattic.com/mailman/listinfo/wp-hackers


More information about the wp-hackers mailing list