Microsoft Word - PHP7Ch01.docx

Similar documents
互動網頁技術系列課程 HTML與CSS網站基礎設計 [12pt]

PowerPoint プレゼンテーション

Microsoft Word - 01.DOC

關於本書 l 3 PhoneGap Appcelerator Titanium Sencha Touch (wrapper framework) Native App PhoneGap Build Native App Hybrid App Java Objective-C Android SDK

untitled

Microsoft Word PHPCh15.docx

untitled

吉林省科技发展计划项目申报书23005

06 01 action JavaScript action jquery jquery AJAX CSS jquery CSS jquery HTML CSS jquery.css() getter setter.css('backgroundcolor') jquery CSS b

關於本書 Part 3 CSS XHTML Ajax Part 4 HTML 5 API JavaScript HTML 5 API Canvas API ( ) Video/Audio API ( ) Drag and Drop API ( ) Geolocation API ( ) Part 5

05 01 accordion UI containers 03 Accordion accordion UI accordion 54

RUN_PC連載_10_.doc

No.32

5-1 nav css 5-2

The Applicibility of Google Maps/Earth and Urmap API to Real Estate Database* Jin-Tsong Hwang** Abstract Whether the real estate market is prosperous

1 1 大概思路 创建 WebAPI 创建 CrossMainController 并编写 Nuget 安装 microsoft.aspnet.webapi.cors 跨域设置路由 编写 Jquery EasyUI 界面 运行效果 2 创建 WebAPI 创建 WebAPI, 新建 -> 项目 ->

<4D F736F F D BB4FC657A4E5A4C6BEC7B34EACE3B051B77CC4B3B57BAAED2E646F6378>

CC213

Perl

6-1 Table Column Data Type Row Record 1. DBMS 2. DBMS MySQL Microsoft Access SQL Server Oracle 3. ODBC SQL 1. Structured Query Language 2. IBM

bootstrap - 2

1 請 至 下 載 Google Earth 6.0 版 圖 6-1: 下 載 畫 面 2 開 啟 Google Earth, 認 識 Google Earth 的 基 本 介 面 2. 搜 尋 1. 主 功 能 選 單 5. 工 具 列 6 導 航

Microsoft Word 样章.dot

填 写 要 求 1. 以 word 文 档 格 式 如 实 填 写 各 项 2. 表 格 文 本 中 外 文 名 词 第 一 次 出 现 时, 要 写 清 全 称 和 缩 写, 再 次 出 现 时 可 以 使 用 缩 写 3. 本 表 栏 目 未 涵 盖 的 内 容, 需 要 说 明 的, 请 在

導讀 ASP.NET HTML ASP 第一篇 基礎篇第 1 章 認識 ASP.NET ASP.NET ASP.NET ASP.NET ASP.NET 第 2 章 認識 Visual Studio 20 開發環境 Visual Studio 20 Visual Studio 20 第二篇 C# 程式

Microsoft Word - 最新正文.doc


序 言 本 专 业 人 才 培 养 方 案 以 适 应 市 场 需 求 为 目 标, 根 据 学 校 校 企 双 主 体 人 才 培 养 的 要 求 和 移 动 应 用 开 发 专 业 的 特 点 设 置 课 程 体 系, 体 现 了 课 程 为 市 场 服 务 的 特 点 本 专 业 要 求 学

全国计算机技术与软件专业技术资格(水平)考试

untitled

WordPress OSSF OSSF is Seeking Software Freedom 1 blog WordPress WordPress WordPress WordPress 2 WordPress WordPress is a state-of-the-art semantic pe

FileMaker 15 WebDirect 指南

(Microsoft Word - \272\364\263q\245|\244A_ _\304\254\253\330\336\263__\272\353\302\262\263\370\247i.doc)

中南大学第二届软件创新大赛

Java

(京)新登字063号

untitled

2013 C 1 #include <stdio.h> 2 int main(void) 3 { 4 int cases, i; 5 long long a, b; 6 scanf("%d", &cases); 7 for (i = 0; i < cases; i++) 8 { 9 scanf("%

FY.DOC

chp6.ppt

本 课 程 作 为 非 计 算 机 专 业 本 科 通 识 课 程, 是 一 门 理 论 和 实 践 紧 密 结 合 的 实 用 课 程, 内 容 包 括 计 算 机 基 础 部 分 和 程 序 设 计 部 分 计 算 机 基 础 部 分 涵 盖 计 算 机 软 硬 件 组 成 数 制 表 示 操

2 第 章 绪 论 Internet 2.0 使 得 消 费 型 电 子 产 品 用 户 可 以 通 过 多 种 不 同 的 数 据 网 络 访 问 互 联 网 内 容 用 户 可 以 使 用 便 携 式 消 费 型 电 子 设 备, 如 智 能 手 机 触 屏 平 板 电 脑 电 子 书, 甚 至

epub83-1

untitled

ebook14-4

臺銀人壽「98年九至十一職等人員甄試」

final

ebook4-12

1. ( B ) IT (A) (B) (C) (D) 2. ( A ) (A) (B) (C) (D) 3. ( B ) (A) GPS (B) GIS (C) ETC (D) CAI 4. ( D ) (A) (B) (C) (D) 5. ( B ) (Stored Program) (A) H

, 即 使 是 在 昏 暗 的 灯 光 下, 她 仍 然 可 以 那 么 耀 眼 我 没 有 地 方 去, 你 会 带 着 我 么 杜 晗 像 是 在 嘲 笑 一 般, 嘴 角 的 一 抹 冷 笑 有 着 不 适 合 这 个 年 龄 的 冷 酷 和 无 情, 看 着 江 华 的 眼 神 毫 无 温

Microsoft Word - Ch06.docx

Adobe AIR 安全性

1. 2. Flex Adobe 3.

RUN_PC連載_8_.doc

Microsoft Word - 第01章new.doc

新版 明解C++入門編

<4D F736F F D D6D0B9FAB5D8D6CAB4F3D1A7BFC6D1D0BEADB7D1D3D0B9D8D6C6B6C82D48442E646F63>

被当作鬼的人.doc

第一章

天仁期末個人報告1.PDF

abyss_of_dreams_2014

技 巧 5: 避 免 除 以 0 的 運 算 在 做 除 的 運 算 時, 先 檢 查 除 數 的 數 值, 避 免 有 除 以 0 的 情 況 若 運 算 中 除 數 為 0,SAS 會 在 LOG 中 註 記 提 醒 並 將 運 算 結 果 設 定 為 遺 漏 值, 減 慢 程 式 的 執 行

untitled

基于CDIO一体化理念的课程教学大纲设计

Python a p p l e b e a r c Fruit Animal a p p l e b e a r c 2-2

( CIP) /. :, ( ) ISBN TP CIP ( 2005) : : : : * : : 174 ( A ) : : ( 023) : ( 023)

(Microsoft Word - \244g\246a\247B\244\275\253H\245\365\244\247\275\325\254d\254\343\250s doc)

新・明解C言語入門編『索引』

untitled

开发技术大揭秘册子内页_Vol.3_1123_预览版

2/80 2

目 錄 1. 摘 要 1 2. 簡 介 2 3. 系 統 環 境 需 求 3 4. 系 統 架 構 4 5. 系 統 流 程 4 6. 資 料 庫 設 計 規 劃 7 7. 配 送 系 統 設 計 規 劃 配 送 系 統 流 程 圖 9 8. 實 際 測 試 網 頁 端 (

財金資訊-83期.indd

! 2000 CSSsprites.com Web FTP app 20% 80% getelementbyid() UI Facebook F8 Web CSSsprites.com Web JavaScript CSS React xi React UI UI 反應 UI 宣告 d

1.JasperReport ireport JasperReport ireport JDK JDK JDK JDK ant ant...6








1

「西醫基層總額支付委員會《第28次委員會議紀錄

Open topic Bellman-Ford算法与负环

_汪_文前新ok[3.1].doc

2 WF 1 T I P WF WF WF WF WF WF WF WF 2.1 WF WF WF WF WF WF

Microsoft PowerPoint - P766Ch09.ppt

概述

校园之星

2-第二章(11#).cdr

Spyder Anaconda Spyder Python Spyder Python Spyder Spyder Spyder 開始 \ 所有程式 \ Anaconda3 (64-bit) \ Spyder Spyder IPython Python IPython Sp

目 录 目 录 平 台 概 述 技 术 架 构 技 术 特 点 基 于 统 一 平 台 的 多 产 品 线 支 撑 先 进 性 安 全 性 开 放 性 高 性 能 和

团 学 要 闻 我 校 召 开 共 青 团 五 届 九 次 全 委 ( 扩 大 ) 会 议 3 月 17 日, 我 校 共 青 团 五 届 九 次 全 委 ( 扩 大 ) 会 议 在 行 政 办 公 楼 五 楼 会 议 室 举 行, 校 团 委 委 员 各 院 ( 系 ) 团 委 书 记 校 学 生

Professional Ajax Ajax Adaptive Path, LLC Jesse James Garrett Ajax php Garrett WebG

全 国 高 等 职 业 教 育 规 划 教 材 21 世 纪 高 职 高 专 规 划 教 材 系 列 高 等 职 业 教 育 计 算 机 专 业 规 划 教 材 选 题 征 集 通 知 一 选 题 范 围 ( 不 仅 限 于 此 ) 选 题 方 向 选 题 名 计 算 机 基 础 计 算 机 应 用

AL-M200 Series

麻 省 理 工 學 院 是 在 西 元 2013 年 12 月 3 日 推 出 MIT App Inventor 2 網 站, 提 供 免 費 的 雲 端 服 務, 使 用 者 可 以 透 過 瀏 覽 器 來 開 發 Android 裝 置 應 用 程 式, 該 網 站 的 網 址 為 : http

审计署关于北京市密云县2012年机构运转支出情况的审计调查结果

2014zb9

Transcription:

PHP 01 1-6 PHP PHP HTML HTML PHP CSSJavaScript PHP PHP 1-6-1 PHP HTML PHP HTML 1. Notepad++ \ch01\hello.php 01:<!doctype html> 02:<html> 03: <head> 04: <meta charset="utf-8"> 05: <title> PHP </title> 06: </head> 07: <body> 08: <?php 09: echo("hello World!"); PHP 10: phpinfo(); 11:?> 12: </body> 13:</html> HTML HTML 03 ~ 06HTML 04 UTF-8 05 PHP 07 ~ 12HTML 1-23

08 ~ 11PHP 0811 <?php?> PHP <?php?> 09 PHP echo() "Hello World!" PHP (;) 10 PHP phpinfo() PHP PHP Apache MySQL ODBC 2. NotePad++ [] \ [] [] \ [ ] [] UTF-8 BOM hello.php ch01 C:\AppServ\www\ch01 ( [] [ UTF-8 ( BOM)]) 1. ch01 C:\AppServ\www\ch01 3. hello (.php) 4. [] 2. PHP 1-24

PHP 01 3. http://localhost/ch01/hello.php [Enter] 0910 <?php?> PHP <?php?> <??> <??> PHP php.ini short_open_tag on <??> <?php?> XML <script language="php"></script> HTML PHP JavaScript JavaScript <script language="javascript"></script> <% %> ASP ASP PHP <% %> PHP 1-25

1-6-2 PHP PHP 1. PHP NotePad++ PHP UTF-8 BOM demo.inc ch01 ( C:\AppServ\www\ch01) \ch01\demo.inc <?php echo("hello World!"); phpinfo();?> 2. PHP NotePad++ UTF-8 BOM hello2.php ch01 PHP include_once() PHP \ch01\hello2.php <!doctype html> <html> <head> <meta charset="utf-8"> <title> PHP </title> </head> <body> <?php include_once("demo.inc");?> </body> </html> 3. http://localhost/ch01/hello2.php [Enter] 1-26

PHP 01 PHP PHP include("/path/filename") require("/path/filename") include_once("/path/filename") require_once("/path/filename") include() include_once() (warning) require() require_once() (fatal error) include_once() require_once() PHP PHP (fatal error) include() require() PHP 1-27

PHP echo() HTML 09 echo() Hello World! <h1><b> <i> HTML 1 \ch01\hello3.php 01:<!doctype html> 02:<html> 03: <head> 04: <meta charset="utf-8"> 05: <title> PHP </title> 06: </head> 07: <body> 08: <?php 09: echo("<h1><b><i>hello World!</i></b></h1>"); 10:?> 11: </body> 12:</html> 1-28

PHP 01 1-7 PHP PHP (program) (statement) (reserved word) (keyword) PHP PHP function PHP function (special character)php ({ }) (;) ($) /* */ (identifier) mynamemyaddress PHP (function) (flow control) (class) PHP HTML PHP definefunctionifelsedo forwhile $myname $myname N n if IF if 1-29

PHP $x = 10; $x = 10; $x = 10; PHP (;) echo ("Hello World!"); PHP // # // # PHP /* */ /* */ /* xxxxx /* */ */ HTML <!-- --> PHP 1-30

PHP 01 PHP PHP and or xor FILE exception php_user_filter LINE array () as break case cfunction class const continue declare default die () do echo () else elseif empty () enddeclare endfor endforeach endif endswitch endwhile eval () exit () extends for foreach function global if include () include_once () isset () list () new old_function print () require () require_once () return () static switch unset () use var while FUNCTION CLASS METHOD 1-31

15 C H A P T E R

15-1 Google API Google API Google Google API Google Maps API Google Maps API Google AndroidAndroid Android SDK API Android Google Calendar API Google Toolbar API API Google YouTube API API YouTube Google Earth API Google Earth JavaScript API Google Earth (3D ) 3D KML 3D Google AJAX Search API API Google Google API Google Maps API Google Maps Google API Google Developers (https://developers.google.com/) 15-2

Google 15 15-2 Google Maps Google Maps API Google Maps PC 11 jquery Mobile 1. 2. () 3. Google () 15-3

() [] ()() () () 15-4

Google 15 Google Google Maps API <\ch15\farm.php> [] <showmap.php> <\ch15\showmap.php> Google Maps API \ch15\farm.php 01:<!doctype html> 02:<html> 03: <head> 04: <meta charset="utf-8"> 05: </head> 06: <body> 07: <?php 08: $farm_address=array(' 131-1 ', 09: ' 233 ', 10: ' 130 ', 11: ' 23 '); 12:?> 13: <form method="post" action="showmap.php"> 14: <input type="radio" name="farm" value="<?php echo $farm_address[0];?>" checked> <br> 15: <input type="radio" name="farm" value="<?php echo $farm_address[1];?>"> <br> 16: <input type="radio" name="farm" value="<?php echo $farm_address[2];?>"> <br> 17: <input type="radio" name="farm" value="<?php echo $farm_address[3];?>"> <br> 18: <input type="submit" value=""> 19: </form> 20: </body> 21:</html> 15-5

08 ~ 11 farm_address MySQL 13 ~ 19 [] 13 action showmap.php [] showmap.php 14 ~17 value \ch15\showmap.php ( 1/2) 01:<!doctype html> 02: <html> 03: <head> 04: <meta charset="utf-8"> 05: <script type="text/javascript" src="http://maps.google.com/maps/api/js?sensor=false"> 06: </script> 07: <script type="text/javascript"> 08: var geocoder; 09: var map; 10: 11: function initialize() 12: { 13: geocoder = new google.maps.geocoder(); 14: var latlng = new google.maps.latlng(0, 0); 15: var myoptions = {zoom:10, center:latlng, maptypeid:google.maps.maptypeid.roadmap}; 16: map = new google.maps.map(document.getelementbyid("map_canvas"), myoptions); 17: codeaddress(); 18: } 19: 20: function codeaddress() 21: { 22: var address = document.getelementbyid("address").value; 23: if (geocoder) 24: { 25: geocoder.geocode({'address': address}, function(results, status) 15-6

Google 15 \ch15\showmap.php ( 2/2) 26: { 27: if (status == google.maps.geocoderstatus.ok) 28: { 29: map.setcenter(results[0].geometry.location); 30: var marker = new google.maps.marker({map:map,position:results[0].geometry.location}); 31: } 32: else 33: { 34: alert("" + status); 35: } 36: }); 37: } 38: } 39: </script> 40: </head> 41: <body onload="initialize()"> 42: <input type="hidden" id="address" value="<?php echo $_POST["farm"];?>"> 43: <div id="map_canvas" style="width:500px; height:500px;"></div> 44: <a href="farm.php"></a> 45: </body> 46:</html> 0506 Google Maps API API JavaScript Google Maps API sensor ( GPS ) sensor=false 11 ~ 18 initialize() codeaddress() 13 google.maps.geocoder geocoder 22.638095 120.325699 15-7

14 google.maps.latlng latlng (0, 0) 15 myoptions 10 latlng 2D 16 google.maps.map map HTML id "map_canvas" 43 <div> 17 codeaddress() 20 ~ 38 codeaddress() 22 marker 41 <body> onload initialize() 42 id "address"value <farm.php> 22 43 <div> id "map_canvas" 500 500 500px 100% 44 <farm.php> 15-8