Posts

Showing posts with the label MySQL

The Advantage of Using PHP and MySQL

One of the first choices to make when planning a new web site is if it should be static or dynamic. Static web sites show the same content to each visitor. Of course there can be more than one page on the site, but the content is fixed. On dynamic web sites the content can change. Visitors can interact with it. For example it might be possible for them to leave a comment for other visitors to see. In general a dynamic web site offers much more possibilities. But if you only want to give a short presentation of yourself or a company, the static solution might be the answer. However in most other cases the dynamic web page is the way to go. Static pages consists of HTML files generated locally on your PC and then uploaded to the web server. This can be done in dedicated programs like Adope Dreamweaver, Microsoft Expression Web or Coffeecup HTML Editor. If a change is to be made the files are changed on the PC and then uploaded to the server again. To create dynamic web pages you need to ...

Accessing Data in MySQL Database Using PHP

PHP and MySQL are two components that are almost always present in every web-based program. Data-driven Web applications can use the MySQL which has the main advantages of open source applications. In each database in MySQL there are a few tables. To learn how to access the data contained in the MySQL database, create a database instance with the name “online-store” . Databases can be created using the SQL command “create database online-store” or using PHPMyadmin . Later in the database table named instance make an “employee” table with the columns in it is the “id”, “first-name”, “last-name”, “address” . You can create table “employee” using SQL command as follows: CREATE TABLE IF NOT EXISTS `employee` ( `id` int(11) NOT NULL AUTO_INCREMENT, `first-name` varchar(50) NOT NULL, `last-name` varchar(50) NOT NULL, `address` varchar(200) NOT NULL, PRIMARY KEY (`id`) ) ENGINE=MyISAM DEFAULT CHAR...

Introduction to Database Driven Development, PHP and MySQL

PHP is one of the “scripting languages” of the Web. It is an interpreted language, interpreted by the official PHP interpreter, developed specifically for web programming. Being quite similar to ASP in many ways, chances are a change from ASP to PHP would not be all that difficult for a seasoned developer who was experienced in a C-style language. PHP, combined with Apache, or another web server handles all the “standard” web serving side of development; it watches for requests, it hands them off to the appropriate handlers, it sends the required headers, and it finalizes the job. On it’s own, PHP is a language capable of many simple things: date functions, file manipulation, mathematics, logic, all the traditional programming language stuff (including some very feature-filled mechanics for topics such as string manipulation and date manipulation) – but it doesn’t expand in to the power given by database driven web applications. Luckily, there a...

Linux, Apache, Mysql, PHP, and Perl - Light Your Lampp With Your Own Server

With all of the available web hosting plans, now is the time to start building sites whether your goal is fun, education, profit or all of the above. The days of plain static HTML sites is past. Today’s servers feature access to programming languages and database capability to provide dynamic web pages with just a little bit of coding. You may have run across a new word, lampp. Lampp is an acronym for Linux, Apache, Mysql, PHP, and Perl. Keep reading to see why these words are important to you. L – The Linux operating system, open source, fast and flexible, and constantly being approved A – The Apache web server, the framework for your website M – Mysql – the most popular open source database P – PHP – a flexible scripting language that makes it easy to create dynamic web pages P – Perl – the old standby language of the web, excellent for text manipulation and data analysis An excellent example of the use of lampp is the blogging so...