Giter VIP home page Giter VIP logo

news's Introduction

Simple news site

Description

An application written for Django1.4.5 using Python2.7.

Pages:
  • news/ - displays stories sorted by date of creation page. "Read More" links are generated, with total length and number of comments
  • news/2013/04/12/Joel-is-a-slug - this format is used for individual stories. Contains a form for content submission, links to next/previous story and day archive. * news/2014/02/17 - day archive, with links to next/previous day and month archive.
  • news/2014/02/ - month archive, with links to next/previous month and year archive.
  • news/2014/ - year archive (a list of months), with links to next/previous years.

Example templates included in the templates/ subdirectory. Basic admin interface available.

Quickstart

  1. Add "news" to your INSTALLED_APPS setting like this:

    INSTALLED_APPS = (
      ...
      'news',
    )
    
  2. Include the news URLconf in your project urls.py like this:

    url(r'^news/', include('news.urls')),
    
  3. Add login/logout views to your project's urls.py:

    url(r'^accounts/login/$', 'django.contrib.auth.views.login', {'template_name': 'news/login.html'}, name='login'),
    url(r'^accounts/logout/$', 'django.contrib.auth.views.logout', name='logout'),
    
  4. Run python manage.py syncdb to create the news models.

  5. Start the development server and visit http://127.0.0.1:8000/admin/ to create entries, Users and Blogs (you'll need the admin, auth apps enabled). Users should be created without 'staff' privileges, otherwise they can modife each others' Blogs. Appropriate create/edit views are provided.

Contact

[email protected]

news's People

Contributors

monuszko avatar

Stargazers

Yasemen avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.