When you started reading this sentence you assumed lo acabar?a en ingl?s. However, I didn't finish in English. This begs the question, 'In which language did I finish?' Unless I tell you the language, you'd have to run around and compare the words against known words in order to learn that it was Spanish, but I'd bet you'd give up and move on first. Servers work much the same way; if you don't let it know the language it assumes you're speaking to someone else (the browser) and sends it along. Servers aren't even friendly enough to give it a whack and see how it comes out.
So, what's server-speak for "Here comes PHP!"? Well, it definitely looks foreign:
Sure. Whatever. It's no use telling the server you're speaking PHP because you only know how to say "I speak PHP". What's that going to do for you? Well, imagine you were visiting a scripts site and wondering how you could put today's date on your webpage when you come across the following little snippet:
To display the date on your webpage, find the area you want to put the date then insert the code below.
echo date('m/d/Y');
Now, you're equipped with 2 statements: "I'm going to be speaking PHP" and "Today's date is mm/dd/YYYY". You then edit the file you want to put the date in by inserting this code in the desired location: Put the file back on the server and you're date shows up exactly as the snippet said it would. Or does it?
If you got lucky, it showed up. If not, there's a little more to learn. There's actually more than one way to tell the server that PHP is coming and I've only covered one way - the other ways aren't necessary for you to know in order to use PHP on your site. Most servers require a bit more information first - they want the name of the file to say whether PHP is there or not. To tell the server that PHP is inside the file, you need to change the extension (the part after the dot) to php. Uh, sure, the extension. Does this guy speak English? YEP! lol. If that wasn't clear, let's illustrate by assuming your file was called index.html when you downloaded it to edit. Before you upload that file back to the server, you need to change "html" to "php", so that the file is called index.php. Without that change most servers won't even look for PHP. The nice thing is that even if a file ends in "php", the server still looks for those opening pieces saying "Here comes PHP!" before trying to read what follows in PHP and just sends everything back to the browser which is outside of PHP, so you don't hurt anything!
Tired of reading? Me too! And, we can only do a couple of things! Or can we? There are a lot of scripts out there which require you to copy and paste a little code here and there or to include a file. In those cases, you are now leaps and bounds ahead in getting them to work!
Jeremy Miller - Webmaster of script reference - The *NEW* PHP Reference & Tutorial Site For Non-Programmers
Batchtown Chicago prom limo .. Lockport Chicago limo O’HareFor years now I've been looking to start my own... Read More
Designing and creating your own website does not have to... Read More
Visitors to your site come looking for information or solutions... Read More
When visitors add your web site to their Favorites or... Read More
"I am a writer, not a business-person. I don't want... Read More
This simple question can take on several different forms, but... Read More
Have you ever wondered what challenges are faced by other... Read More
When a user signs up at your website, you may... Read More
What is web accessibility & why is it important?Web accessibility... Read More
Webmaster tools are vital to becoming both efficient and effective... Read More
What to do if you are an artist after you... Read More
So your prospect, Mary, is sitting at the computer reading... Read More
As a business you can't afford to ignore the Internet... Read More
If you are like me you have wanted to build... Read More
Do you make your website just to entertain yourself or... Read More
Your business website is a critical aspect of being able... Read More
The popular search engine Google indexes over 8 billion websites.... Read More
When I set up my website I felt paypal was... Read More
Website, website, website, everyone says you need one. But do... Read More
1) Data CaptureOne easy way to collect e-mail addresses and... Read More
Is your website Really useful?I had a 'rep' in yesterday... Read More
Most people know they need a website in order to... Read More
1. The first page appears quickly.It's a good way to... Read More
Like any area of business your website needs some effort... Read More
Mini Websites are the most powerful and cost effective solution... Read More
shuttle from Midway Munster are ..So you want to take a look at a real... Read More
Selecting the Perfect Domain NameThe first issue I have with... Read More
A simple website stats counter is not enough if you... Read More
While it may seem like a "quick and easy" task,... Read More
Webmaster tools are vital to becoming both efficient and effective... Read More
You have permission to publish this article electronically, in print,... Read More
In this day and age most businesses consider having their... Read More
One of my most salient memories from when I sold... Read More
What is web accessibility & why is it important?Web accessibility... Read More
The art of turning website visitors into paying customers depends... Read More
The cost of setting up a web site is dirt... Read More
The DDA (Disability Discrimination Act) states that service providers must... Read More
An automated accessibility tool is a piece of software which... Read More
While most marketers are beginning to understand the critical importance... Read More
With search engines putting a damper on direct reciprocal links,... Read More
SummaryHere's the scoop on what you must know when designing... Read More
There are lots of HTML editors on the market, however,... Read More
"What's in it for me?" you ask. "Why should I... Read More
An interesting eCommerce success factor that isn't precisely overlooked, but... Read More
My life's greatest passion is a safari hobby. And what... Read More
If you've been developing websites on Mars for the past... Read More
If you have some experience in web site design and... Read More
1. The first page appears quickly.It's a good way to... Read More
"Don't Sell the Steak, Sell the Sizzle."Have you heard of... Read More
An additional benefit of website accessibility is an improved performance... Read More
Web Development |