Re: Error at the return of an AJAX POST in DJANGO

2020-10-25 Thread rbar...@xcaretresearch.com
Not sure, but looks like an extra closing bracket in line 9 of the ajax code On Sunday, October 25, 2020 at 2:05:28 PM UTC-7 wwran...@gmail.com wrote: > Hi buddies, I have a POST request from ajax. At the backend some records > are updated in the django view, this is done fine but an error comes

Re: Re: Path in First App, Part 3

2020-10-23 Thread rbar...@xcaretresearch.com
oh no, trying that ruined everything, now none of them work. I tried again, and now "votes' works but "results" doesn't.. Again, is there anyone who knows this code? On Friday, October 23, 2020 at 2:38:15 PM UTC-7 rbar...@xcaretresearch.com wrote: > Someone su

Re: Re: Path in First App, Part 3

2020-10-23 Thread rbar...@xcaretresearch.com
Someone suggest that I add "detail" to the urls.py code at path('/", view detail, name="detail" But that ruins everything. On Friday, October 23, 2020 at 2:32:19 PM UTC-7 rbar...@xcaretresearch.com wrote: > My guess is that the index url is supposed to return

Re: Re: Path in First App, Part 3

2020-10-23 Thread rbar...@xcaretresearch.com
quot; to the functions just to provide a return message for the. index page seems odd. But if I take it out, I get an error message in the code and it won't run. Hmmm. I wish I understood this. On Friday, October 23, 2020 at 2:24:55 PM UTC-7 rbar...@xcaretresearch.com wrote: > > Oh my

Re: Re: Path in First App, Part 3

2020-10-23 Thread rbar...@xcaretresearch.com
doesn't work for "detail". Is it supposed to be that way. On Friday, October 23, 2020 at 2:18:11 PM UTC-7 rbar...@xcaretresearch.com wrote: > Now I am in the situation where "votes" works but "detail" and "results" > does not work. So weird..

Re: Re: Path in First App, Part 3

2020-10-23 Thread rbar...@xcaretresearch.com
utorial, is what it supposed to do. Does anybody know this code? On Wednesday, October 21, 2020 at 1:04:26 PM UTC-7 Kasper Laudrup wrote: > Actually, I tried "votes" one more time and it did work. > > On 10/21/20 12:02 PM, Kasper Laudrup wrote: > > Hi rbar, > > > &g

Path in First App, Part 3

2020-10-21 Thread rbar...@xcaretresearch.com
I can get to .localhost:8000/polls. but not /polls/detail ror /votes or /results. Here is my code: ``` from django.urls import path from django.contrib import admin from . import views urlpatterns = [ #es: /polls/ path('', views.index, name='index'), # ex: /polls/5 path('/', views.detail, name=