|Language:||English, Spanish, German|
|Genre:||Children & Youth|
|ePub File Size:||25.89 MB|
|PDF File Size:||15.55 MB|
|Distribution:||Free* [*Sign up for free]|
Editorial Reviews. From the Back Cover. Learn to use the tools that bring Web sites to life —it's PHP and MySQL For Dummies - Kindle edition by Janet Valade. Download it once and read it on your Kindle device, PC, phones or tablets. Read "PHP and MySQL For Dummies" by Janet Valade available from Rakuten Kobo. Sign up today and get $5 off your first download. Here's what Web. PHP & MySQL® For Dummies®, 2nd Edition. Published by Janet Valade is the author of PHP 5 For Dummies as well as the first edition.
An effective e-commerce site gathers information about users and provides information they need to get the desired result. PHP scripting language with a MySQL back-end database offers an effective way to design sites that meet these requirements. Enter your mobile number or email address below and we'll send you a link to download the free Kindle App. Then you can start reading Kindle books on your smartphone, tablet, or computer - no Kindle device required.
To get the free app, enter your mobile phone number. Static Web sites don't cut it anymore. This book shows you how to build two common applications: You'll learn a basic design you can expand however you choose! New to all this? Visit the companion Web site at www. She has designed and developed data archives, supervised computer resource operations, and conducted seminars and workshops.
Would you like to tell us about a lower price? Here's what Web designers need to know to create dynamic, database-driven Web sites To be on the cutting edge, Web sites need to serve up HTML, CSS, and products specific to the needs of different customers using different browsers. Read more Read less.
Discover Prime Book Box for Kids. Learn more. Kindle Cloud Reader Read instantly in your browser. Customers who bought this item also bought. Page 1 of 1 Start over Page 1 of 1. Ed Tittel. An Ultimate Beginner's Guide! Ray Yao. Creating a Website: The Missing Manual. Matthew MacDonald. PHP for the Web: Visual QuickStart Guide. Larry Ullman. The new approach that uses technology to cut your effort in half. Mark Myers. How to keep up with PHP and MySQL updates What's different in the newest versions Pros and cons of Web hosting companies How to back up and restore data in your database Error messages and what they mean Why you must plan your database application Advice on what offers value to your users Ten "gotchas" that will mess up your code.
Product details File Size: For Dummies; 4 edition December 10, Publication Date: December 10, Sold by: English ASIN: Enabled X-Ray: Not Enabled. Share your thoughts with other customers. Write a customer review. Read reviews that mention php and mysql website easy to read dummies series mysql for dummies good solid dummies books need to know book did an excellent bought this book recommend this book reference book found the book good book mysql and php examples database chapters follow functions.
Showing of 52 reviews. Top Reviews Most recent Top Reviews. There was a problem filtering reviews right now. Please try again later. Paperback Verified download.
This book is good, a little funny as all For Dummies books should be , an easy read, and full of good information. I guess, get a book dedicated to just PHP if you want to learn what the language can really do.
The biggest problem I have with this book is the countless typos, particularly in the code which is the worst place for typos. Pretty disappointing for a 4th edition.
Also, the author's use of HTML doesn't really jive with me some minor coding problems but it's not a huge deal either. Or, there are some places where quote marks in code are bottom-quote-marks looks like double-commas instead of normal quote marks as they should look.
These are mainly annoyances and not serious problems if you know to keep your eyes open. I bought this book while writing a web app. Although I had some previous experience, I didn't have much in PhP and the book did an excellent job of describing the basics.
Similarly, with MySqL I had little experience and it really helped. The book has you work through examples, and then has the programs written out later on so you can go look at what they did.
It describes many of the callable functions available in the language, but it tells you to go to the PHO web site for a complete list of all the functions and features. You can choose the level of services you want for the fee that you want to pay.
You can even search the e-mail list archives, which con- tain a large archive of MySQL questions and answers. Its speed and small size make it ideal for a Web site. The main goal of the folks who developed MySQL was speed.
Thus, the software was designed from the beginning with speed in mind. Check out Chapter 4 for the lowdown on the SQL language. A large base of users provides free support through mailing lists. The MySQL developers also partici- pate in the e-mail lists. Passwords are encrypted. MySQL handles databases up to 50 million rows or more. The default file size limit for a table is 4GB, but you can increase this if your operating system can handle it to a theoretical limit of 8 million terabytes TB.
The heart of the system is the MySQL server. The MySQL server is the manager of the database system. It handles all your database instructions. In the same manner, to add data to that database, you send a message to the MySQL server, giving it the data and telling it where you want the data to be added.
Before you can pass instructions to the MySQL server, it must be running and waiting for requests. The MySQL server is usually set up so that it starts when the computer starts and continues running all the time.
This is the usual setup for a Web site. If you need to, you can start it manually whenever you want to access a database.
The MySQL server must be able to understand the instructions that you send it. The MySQL server sends a return message, stating its status and what it did or reporting an error if it was unable to understand or follow the instructions. Software designed specifically to interact with MySQL database is also dis- cussed in this book. PhpMyAdmin is also available on almost all Web hosts. Rich in features that make Web design and programming easier, PHP is in use on more than 20 million domains according to the Netcraft survey at www.
Its popular- ity continues to grow, so it must be fulfilling its function pretty well. HyperText Preprocessor. When it developed into a full-blown language, the name was changed to be more in line with its expanded functionality. PHP is particularly strong in its ability to interact with databases. PHP handles connecting to the database and communicating with it. It connects to the database, passes your instructions to the database, and returns the database response to you.
Technical support is available for PHP. You can join one of several e-mail discus- sion lists offered on the PHP Web site www.
In addition, a Web interface to the discussion lists is available at http: Because it is embedded in HTML code, the response time is short. PHP is proof that free lunches do exist and that you can get more than you paid for. PHP contains many special features and functions needed to create dynamic Web pages. If you are going to publish your Web site on a Web host, you will find PHP installed on almost all Web hosts for free. A large base of users provides free support through e-mail discussion lists.
The user does not see the PHP code. PHP includes functionality designed to interact with specific databases. It relieves you of the need to know the technical details required to communicate with a database. The open source license allows programmers to modify the PHP software, adding or modifying features as needed to fit their own specific environments. The PHP software works with the Web server. The Web server is the software that delivers Web pages to the world. The Web server responds by sending the requested file.
You also request the Web server to send you a file when you click a link in a Web page. In addition, the Web server processes a file when you click a Web page button that submits a form. Often the extension is. When PHP language statements are processed, only the output is sent by the Web server to the Web browser.
The PHP language statements are not included in the output sent to the browser, so the PHP code is secure and transparent to the user. For instance, in this simple PHP statement: PHP and the Web server must work closely together. PHP is not integrated with all Web servers but does work with many of the popular Web servers. If you can select or influence the selection of the Web server used in your organization, select Apache. By itself, Apache is a good choice. It currently powers more than 60 percent of all Web sites, according to the Web server survey at www.
Both were designed specifically for use on Web sites. Both have a set of features focused on building dynamic Web sites. Both were designed to get a Web site up quickly.
Both were designed with speed as a major goal. Together they provide one of the fastest ways to deliver dynamic Web pages to users. You use the PHP language to write the programs that perform the application tasks. PHP can be used for simple tasks such as displaying a Web page or for complicated tasks such as accepting and veri- fying data that a user typed into an HTML form.
One of the tasks that your application must do is move data into and out of the database — and PHP has built-in features to use when writing programs that move data into and out of a MySQL database. When the task to be performed by the application requires storing or retrieving data, you use specific PHP statements designed to interact with a MySQL database. You use one PHP statement to connect to the correct database, telling PHP where the database is located, its name, and the password needed to connect to it.
MySQL returns a status message that shows whether it successfully performed the task. If a problem came up, it returns an error message. You then use one or more PHP statements to complete the application task.
For instance, you can use PHP statements to display data that you retrieved. Or you might use PHP statements to display a status message in the browser, informing the user that the data was saved. As a scripting language, PHP can perform complicated manipulations of data, on either data that you need to modify before saving it in the database or data that you retrieved from the database and need to modify before displaying or using it for another task.
Open source software changes frequently, rather than once every year or two like commercial software does. It also changes quickly in response to problems. When a serious problem is found — such as a security hole — a new version that fixes the problem can be released in days.
Join the mailing lists, which often are high in traffic. When you first get acquainted with PHP and MySQL, the large number of mail messages on the discussion lists brings valuable information into your e-mail inbox; you can pick up a lot by reading those messages.
And soon, you might be able to help others based on your own experience. At the very least, sub- scribe to the announcement mailing list, which delivers e-mail only occasion- ally. Any important problems or new versions are announced here. The e-mail that you receive from the announcement list contains information you need to know.
When PHP changes from version 5 to version 6, the following important changes will occur: These arrays were commonly used in PHP 4. I explain these changes throughout the book where they apply to the techniques and procedures. MySQL 5. The examples and scripts in this book run equally well under either ver- sion. Some of the more advanced features of 5.
However, at the time of this writing, version 6. The examples and scripts in this book can execute properly on these sites as well. This chapter describes how to set up your Web site environment with all the tools you need to build your Web database application.
Anatomy of a Web Site Because you most likely have created simple Web sites before, you know what a Web site is. The computer space where the files are stored is the physical location of your Web site. Web users often talk about Web site visitors, but the term visitors is techni- cally misleading. When a person types the address called a URL or Uniform Resource Locator of a Web site into a Web browser, the browser sends a request over the Internet, asking to view the Web page at that address.
Software at the Web site, called a Web server, receives the request and responds by sending the requested Web page. The browser receives the Web page file and displays the Web page in the browser window. To make your Web site available to the public, you place the text files con- taining HTML code on the Web site where users can access them. A Web database application is similar. Building a Web Site As discussed in the previous section, a Web site is a collection of text files placed on a computer in a location where users can access them.
Placing the Web site files where they can be accessed by the public is called publishing the Web site.
However, this is the final step of building the Web site, not the first step. You need to do this work in private.
The site where your published Web site is located. The location where the public views your Web site. The location where you develop your Web pages. When your pages are complete, you then move them to your Web site.
Your Web site publishes your Web pages to the world. Your development site needs to be hidden from the world. Never pub- lish your Web pages until they are complete and perfect. The information you need to make these decisions is provided in the next few sections of this chapter. The com- puter should also provide the tools you need, as discussed earlier: The Web hosting company installs and maintains the Web site software and provides space on its computer where you can install the files for the Web site.
Your job, for the purposes of this book, is to program the Web site, either as an employee of the company or as a contractor.
You plan to install and maintain the Web site software yourself. The third option requires that you install, set up, administer, and maintain the Web site software yourself.
This option requires much more technical knowledge of computer software than the first two options, where others provide the software for you. However, the advantage of this option is that you have more control.
You can set up the Web site software with the set- tings that you prefer. In the next three sections, I describe the publishing options in more detail and provide the information you need to decide where to publish your Web site.
You just create the files for your Web pages and move them to a location specified by the Web hosting company. Most small-to-medium-sized Web sites are hosted by Web hosting companies. About a gazillion companies offer Web hosting services. Most charge a monthly fee often quite small , and some are even free. Most, but not all, of the free ones require you to display advertising.
Usually, the monthly fee varies depending on the resources provided for your Web site. When looking for a place to host your Web site, make sure that the Web host- ing company offers the following: Not all companies provide these tools. As of this writing, PHP 6 is close to being released. Many develop- ers have not yet converted their code to run under PHP 5. However, the demise of PHP 4 is looming. Support for PHP 4 stopped at the end of There will be no more releases of PHP 4, and critical security fixes ended in late There is no reason for anyone developing new code to use PHP 4.
Look for a Web hosting company that provides PHP 5. The techniques in this book work with older versions of MySQL. However, even older versions provide a feature set that allows quite sophisticated dynamic Web sites.
Web hosts vary in the amount of access to PHP set- tings that you, as their customer, are given. More access to PHP settings gives you more control over your Web site functionality.
A text file named php. Your Web host will not give you access to the general php. Another way to change PHP settings is using an. Many Web hosts allow you to store an.
When you select a Web host, be sure the hosting company allows you to use either a local php. To create and use MySQL databases, you need specific software.
Other software also works, but this book assumes you have access to phpMyAdmin. Web pages that download slowly are a problem because users will get impatient and go elsewhere. Slow pages could be a result of a Web hosting company that started its business on a shoestring and has a shortage of good equipment — or the Web hosting company might be so successful that its equipment is overwhelmed by new customers. Either way, Web hosting companies that deliver Web pages too slowly are unacceptable.
Some Web hosting companies have no one avail- able to answer questions or troubleshoot problems. Technical support is often provided only through e-mail, which can be very good if the response time is short.
Each Web site has a domain name that Web brows- ers use to find the site on the Web. Each domain name is registered for a small yearly fee so that only one Web site can use it. Some Web hosting companies allow you to use a domain name that you have registered independently of the Web hosting company, some assist you in register- ing and using a new domain name, and some require that you use their domain name.
For instance, suppose that your name is Lola Designer and you want your Web site to be named LolaDesigner. Some Web host- ing companies allow your Web site to be LolaDesigner.
In general, your Web site looks more professional if you use your own domain name. Backups are copies of your Web page files and your database that are stored in case your files or database are lost or damaged. You want to be sure that the company makes regular, frequent backup copies of your application. You also want to know how long it would take for backups to be put in place to restore your Web site to working order after a problem. Select features based on the purpose of your Web site.
Usually a hosting company bundles features together into plans — more fea- tures equal a higher cost. Media files, such as graphics or music files, can be quite large. Some hosting companies charge you for sending Web pages to users. If you expect to have a lot of traffic on your Web site, this cost should be a consideration. Most hosting companies provide you with one or more e-mail addresses for your Web site.
For instance, if your Web site is LolaDesigner. Hosting companies offer access to a variety of software for Web development.
Some hosting companies might offer other databases, and some might offer other development tools such as FrontPage extensions, shopping cart software, and credit card validation. Often you can get statistics regarding your Web traffic, such as the number of users, time of access, access by Web page, and so on.
The best way to research Web hosting companies is to ask for recommendations from people who have experience with those companies. People who have used a hosting company can warn you if the service is slow or the computers are down often. Domain names Every Web site needs a unique address on the Web.
The unique address used by com- puters to locate a Web site is the IP address, which is a series of four numbers between 0 and , separated by dots — for example, A domain can be one computer or many connected computers. When a domain refers to several computers, each computer in the domain can have its own name. A name that includes an individual computer name, such as thor. Each domain name must be unique in order to serve as an address.
Consequently, a system of registering domain names ensures that no two locations use the same domain name. You can register a domain name on the Web. The name is then yours to use, and no one else can use it. You should never pay more, but bargains are often available. Many Web sites provide the ability to register a domain name, including many Web host- ing companies.
A search at Google www. Shop around to be sure that you find the lowest price. Also, many Web sites allow you to enter a domain name and see whom it is registered to. These Web sites do a domain name database search using a tool called whois. A search at Google for domain name whois results in more than 17 million hits. A couple of places where you can do a whois search are Allwhois. The company is responsible for the operation of the Web site, so that burden is off your shoulders.
In most cases, the Web site already exists, and your job is to add to, modify, or redesign the existing Web site. In a few cases, the company might be installing its first Web site, and your job is to design the Web site. The name of this department can vary in different companies, but its function is the same: You will interact with the IT folks frequently as needs arise.
For example, you might need options changed, you might need information to help you inter- pret an error message, or you might need to report a problem with the Web site software. So a good relationship with the IT folks will make your life much easier. Bring them tasty cookies and doughnuts often. You have to make several decisions regarding hardware and software. Taking this route, rather than using a Web site provided by others, requires more work and more knowledge.
The advantage is that you have total control over the Web development environment. Here are the general steps that lead to your dynamic Web site: Set up the computer. If your Web site receives much traffic, it may not have enough resources and may bog down.
Install the Web server. After you set up the computer, you need to install Web server software. In most cases, you want to install Apache.
Apache is automatically installed with the operating system on Macs and Linux. Currently, Apache powers about 60 percent of Web sites. You can find information about installing Apache at http: Install MySQL. Many Mac and Linux computers arrive with MySQL already installed, although they still may need to be upgraded to the most recent version.
You can download and install MySQL from www. Install PHP. You can find software to download and install, as well as thorough documenta- tion, at www.
You just clipped your first slide!