Database to HTML and Back again A programmers tale.

Slides:



Advertisements
Similar presentations
Using GET data within a IF Statement. If ($GETCom === ‘home’) { echo ’They Match’; } $GETCom = $_GET[‘com’]; If the data stored in the variable ($GETCom)
Advertisements

Web Database Programming Connecting Database to Web.
Introduction to GTECH 201 Session 13. What is R? Statistics package A GNU project based on the S language Statistical environment Graphics package Programming.
Copyright © 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Chapter 14 Web Database Programming Using PHP.
Multiple Tiers in Action
Database-driven Web Pages from Access Databases Stephen Rondeau TINST May 2009.
U:/msu/course/cse/103 Day 23, Slide 1 Review of Day 22 What query did you use to search for an actor by name? –Return matches.
2440: 141 Web Site Administration Web Server-Side Programming Professor: Enoch E. Damson.
XML & RDBMS By Molly Gumpert for: LIS 469: XML Fall 2014 Professor Gerry Benoit.
RMS Importer/Exporter Create configuration for the MedAustron Control System PP a-ABR_RMSImporterExporter.pptm abrett/mmarchha RMS Importer/Exporter.
Programming with php By: Seth Larson. A little bit about PHP  PHP stands for PHP:  Hypertext Preprocessor  PHP is a widely-used general-purpose server-side.
Introduction to PHP and Server Side Technology. Slide 2 PHP History Created in 1995 PHP 5.0 is the current version It’s been around since 2004.
U:/msu/course/cse/103 Day 25, Slide 1 Back-up PHP Files If you have not yet passed the 3.0 BT, make back-up copies of ALL.
INFM 603: Information Technology and Organizational Context Jimmy Lin The iSchool University of Maryland Thursday, October 18, 2012 Session 7: PHP.
Internet and Web Application Development Revision.
1 PHP and MySQL. 2 Topics  Querying Data with PHP  User-Driven Querying  Writing Data with PHP and MySQL PHP and MySQL.
PHP meets MySQL.
GUI To Create a DB Table CS346 Fall Methods to create a table At your local server and/or remote server – Use MySQL Console and create it interactively.
Creating Dynamic Web Pages Using PHP and MySQL CS 320.
Polling System Part 1 Creating PHP & MySQL Files CIS 254.
NMD202 Web Scripting Week3. What we will cover today Includes Exercises PHP Forms Exercises Server side validation Exercises.
PHP with MySQL 1.
CS 174: Web Programming September 2 Class Meeting Department of Computer Science San Jose State University Fall 2015 Instructor: Ron Mak
PHP Form Introduction Getting User Information Text Input.
13. PHP: Insert, View Data. M. Udin Harun Al Rasyid, S.Kom, Ph.D Desain dan Pemrograman.
If statements and validation. If statement In programming the if statement allows one to test certain conditions and respond differently depending on.
PL/SQLPL/SQL Oracle10g Developer: PL/SQL Programming Chapter 3 Handling Data in PL/SQL Blocks.
Lecture # 32.1 Lab 10: Server 1. Lab 10 Server 1 Add and delete names.
Enterprise PHP – Reading Data from a DB Reading Data from a relational database in PHP Nic Shulver, FCES, Staffordshire University Using the SQLi interface.
THE WEBMASTERS: SENG + WAVERING.  On account of construction, we will be having class in room 1248 next week.
PHP getting data from a MySQL database. Replacing XML as data source with MySQL Previously we obtained the data about the training session from an XML.
IT ELECTIVE 2.  Web server Can refer to either the hardware (the computer) or the software (the computer application) that helps to deliver content that.
Databases Letts Chapter 11. A database program can be used to:  sort a file into a different order;  search through the records for a matching string.
Oracle10g Developer: PL/SQL Programming1 Objectives SQL queries within PL/SQL Host or bind variables The %TYPE attribute Include queries and control structures.
PHP and SQL Server: Connection IST2101. Typical web application interaction (php, jsp…) database drivers 2IST210.
U:/msu/course/cse/103 Day 21, Slide 1 CSE 103 Makeups –If you didn’t take one over the weekend, take one TUESDAY or WEDNESDAY!
E-COMMERCE JOBS This project (Project number: HU/01/B/F/PP ) is carried out with the financial support of the Commssion of the European Communities.
PHP Programming. Topics Database Handling (MySQL, MSSQL, ODBC)
HTML Links HTML uses a hyperlink to another document on the Web.
Instructor: Pavlos Pavlikas1 How Data is Stored Chapter 8.
Ajax Dice Game Part 1. We saw that we could use the jQuery load() function, to dynamically load a piece of an html document into another html document.
Introduction to JavaScript MIS 3502, Spring 2016 Jeremy Shafer Department of MIS Fox School of Business Temple University 2/2/2016.
Web based Documentation Distribution Tools: MSAccess database (DSN) DreamWeaver Ultradev Microsoft Image Composer Clicking on the document will open an.
PHP and SQL Server: Connection IST 210: Organization of Data IST2101.
INTRODUCTION ABOUT DIV Most websites have put their content in multiple columns. Multiple columns are created by using or elements. The div element is.
PHP AND SQL SERVER: CONNECTION IST 210: Organization of Data IST210 1.
PDO Database Connections MIS 3501, Fall 2016 Jeremy Shafer Department of MIS Fox School of Business Temple University 3/8/2016.
Web Database Programming Using PHP
DB Programming – Basic analysis
PDO Database Connections
Web Database Programming Using PHP
Relational Databases.
* Lecture # 7 Instructor: Rida Noor Department of Computer Science
PDO Database Connections
HTML Forms and User Input
MVC Framework, in general.
ISC440: Web Programming 2 Server-side Scripting PHP 3
Functions BIS1523 – Lecture 17.
PDO Database Connections
In Class Program: Today in History
PDO Database Connections
In Class Programming BIS1523 – Lecture 11.
Data Management Innovations 2017 High level overview of DB
Database Assignment Write down your answers in word document with file name highlighting your name, student number, and class. E.g “95002”+”_”+ “03 class”+”_”+”name”,
Updating Databases With Open SQL
Database SQL.
Updating Databases With Open SQL
Presentation transcript:

Database to HTML and Back again A programmers tale

DB to HTML To get information from a Database table into a HTML file we need to use SQL and PHP 1. get the data from the table 2. put the data into PHP variables 3. put the variables into the values attributes or HTML The document is then printed

DB to HTML 1. get the data from the table USE SQL SELECT statement The SQL fields and table names must match the table

DB to HTML 2. put the data into PHP variables The names of the PHP variables reflect easily recognizable names based on the table and fields. The data from the field names goes into the variable names.

DB to HTML 3. put the variables into the values attributes or HTML If you are using a form the variables should go into value attributes in many cases.

HTML to DB To get HTML form information into a Database we just reverse the process. 1. Take the HTML form elements and place them into PHP variables 2. Take the variables and put them into a SQL statement.

HTML to DB 1. Take the HTML form elements and place them into PHP variables This is first accomplished by naming the name attribute values with recognizable names.

HTML to DB 2. Take the variables and put them into a SQL statement. The names of the variables will be the values of the SQL statement. The names to the left of the = signs are the names of the fields