I need to upload my client’s website from “development” to “production”, and I need to keep the file structure/URL’s exactly as they are in Dev, but I also want to block out the public for the time being!!
(I have never been responsible for uploading a website or managing the web hosting, so pardon if this is a dumb question!!)
You may ask, “What exactly are you trying to do?”
Well, I want to upload my final code-base from Dev to Production and not mess with any of the directory-structure or URL’s because I need the ability to do final testing that what works beautifully in Dev will work beautifully in Production.
But I want end users off the Internet to stay the hell out until I deem things to be ready for “Go Live”!!
Make sense?
There is also the NOT so tiny issue that my client is 2 months behind delivering content that we really need to go live.
So I want to upload everything now, make sure that only I can surf the website on the Internet, and be sure that everything works, and then when my client gives me the missing content and the thumbs up, then ideally I could just make a minor tweak to the advice I hope to get here, and wha-la, my client’s website is “live” and already thoroughly tested for the Internet.
Am I making any sense?
I was thinking maybe something like a .htaccess file would allow me to “password-protect” www.MyClientsWebsite.com so only I can get in for now.
It seems like I would want to follow your logic, but do it in a .htacess file…
In Apache, is there a way to say, "If the IP requesting www.domain.com is < My_IP > then pass through to index.php, otherwise go to “under-construction.php”
Or if you access the internet in a public place, such as the Library/Internet Cafe, that you will share a public IP address with everyone in that building.
My MacBook has a static IP and my VPS has a dedicated IP.
Since my IP never changes on my MacBook, it would make sense to make it so if my .htaccess file sees that it is my IP address then it loads index.php, and for everyone else they either get an “Under Construction Page” or an error.
I think that is better done using Apache than PHP.
And I keep asking if that can be done using my .htaccess file - which I’m pretty sure it can.
I have no clue what Internet Cafes have to do with what I am asking for help with?!
Did you try the htaccess scripts in the perishable press link I supplied? At least one example should solve your problem.
off topic
How much extra did it cost for a dedicated IP address. This service is not normally supplied by any ISP. Normally ip addresses change frequently.
[quote=“John_Betong, post:10, topic:113379, full:true”]
Did you try the htaccess scripts in the perishable press link I supplied? At least one example should solve your problem.[/quote]
I missed that post before. Sorry.
I have a VPS which came with 2 dedicated IP’s at no additional cost.
It believe you request and log on to an internet service provider. The ISP allocates your personal, random IP Address which can be used to access the internet.
Your web hosting stores and hosts data that you upload to their servers and supplies static, public URLs for others to access your data.
I disagree. You can’t consider the VPS IP address when you are wanting to block out the public from viewing your website, you have to consider your ISP’s IP address that gets assigned to your internet connection. So with that said, John’s responses make a lot of sense.