網站全棧開發指南:HTML + CSS + JavaScript + PHP

曹化宇

  • 出版商: 清華大學
  • 出版日期: 2021-09-01
  • 定價: $594
  • 售價: 8.5$505
  • 語言: 簡體中文
  • ISBN: 7302583552
  • ISBN-13: 9787302583554
  • 相關分類: CSSHTMLJavaScriptPHP
  • 下單後立即進貨 (約4週~6週)

  • 網站全棧開發指南:HTML + CSS + JavaScript + PHP-preview-1
  • 網站全棧開發指南:HTML + CSS + JavaScript + PHP-preview-2
  • 網站全棧開發指南:HTML + CSS + JavaScript + PHP-preview-3
網站全棧開發指南:HTML + CSS + JavaScript + PHP-preview-1

買這商品的人也買了...

相關主題

商品描述

本書是一線程序員多年開發經驗的結晶。它深入淺出地講解Web開發所需的HTML、CSS、 JavaScript、PHP和數據庫等基礎內容,幫助讀者快速進入Web項目開發,在項目中靈活應用各種開發技術和方法。 本書共23章。第1章討論在Windows系統中創建網站的開發和測試環境。第2~10章主要討論PHP開發的相關內容,如PHP編程的基本概念、數據處理、運算過程、函數、PHP代碼管理、格式設置、操作文件系統等。第11和12章主要討論MariaDB的應用。第13章介紹PHP中使用GD模塊處理圖形圖像。第14和15章介紹開發PHP網站時需要的一些常用資源以及使用第三方資源PHPMailer處理郵件。第16章介紹HTML和CSS的應用。第17章討論JavaScript開發基礎。第18~22章主要討論表單、正則表達式、服務器與客戶端之間的數據交換、文件上傳,以及通過JavaScript操作高德地圖等綜合應用。第23章介紹PHP 8的安裝和應用,並討論PHP 8編程語言方面的新變化。 本書內容安排合理,架構清晰,註重理論與實踐相結合,適合廣大從事Web項目開發的人員、對Web項目開發感興趣的愛好者及大中專院校相關專業的學生閱讀。相關培訓院校及高校的老師亦可將本書作為教材使用。

目錄大綱

Contents 目  錄

 

第1章 準備工作……………………1

 

1.1 PHP開發與測試環境 ·················1

 

1.2 開發工具 ································5

 

1.3 安裝MariaDB數據庫·················6

 

第2章 PHP開發基礎 ……………11

 

2.1 頁面中添加PHP代碼 ···············11

 

2.2 語句和函數 ····························12

 

2.3 變量 ·····································14

 

2.4 常量 ·····································14

 

2.5 註釋 ·····································16

 

第3章 數據類型及操作……………17

 

3.1 整數 ·····································17

 

3.2 組合運算符 ····························21

 

3.3 浮點數 ··································21

 

3.4 類型判斷和轉換 ······················23

 

3.5 字符串 ··································24

 

3.6 mbstring模塊 ··························40

 

3.7 布爾類型 ·······························44

 

3.8 null值及變量檢測 ····················45

 

3.9 資源類型 ·······························46

 

3.10 混合型和void類型 ·················46

 

3.11 可空類型 ······························46

 

3.12 數學函數 ······························47

 

第4章 流程控制……………………51

 

4.1 比較運算 ·······························51

 

4.2 條件語句和?:運算符 ················53

 

4.3 switch語句 ·····························54

 

4.4 循環語句 ·······························56

 

4.5 錯誤控制 ·······························60

 

4.6 exit和die語句 ························63

 

第5章 函數…………………………64

 

5.1 定義與調用函數 ······················64

 

5.2 按引用傳遞參數 ······················65

 

5.3 動態處理參數和可變長度參數 ····67

 

5.4 回調類型和動態調用函數 ··········69

 

5.5 靜態變量 ·······························70

 

第6章 面向對象編程………………72

 

6.1 類與對象 ·······························72

 

6.2 構造函數與析構函數 ················75

 

6.3 靜態成員 ·······························77

 

6.4 類常量 ··································78

 

6.5 魔術方法 ·······························78

 

6.6 繼承 ·····································83

 

6.7 抽象類 ··································87

 

6.8 接口 ·····································88

 

6.9 對象序列化 ····························90

 

6.10 動態操作 ······························90

 

第7章 代碼文件引用與命名空間…93

 

7.1 引用代碼文件 ·························93

 

7.2 命名空間 ·······························93

 

7.3 _ _autoload()函數(PHP 7.2.0棄用) ····································95

 

7.4 spl_autoload_register()函數 ·········96

 

7.5 本書資源載入函數 ···················97

 

7.6 全局變量 ·······························98

 

第8章 數組…………………………99

 

8.1 基本操作 ·····························100

 

8.2 數組與變量 ··························104

 

8.3 數組成員操作 ·······················106

 

8.4 分割與組合 ··························110

 

8.5 排序 ···································119

 

8.6 計算 ···································125

 

8.7 多維數組 ·····························127

 

第9章 日期和時間………………130

 

9.1 時區設置 ·····························130

 

9.2 使用函數庫 ··························130

 

9.3 使用類庫 ·····························133

 

9.4 日期與時間的格式化 ··············137

 

第10章 文件系統 ………………140

 

10.1 獲取磁盤、目錄和文件信息 ····140

 

10.2 文件權限 ····························142

 

10.3 目錄和文件操作 ···················143

 

10.4 文件讀寫 ····························146

 

10.5 臨時文件 ····························151

 

10.6 壓縮與解壓 ·························152

 

第11章 MariaDB數據庫 ………156

 

11.1 數據庫 ·······························156

 

11.2 數據類型 ····························157

 

11.3 表 ·····································158

 

11.4 索引 ··································161

 

11.5 添加、修改、刪除記錄 ··········162

 

11.6 條件設置 ····························164

 

11.7 數據查詢 ····························168

 

11.8 函數 ··································172

 

11.9 連接 ··································178

 

11.10 聯合 ································180

 

11.11 視圖 ·································181

 

第12章 PHP中使用MariaDB數據庫 …………………182

 

12.1 連接和關閉數據庫 ················182

 

12.2 執行SQL並獲取查詢結果 ······184

 

12.3 處理多個查詢結果 ················187

 

12.4 語句預備與參數 ···················188

 

12.5 將文件保存到blob字段 ·········191

 

12.6 處理事務 ····························192

 

12.7 獲取新記錄的ID值 ··············193

 

第13章 圖形圖像 ………………195

 

13.1 創建圖像 ····························195

 

13.2 圖像輸出和保存 ···················197

 

13.3 圖形繪制 ····························197

 

13.4 旋轉 ··································207

 

13.5 翻轉 ··································208

 

13.6 圖像的分辨率 ······················209

 

第14章 Web開發資源 …………212

 

14.1 $_SERVER數組 ···················212

 

14.2 會話與$_SESSION數組 ········212

 

14.3 $_GET和$_POST數組 ·········213

 

14.4 header()函數 ·······················213

 

14.5 頁面中自動添加內容 ·············214

 

14.6 編碼與解碼 ·························215

 

第15章 發送電子郵件 …………217

 

15.1 通過PHPMailer發送電子郵件 ··································217

 

15.2 通過SMTP協議發送電子郵件 ··································217

 

第16章 HTML和CSS …………220

 

16.1 創建HTML網頁 ··················220

 

16.2 在頁面中使用CSS ················221

 

16.3 CSS選擇器 ·························223

 

16.4 CSS屬性設置基礎 ················235

 

16.5 佈局與定位 ·························251

 

16.6 文本與段落 ·························267

 

16.7 鏈接 ··································278

 

16.8 圖片與背景 ·························279

 

16.9 列表 ··································282

 

16.10 表格 ································290

 

16.11 iframe元素 ························296

 

16.12 HTML5的新語義元素 ··········297

 

16.13 object和edbmed元素 ··········298

 

16.14 動態樣式 ··························299

 

第17章 JavaScript ……………307

 

17.1 頁面中添加JavaScript代碼 ·····307

 

17.2 數據處理 ····························309

 

17.3 代碼流程控制 ······················317

 

17.4 函數和函數類型 ···················321

 

17.5 面向對象編程 ······················324

 

17.6 數組 ··································327

 

17.7 字符串 ·······························334

 

17.8 URI編碼 ····························337

 

17.9 日期與時間 ·························338

 

17.10 數學計算 ··························342

 

17.11 計時器 ·····························343

 

17.12 Ajax ·································346

 

17.13 對話框 ·····························351

 

17.14 DOM ·······························353

 

17.15 window.onload事件 ·············363

 

17.16 audio和video元素 ··············364

 

17.17 localStorage和sessionStorage

 

    對象 ································367

 

第18章 處理HTML表單 ……369

 

18.1 form元素 ···························369

 

18.2 input元素 ···························370

 

18.3 textarea元素 ························380

 

18.4 select和option元素 ·············380

 

18.5 button元素 ·························385

 

18.6 label元素 ···························386

 

18.7 fieldset和legend元素 ············387

 

18.8 單頁面處理表單 ···················388

 

第19章 正則表達式 ……………390

 

19.1 preg_match()函數 ·················390

 

19.2 模式定義 ····························391

 

19.3 PCRE函數 ··························394

 

19.4 JavaScript中的正則表達式 ······401

 

19.5 常用模式 ····························403

 

第20章 數據交換 ………………406

 

20.1 Excel ·································406

 

20.2 CSV ··································410

 

20.3 XML ·································416

 

20.4 JSON ·································420

 

 

 

第21章 文件上傳 ………………426

 

21.1 上傳表單 ····························426

 

21.2 接收上傳文件 ······················427

 

21.3 同時上傳多個文件 ················428

 

21.4 單頁面處理 ·························429

 

第22章 高德地圖 ………………431

 

22.1 地圖初始化 ·························431

 

22.2 標記 ··································432

 

22.3 地圖控件 ····························436

 

22.4 距離測量 ····························437

 

第23章 PHP 8 …………………441

 

23.1 安裝PHP 8 ·························441

 

23.2 命名參數 ····························441

 

23.3 在構造函數中聲明屬性 ··········442

 

23.4 空值安全運算符 ···················443

 

23.5 聯合類型 ····························444

 

23.6 match表達式 ·······················445