We recommend the django learning website today !, Django learning website!
In the first 20 days of every month, I spent about three days studying django during my work hours and finally spent some time studying django. This reall
User Management Section of Django's blog website (using its own django. contrib. auth) 1. Registration Section, django. contrib. auth
Project tool: Python 2.7.11 Django 1.10.2 Bootstrap 3.3.0 IDE: eclipse Pydev
1. Make sure that 'django. contrib. auth' already exists in sett
Simple Django tutorial, django tutorial1. Introduction to Django 1. Introduction to the web Framework
Before introducing Django, you must first introduce concepts such as WEB framework.
Web Framework: someone else has set a web website
/$ ', userena_views.signin, {'auth _ form': BsAuthenticationForm}, name = 'userena _ signin '), (r ^_^ _ ^ ', include ('userena. urls ')),)
Questions about Chinese user name
Like django-admin, django-userena cannot be registered in Chinese. It seems unreasonable for a Chinese website to use a Chinese registration ID.
Django
) Understand the relationship of urls.py under each appname under the urls.py and ProjectName directory, than the configuration;4) write "views.py" in the appname directory, return variables and specific pages;6. Enter "python. \manage.py sycndb" To create a database, this article does not mention this part of the content, the next time to strive for a deeper understanding, and then organize.---------------------------------------------------------------------------------------------------------
A simple tutorial on using the Django-userena component in Python django
This article describes how to use the Django-userena component in Python, including the implementation of simple functions such as user login and registration. For more information, see
Using twitter/bootstrap, the basic template of the Project is
Not limited to Chinese and English. question added: I am currently writing Django + flatpages. I feel that the front-end interface is not very good. I can see that the front-end of Bootstrap is more beautiful, but I don't know how to integrate it into Django, if you want to find some information in this area, I would like to recommend some documents in Chinese and English.
Question added: I am currently wri
. Django-userena The default template is very ugly to display in the project. We need to rewrite the default template for Django-userena and use Django-bootstrap to generate the form.
forms.py# add bootstrapmixinfrom bootstrap.forms import Bootstrapmixinclass bsauthenticationform for the original form ( Authenticationform, Bootstrapmixin): Def __init__ (self, *a
This article mainly introduces the Python Django Django-userena components of the simple use of the tutorial, including user login and registration, such as the implementation of simple functions, need friends can refer to the
Using Twitter/bootstrap, the project's underlying template is well done. The next step is to start processing the User Center.
User Cent
Python Django environment setup tutorial (MAC + pycharm + Django ++ postgreSQL), djangopycharm
Setting up the Django environment seems to be a very simple task. In fact, it is not the case that I have struggled for more than half a day, so I would like to summarize the entire setup process here, at the same time, we al
Sign up, add apps, select python3.5, then open the console
Build python3.5 Virtual Environment
python --version virtualenv -p /usr/bin/python3.5 VENV source VENV/bin/activate
Installing Django
pip install "django
Create a Web site
django-admin startproject mvote cd mvote python manage.py star
tools, so virtualenv is a more powerful solution (see article).
1. To install this package, you need to use the PIP (you have installed it, right?). )
Pip Install--user django-polls/dist/django-polls-0.1.tar.gz
2. If you're lucky, your Django project should be working properly now. Run the server again to confirm.
3. To uninstall this package, use PIP.
Pip Unin
/background.gif.
Then, in the style sheet file (polls/static/polls/style.css), add:
/* POLLS/STATIC/POLLS/STYLE.CSS * *
background:white url ("images/background.gif") No-repeat right Bottom;
}
Reload http://localhost:8000/polls/ you will see that the background image is placed in the lower-right corner of the page.
Warning
Obviously {% static%} template tags are not available in static files, such as style sheet files, because they are not Django
example, {{ship_date|date: "F J, Y"}}, we pass the variable ship_date to the date filter. Specify the number of references "F j,y" at the same time. The date filter formats the output according to the number of parameters. The filter is with a pipe character (|) To invoke. You can see the UNIX pipe symbol in detail.In fact, I prefer to filter this information in the background. Because we cannot ask the artist or the person who participates in the layout design to have too many programming foun
Tutorial on using SQLAlchemy to operate databases in Python Django framework, djangosqlalchemy
What is zero and SQLAlchemy?SQLAlchemy's official website contains the following text:
SQLAlchemy is the Python SQL toolkit and Object Relational Mapper that givesApplication developers the full power and flexibility of SQL.SQLAlchemy is a very powerful ORM and database
Not limited to Chinese and English.
Add: I am writing now is django+flatpages, feel the front-end interface is not very good, see Bootstrap as the front end will be more beautiful, but do not know how to integrate into Django, want to find some of this information, to recommend some
Reply content:How to Tango with Django:a Python Django
This article mainly introduces the use of django-tagging in the Python Django Framework, for the function of the tag part of network programming to help, the need for friends can refer to the
Django uses the app mechanism to reuse components, and making full use of existing apps can greatly simplify the development effort. Currently Django's app is not rich enou
queries.
You can specify the name of the field you want to select_related with variable length parameters. You can also implement a specified recursive query by using the double underscore "__" to concatenate the field names. No specified field is cached, no depth specified is not cached, and Django will make a SQL query again if it is to be accessed.
You can also specify the depth of recursion through the depth parameter, and
Use the Django framework to build a game website.
Click the open link for the complete Project Link
In the previous article, we used Javascript and Html5 to implement a fl game. In this article, we hope to implement a game website based on it to enable user registration and login, game score records, and ranking display, weibo sharing and other functions.
F
Technorati tags: django, i18n, javascript, Chinese, multi-language
Django's internationalization support is very good and easy to use. It supports code, templates, and JS internationalization solutions. Especially in version 1.2
Local formatting of dates and numbers has been well-developed for internationalization.
Application Method
First, modify settings. py:
1. Add TEMPLATE_CONTEXT_PROCESSORS to django.
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.