Hey guys I am trying to figure out how to create a api using the django
rest frame work to display a airplane flight tracker on a website. I am not
really sure how to do it as from what i have seen as examples the api's
have been used form simple data like names, height, id number, etc. I am
lo
Are there any books that teach django for the most recent version out there? I
have not been successful at finding a book with up to date info
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To unsubscribe from this group and stop receiving ema
, ListView.as_view(
queryset=Post.objects.order_by('-date')[:25],
template_name="blog/blog.html")),
url(r'^(?P\d+)$', DetailView.as_view(model = Post,
template_name='blog/post.html')),
]
Do you see what I need to change?
On
ay, May 31, 2018 at 7:11:46 AM UTC-4, Mohammed Noor wrote:
>
> I think the mistake is using a '/' before the name inside href. Try
> changing it from href= '/contact'/ to href= 'contact/'
>
> Have a great day
>
> On 31-May-2018, at 9:26 AM, Caleb
, ListView.as_view(
queryset=Post.objects.order_by('-date')[:25],
template_name="blog/blog.html")),
url(r'^(?P\d+)$', DetailView.as_view(model = Post,
template_name='blog/post.html')),
]
Do you see what I need to change?
On Thursday
So i am trying to create a directory with a Home,Blog,and Contact
selection. But every time i click on one of them they all go back to the
home page. How do i fix this, and here is the secton of code below. let me
know if you need to see more
Home
Blog
Contact
I think it was because i did not use camel casing so CharField instead of
Charfield. I will continue the tutorial and see if that works
On Wednesday, May 30, 2018 at 10:04:04 PM UTC-4, Mike Dewhirst wrote:
>
> On 31/05/2018 11:45 AM, Caleb Bryson wrote:
> > I am getting a attribut
it is still saying "AttributeError: model 'django.db.models' has no
attribute 'Charfeild'
On Wednesday, May 30, 2018 at 10:04:04 PM UTC-4, Mike Dewhirst wrote:
>
> On 31/05/2018 11:45 AM, Caleb Bryson wrote:
> > I am getting a attribute error when i try to
I am getting a attribute error when i try to run my server. does anyone
know what i can change in this code to fix that?
from django.db import models
class Post(models.Model) :
title = models.Charfield(max_length=140)
body = models.Textfield()
date = models.DataTimeField()
def __str__(self):
re
it should be
>
> basic.html', {'content'
> Hope that helps!
>
> On 5/30/2018 5:45 PM, Caleb Bryson wrote:
>
> I can not seem to figure out what the syntax error is in line 7 of this
> code, can anyone help
>
> from django.shortcuts import render
> de
I can not seem to figure out what the syntax error is in line 7 of this
code, can anyone help
from django.shortcuts import render
def index(request):
return render(request, 'hybridair/home.html')
def contact(request):
return render(request, 'hybridair/basic.html' {'content' : ['contact the
tea
ote:
>
> View require that you return an HttpResponse object. Your function does
> not (it probably even lacks a "return").
>
> You need to return the response back in the view.
>
> On Tue, May 29, 2018 at 8:48 AM, Caleb Bryson > wrote:
>
>> Hey i am gett
n question.choice_set.all %}
{{ choice.choice_text
}}
{% endfor %}
and here is my result.html
{{ question.question_text }}
{% for choice in question.choice_set.all %}
{{ choice.choice_text }} -- {{ choice.votes }} vote{{
choice.votes|pluralize }}
{% endfor %}
Vote again?
On Monday, May 28, 2018 at 9:4
Hey guys, I am on part 4 of writing your first django app. And I am stuck
at the part where it says this "Now, go to /polls/1/ in your browser and
vote in the question. You should see a results page that gets updated each
time you vote. If you submit the form without having chosen a choice, you
So I am follow the instructions on the django site to make a poll. I am at
the current step where you run the server and everything went fine when i
typed in the command. But now it is just there at saying "GET /favicon.ico
HTTP/1.1" 404 1977 on the last command line. I was wondering should i wa
Hey I am new to python and i am trying to use django to make my first web
page. I know the basics of python but i am stuck on the step where you
start your app. i made sure i have a directory and have installed south to
help out but when i type "python mange.py startapp blog" it keeps giving me
16 matches
Mail list logo