Try Django 1.9 – 35 of 38 – Item Publish Date & Draft



Try Django 1.9 – 35 of 38 – Item Publish Date & Draft

** Try Django 1.9 ** is an introduction to Django version 1.9 by creating a simple, yet robust, Django blog. This series covers a variety of Django basics as well as Django 1.9 specific material. Learn more about the Django Web Framework here:

Subscribe to our channel:

Generally the topics will include:
– Django Project Setup
– Class Based Views (& some Function Based Views)
-…

12 Comments

  1. Thank you very much for the videos!!! One question, is there any way to post the img tag in a different place that the defined, when you create the post? For example, if you write a post and want to place the image in the middle of the post instead of in the defined position like now? Does this make any sense to you?

  2. At 1:11 to 2:49 the 'publish' field is in question as lacking a Date….

    I assume assigning the "timezone.now()" (not showing up in the Post model) will thus then be "hidden" (applied) in the Django settings. ergo, if someone would to download this code for any reason…that might not show up in the Django settings as not likely ported with the Github download?

    timezone.now() searches within the repository are here:
    https://github.com/codingforentrepreneurs/try-django-19/search?utf8=%E2%9C%93&q=timezone.now%28%29&type=

  3. Hey Justin,

    I added draft and publish to my model and did migrations. But when I am trying to add publish field to my form, it is giving me following error.

    django.core.exceptions.FieldError: 'publish' cannot be specified for Post model form as it is a non-editable field

    Please Help me out.
    Thanks,
    Akash.

  4. This didn't work for me, when i go to post/create 'draft' and 'published' are not there BUT if I create a post in the admin panel they are….. any ideas? i'm on django 1.10 and py 3.5

  5. I learned so much with you, thanks so much … but I have a question, how can I change the time of "publish", I mean, in this case we need to write YYYY-MM-DD but I want to write DD-MM-YYYY, how can I change it? sorry for my bad english

Leave a Reply

Your email address will not be published.


*