Ultra-Practical Python small Project--a python-based phone address book QR code generation website--1, Project introduction and development environment

Source: Internet
Author: User

This project is my first complete Python Web project, and for beginners, this project is definitely a great practiced hand project.

The name is still difficult, but it is really annoying to enter such long names (phone address book QR code generation site) to define the site, so give this project a name, what is it called? It's called "Goose Day Directory" (Earth address list).


--------------------------------------------------------------------------------------------I'm a split line------------------------ --------------------------------------------------------------------------

First look at the project :

Mei Yemai:

  

After beauty:

Then, a beautiful QR code is generated.

The QR code will be stored in the project path: \static\cardimg:

Scan the QR code in the image with your phone and you will see the following effect:

Click Save to sync your contacts card to your phone:

  

What do you think? Pretty cool, huh? It's definitely a B artifact.

--------------------------------------------------------------------------------------------I'm a split line------------------------ --------------------------------------------------------------------------

Next, I'll explain my development environment :

First of all, you have to have python2.7, and the Python on my computer is python2.7.12

Second, you have to install the web.py library, the PIL library, and the QRCode library. And how do you install these libraries? The premise is to have a PIP, how to install I will not wordy, self-Baidu, or concern my follow-up blog.

Shortcut key ctrl+r, enter cmd, open the command line, type the following command (highlighted):

  pip install web.py #web. Py is one of the legendary Python 4 Web development frameworks (the other three types are Django, Flask, Tornado)

  Pip install PIL #PIL图形加载库, primarily for opening pictures and storing pictures

  Pip install QRCode #这个项目的核心所在, two-dimensional code generation library

Of course, time modules are also needed, mainly for delay processing.

Note that after installing the PIP, if you feel that the default source download module speed is too slow, you can also use domestic sources, such as the source of watercress,

pip install-i https://pypi.doubanio.com/simple/module nameTo increase download speed.

Next, I will introduce the IDE that I use, 工欲善其事, must first bitter its mind, labor its bones, hungry its body skin ... Far away, the good IDE will bring great convenience to the programming. The IDE I'm using is pycharm, the most python-developed IDE, designed for Python. I also uneasy so many, concrete how strong, Baidu knew.

--------------------------------------------------------------------------------------------I'm a split line------------------------ --------------------------------------------------------------------------

  The significance of the project and the development of the direction:

The main advantage of this project at this stage is to be able to make their own QR Code business card, the production of a good two-dimensional code card into the mobile phone, in the face of new customers, you can let customers sweep two-dimensional code card, so that you can let others easily put you into the phone address book.

This project can also be combined with selenium module, through to Excel table or Notepad to enter multiple address book information, Excel table or Notepad information automatically imported into this site, you can batch generate two-dimensional code business cards, these two-dimensional code card can be long-term retention.

In fact, the above is not the focus, the focus is that the novice can take this project familiar with the development of two-dimensional code, familiar with the use of web framework, this is only a good example.

--------------------------------------------------------------------------------------------I'm a split line------------------------ --------------------------------------------------------------------------

The above is the overall introduction of the whole project, want to refer to the source code, you can visit my github to download: HTTPS://GITHUB.COM/GITDZREAL93/WX2WM/TREE/MASTER/WX2WM

Follow my blog, I will follow the project's Python code and front-end template to do a little more detailed introduction, Thank you!

Super-Practical Python Small project--Python-based phone address book QR code generation website--1, Project introduction and development environment

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.