Class Note 13 for Web Scripting 

Learning Objectives:

You will be able to connect to a database using PHP

 

Homework:

Read: Chapters 14

Finish Projects

 

Topics Covered:

ASP vs PHP

ASP Declaration PHP Declaration

<%
response.write("Hello World!")
%>

<?php 
echo "Hello World";
?>
ASP Variable Declaration 
PHP Variable Declaration
dim name
name="Donald Duck"
$txt="Hello World";
ASP Write PHP Echo
response.write("Hello World!")
echo "Hello World";

 

Setup Dreamweaver for ASP to work with my server. You will need to setup your connection

Download the jstorslee.mdb database and put your name on it (first initial and last name).mdb then FTP the database into your directory on the Web!

dynamic

Dreamweaver combined these languages to create our dynamic page:

ADO - Server.CreateObject ("ADODB.Command");

SQL - SELECT * FROM productinfo

ASP

 

<%@LANGUAGE="JAVASCRIPT" CODEPAGE="1252"%>
<!--#include file="Connections/CNJstorslee2.asp" -->
<%
Code for the page 
%>

 

Terms:

ASP, PHP, Database, DSN and connection string

HTML Valid