Instant Flask Web Development

Ron DuPlain

  • 出版商: Packt Publishing
  • 出版日期: 2013-09-08
  • 售價: $1,030
  • 貴賓價: 9.5$979
  • 語言: 英文
  • 頁數: 78
  • 裝訂: Paperback
  • ISBN: 1782169628
  • ISBN-13: 9781782169628
  • 相關分類: Flask
  • 下單後立即進貨 (約3~4週)

商品描述

Impatient for results? This is a fast, concise guide to the essentials of Flask with a totally practical approach that means you'll be up and running on your first Flask app before you know it.

  • Learn something new in an Instant! A short, fast, focused guide delivering immediate results
  • Build a small but complete web application with Python and Flask
  • Explore the basics of web page layout using Twitter Bootstrap and jQuery
  • Get to know how to validate data entry using HTML forms and WTForms
  • Understand SQLAlchemy and relational databases

In Detail

Flask is a web framework for Python, which lets you start simply and grow carefully without facing any issues with the framework as your project gets large. Flask integrates Werkzeug (a web programming toolkit) and Jinja (a templating engine) and adds a layer that lets you build web applications and services in a compact way, while letting you choose your own tools.

Instant Flask Web Development takes you beyond the quick start in the Flask documentation and shows you a bottom-up approach to organizing your Flask application. It shows you how to build a small deployable scheduling application with pointers to the various design decisions you can make when developing with Flask.

Instant Flask Web Development lets you set up your development environment and learn how Flask handles web requests, then shows you how to build a functional data-driven web application that is ready to publish, by adding one layer at a time. When working with Flask, you can work with Python and utilize its best tools for the job. The book will help you build the layers of a simple application: URL routes with Flask, a database with SQLAlchemy, form validation with WTForms, user authentication and sessions, page layout with Twitter Bootstrap, and browser code with jQuery.

This book promises to get you up and running on your first Flask app, so that you can use Flask and Python on your next web project.

What you will learn from this book

  • Manage your project dependencies using virtualenv
  • Understand how Flask provides URL routing and web request handling
  • Recognize how Flask serves static files on disk
  • Learn about modeling, storing, and querying data with SQLAlchemy
  • Present HTML forms and validate input with WTForms
  • Build a page layout with Twitter Bootstrap using a base Jinja template
  • Create, recall, update, delete, and list database records
  • Build custom template filters in Jinja to format data
  • Authenticate users and maintain sessions

Approach

Filled with practical, step-by-step instructions and clear explanations for the most important and useful tasks. The book uses a bottom-up approach to help you build applications, and is full of step-by-step instructions and practical examples to help you improve your knowledge.

Who this book is written for

Instant Flask Web Development is for developers who are new to web programming, or are familiar with web programming but new to Flask. This book gives you a head start if you have some beginner experience with Python and HTML, or are willing to learn.

商品描述(中文翻譯)

迫不及待想要看到結果嗎?這是一本快速、簡潔的 Flask 指南,以實用的方式引導您進入 Flask 的基本知識,讓您在不知不覺中就能運行您的第一個 Flask 應用程式。

- 立即學習新知識!一本短小、快速、專注的指南,立即帶來成果。
- 使用 Python 和 Flask 建立一個小而完整的網頁應用程式。
- 使用 Twitter Bootstrap 和 jQuery 探索網頁佈局的基礎知識。
- 了解如何使用 HTML 表單和 WTForms 驗證資料輸入。
- 理解 SQLAlchemy 和關聯式資料庫。

Flask 是一個用於 Python 的網頁框架,讓您可以從簡單開始,並在項目變得龐大時謹慎擴展,而不會遇到框架問題。Flask 整合了 Werkzeug(一個網頁程式開發工具包)和 Jinja(一個模板引擎),並添加了一個層次,讓您以緊湊的方式構建網頁應用程式和服務,同時讓您選擇自己的工具。

《即時 Flask 網頁開發》將帶您超越 Flask 文件中的快速入門,並向您展示一種自下而上的方法來組織您的 Flask 應用程式。它向您展示了如何建立一個小型可部署的排程應用程式,並指出在使用 Flask 開發時可以做出的各種設計決策。

《即時 Flask 網頁開發》讓您設置開發環境,學習 Flask 如何處理網頁請求,然後逐步添加一層一層地建立一個功能齊全的資料驅動網頁應用程式,準備好發布。在使用 Flask 時,您可以使用 Python 並利用其最佳工具來完成工作。本書將幫助您建立一個簡單應用程式的各個層次:使用 Flask 的 URL 路由、使用 SQLAlchemy 的資料庫、使用 WTForms 的表單驗證、使用 Twitter Bootstrap 的頁面佈局以及使用 jQuery 的瀏覽器程式碼。

本書承諾讓您在第一個 Flask 應用程式上運行起來,以便您可以在下一個網頁項目中使用 Flask 和 Python。

本書將教您以下內容:
- 使用 virtualenv 管理專案相依性。
- 了解 Flask 如何提供 URL 路由和網頁請求處理。
- 了解 Flask 如何提供靜態檔案服務。
- 使用 SQLAlchemy 建立、儲存和查詢資料。
- 呈現 HTML 表單並使用 WTForms 驗證輸入。
- 使用基礎 Jinja 模板建立頁面佈局。
- 建立、檢索、更新、刪除和列出資料庫記錄。
- 在 Jinja 中建立自訂模板過濾器以格式化資料。
- 驗證使用者並維護會話。

本書充滿了實用的、逐步的指示和清晰的解釋,針對最重要和最有用的任務。本書使用自下而上的方法來幫助您建立應用程式,並充滿了逐步的指示和實用範例,幫助您提升知識。

《即時 Flask 網頁開發》適合那些新手網頁程式開發者,或者對網頁程式開發有一些了解但對 Flask 不熟悉的開發者。本書將為您提供一個起點,如果您對 Python 和 HTML 有一些初步經驗,或者願意學習,將能夠快速上手。