I have some trouble trying to understand what you means by "content type".
That terms refer to the content of a file. For exemple, text/plain for
plain text file or image/png for an image encoded as png.
What you show look like a standard form. If you need basic pointer on how
to use a form, saving
text of an answer
> 0302 text of an answer
>
>
>
>
> On Monday, May 2, 2016 at 3:25:06 PM UTC+6, ludovic coues wrote:
>>
>> I have some trouble trying to understand what you means by "content type".
>&
I would use the browser developer tools to look at what JQuery is
sending to django in the submit event.
2016-05-02 18:01 GMT+02:00 carloratm :
> hello everyone,
> I am a frontend developer studying Django, so please forgive my noobish
> question...
> I am trying to make a simple ajax call working
> On Monday, May 2, 2016 at 4:25:13 PM UTC+6, ludovic coues wrote:
>>
>> You might want to add a foreign key in the answer model pointing to
>> the question.
>> Then in the view to show the form, create an answer object with it's
>> question FK assigned to the
Look like you aren't using the static tag for image and javascript url.
2016-05-06 19:20 GMT+02:00 Yakir Gabay :
> Hello I'm very new to Django and very confused
> I have basic familiarity with HTML.
> Hosted a website on my localhost, the CSS loads like I wanted however the
> images refuse to loa
If you hare a beginner, you should definitely take a good look at the
django tutorial. It's full of details you need to know to be effective
with django like ForeignKeyField, which let you write
user.Badge.Available = 0
2016-05-09 10:34 GMT+02:00 Biase D'Agostino :
> Hello,
> sorry for the questio
First virtualenv. The easiest way for you is to install Linux mint package
python-virtualenv.
Then you can use `virtualenv ~/.config/django_env` to setup your virtual
env. To use it, you need to activate it with the command `source
~/.config/django_env/bin/activate`. You need that command each tim
It should work better this way:
Save
the url template tag take a route name, not an url as it first argument.
2016-05-24 10:19 GMT+02:00 meInvent bbird :
> Reverse for 'reg/{{post.pk}}/' with arguments '()' and keyword arguments
> '{}' not found. 0 pattern(s) tried: []
>
> i follow django girl we
chapter about form.
[1] http://tutorial.djangogirls.org/en/django_forms/
2016-05-26 3:46 GMT+02:00 meInvent bbird :
> https://drive.google.com/file/d/0Bxs_ao6uuBDUQm5jOEdCOFowa0U/view?usp=sharing
>
> On Tuesday, May 24, 2016 at 9:07:25 PM UTC+8, ludovic coues wrote:
>>
>> It should
#x27;businessType': post.BusinessType, 'company': post.Company,})
>
>
>
>
> On Thursday, May 26, 2016 at 10:24:44 PM UTC+8, ludovic coues wrote:
>>
>> Have you done the django tutorial ? It help a lot when starting with
>> django.
>>
>> Yo
I will assume user can vote a specific article. I would go for another
model, like that
class VoteForArticle(models.Model):
DOWN = 0
NEUTRAL = 1
UP = 2
VOTES = ((DOWN, "down"), (NEUTRAL, "neutral)", (UP, "up"))
user = models.ForeignKey(settings.AUTH_USER_MODEL)
article = mo
There is two way to monitor the data.
Either passively, listening for each host saying hello on the network
or actively, probing for host at regular interval [1].
First way look like difficult as in requiring cooperation from diverse
host and relying on protocol like SNMP. Or you could listen for
Have you looked at the django documentation ?
There is a builtin form for creating a new user, working with user
model shipped with django.
https://docs.djangoproject.com/en/1.9/topics/auth/default/#django.contrib.auth.forms.UserCreationForm
2016-06-08 10:46 GMT+02:00 Arshpreet Singh :
> I am im
I'm pretty sure you can specify a widget to use in admin for each model and
field.
Part 7 of the tutorial will show you how to alter the admin without
changing the file in the virtualenv.
The documentation on ModelAdmin have an example of what you are trying to
do :)
+33614874342
On 8 Jun 2016 6:
> (function($) {
> 'use strict';
>
> })(django.jQuery);
This syntax is called a closure. First you declare a function so you
don't contaminate the global scope with your local declared variable.
Then you execute your function.
I will assume django.JQuery is the version of JQuery shipp
The django girls tutorial is also a very good ressource for beginner.
http://tutorial.djangogirls.org/
2016-06-11 23:45 GMT+02:00 Lee Hinde :
> https://leanpub.com/tangowithdjango19/
>
>
> On Jun 11, 2016, at 2:07 PM, Gary Roach wrote:
>
> If you don't mind working with Python2.7 and Django 1.7 y
The "Python Crash Course" aim to teach python from nothing in the
first half and to put that knowledge in application in the second half
through 3 projects. These are a 2D game, some data visualization
technique from diverse source and a django application.
Some people have some difficulty with th
I don't understand what you are trying to do.
base(request) create a response for the browser using j and a to
render base.html.
If you want to have access to j and a in both index.html and
list.html, try this:
def base(request):
j = Job.objects.all()
a = Ab.objects.all()
return {'j':j
that's the expected result at this point.
2016-06-16 7:43 GMT+02:00 Tushar Shukla :
> iam doing this tutorial and i cant get the final result no matter what i do
>
> iam using pycharm. please help i have attached the error page
>
> On Saturday, 11 June 2016 23:57:33 UTC+5:30, Derek wrote:
>>
>> Th
Can you post the INSTALLED_APPS part of your settings.py ?
2016-06-17 21:01 GMT+02:00 'antanas skiudulas' via Django users
:
> I'm a newbie trying to make a wiki page with Django, however, I keep running
> into this very annoying problem:
>
> NoReverseMatch at /wiki/page/Start/ Reverse for '' with
Python 3 have a better support of international alphabet.
2016-06-20 23:44 GMT+02:00 Xristos Xristoou :
> hello i want to use choices in my field but not work if i write in my
> language(greek) only work in the england language.
> if i writing choices in my language show me error message in the ad
Have you tried {{item1|pprint}} ?
Or to check the raw page, not the one displayed by the brother ?
I got bitten more than once by brother not displaying variable whose
value looked like
2016-06-22 20:31 GMT+02:00 :
> Hello everyone,
>
> I am trying to do the following:
>
> Grab Year/Month values
Do you have extra good reason to call hashlib function with a variable
called password ?
If you simply want to hash user password, django provide a few
function for that job [1].
it's used like that:
>>> from django.contrib.auth.hashers import make_password, >>> check_password
>>> pwd = make_pass
Django 1.9.7 is compatible with python 2.
Django 1.11 is planned to be last version supporting python 2, the last
version for django 1 and will be on long term support.
Only django 2 will drop support for python 2.
For the original question, the issue seems related to salute. The content
of setti
virtualenv venv
source venv/bin/activate
pip install django
pip freeze > requirements.txt
django-admin startproject tutorial
cd tutorial && python manage.py runserver
Assuming you have python and virtualenv installed on your machine. At
this point, you have:
* a virtualenv inside the folder venv
The virtualenv folder should not be your root folder.
It's a separate folder. You can keep them all in a single location or
put each of them in a subdir of your projet.
You start using a virtualenv with "source venv/bin/activate". After
this, the current terminal will use the virtualenv in the fol
;
> On Sunday, June 26, 2016 at 11:13:20 AM UTC-5, ludovic coues wrote:
>>
>> The virtualenv folder should not be your root folder.
>
>
> it's not. VirtEnv is base. VirtEnv/mysite is the virtualenv. this is
> where manage.py is located then VirtEnv/mysite/mysite and
It's not that the framework will come to an halt. It's that a server
serving static file directly would be an order of magnitude faster.
https://unix4lyfe.org/time/hn.html is a nice article on how server
react to heavy load when serving static file.
2016-06-27 18:26 GMT+02:00 Ankush Thakur :
> I
I would separate user and account.
User is one person and is used to connect.
Account have newsfeed and follow other user.
Each user can manage as many account as he want.
Many user can manage the same account.
All that can be transparent to your user if you setup an account
matching the user for
https://docs.djangoproject.com/en/dev/releases/1.11/
"The Django 1.11.x series is the last to support Python 2. The next
major release, Django 2.0, will only support Python 3.5+."
But your point remains valid.
It make more sense to use python 3 as it will be the only option
available soon and som
We can't help you because we have to watch a gif at least 5 seconds long
and the error message stay on screen less than half a second.
If you could past the content of your term at the end of the gif, we could
help you.
thanks.
2016-07-02 12:59 GMT+02:00 Ricardo Valério :
> *I'm following the o
I could ask you what error you get when running syncdb. I could tell
you to use manage.py createsuperuser.
But the best advice anyone can give you is to do a tutorial about
django. The django girls one is really great. The one from the
official documentation is shorter. Either one will give you a s
try to add that
## {{ airlines|pprint }}
If it show `## ''` in the page, airlines is not defined in the template context.
2016-07-06 12:21 GMT+02:00 :
> Hi,
> I have a model and whould like to create a dropdown menu from the fields
> generated.
> Unfortunately no dropdown list is showed:
>
>
You want a value to identify a specific job, different from the
job_id, to put in the url.
I would add a slug field in the model and use that.
The slug could be derived from the job title, maybe concatenated to an
UUID for uniqueness or simply an UUID different from the id.
If you are using views
"## {{ airlines|pprint }}" can't display a dropdown menu.
It's a debug tool.
It's supposed to show two # symbol so you know you are editing the
right template then it should display a python representation of what
airlines is.
If things work as expected, you should have something like that in the p
If the image is displayed, the user can use a screen capture tool to get it.
You can make it harder for your user to get the image by putting a
transparent image on top of the displayed image. You can put the image
as a background on a div. You can cut the image in many part and
display a grid of
A full stacktrace and the content of urls.py would be nice.
2016-07-09 13:46 GMT+02:00 :
> I tried my best to solve this but i couldn't please help me
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To unsubscribe from this group and s
After reading your message, I don't know what the app should do, and
what happen currently.
I don't know if there is an error or not. Some part are missing like
the imports, app_name in urls.py or the url for message_board:list.
As a sidenote, I will suggest you to look the authentication views [
Have you done the django tutorial ?
Part 7 [1] Should answer your question.
[1] https://docs.djangoproject.com/en/1.9/intro/tutorial07/
2016-07-09 18:03 GMT+02:00 :
> I have a 2 Models, Product and Image. Image has a foreign key to Product.
>
> In the form I want to appear information from both
forms/modelforms/#inline-formsets
2016-07-09 21:47 GMT+02:00 ludovic coues :
> Have you done the django tutorial ?
>
> Part 7 [1] Should answer your question.
>
> [1] https://docs.djangoproject.com/en/1.9/intro/tutorial07/
>
> 2016-07-09 18:03 GMT+02:00 :
>> I have a 2
What are you trying to do ?
Where do you want to import your js code ? Why do you want to do it ?
What are you trying to achieve ?
2016-07-10 15:06 GMT+02:00 Seti Volkylany :
> After googling in the Web, I don`t found clean solution for it.
>
> --
> You received this message because you are subscr
Have you checked you didn't put a space between 'account: and
resetPasswordSendMail' ?
2016-07-10 6:49 GMT+02:00 Ajo Thomas :
> I am getting the error mentioned in the heading. The reverse url is
> working perfectly everywhere in the html code except in the form action
> part. The code works per
First, you need a model to store the data in the database.
Then, you can use a CreateView as explained at [1].
You should have something like that at the end.
models.py:
from django.db import models
class User(models.Model):
name = models.CharField(max_length=128)
newsletter = models.Bool
My go to solution for that king of problem is to append a query
argument. If the browser have a cached version of sound.wav?v=1 but
you serve sound.wav?v=2, the browser should grab the last version,
even if the file is still named sound.wav.
For your second point, you could use BytesIO, from the i
Any chance the big time difference come from the difference between
SSD and mechanical drive ?
2016-07-11 7:00 GMT+02:00 Krishna Bharadwaj :
> Fred,
>
> That's very good to know. At least it tells me that the number of imports
> could be one of the main reasons for the slow down. And I apologise f
Do you define BASE_DIR and STATIC_URL in your settings.py file ?
2016-07-11 23:56 GMT+02:00 Malik Rumi :
> Well, I'm stuck again. I am still trying to get my dev site to work with
> this new bootstrap theme. Debug toolbar is telling me over 1,000 staticfiles
> have been found, but none were used.
Assuming you have created a virtual env with `virtualenv myvenv`
* activate the virtualenv: `source myvenv/bin/activate`
* install django: `pip install django`
* create a django project: `djang-admin startproject myproject`
* move into that project: `cd myproject`
* create an app for your pr
Code would be more useful to understand what is happening.
Or you can use the django test client [1] to see what the view is
returning as context. The list of event might be empty.
[1]
https://docs.djangoproject.com/en/1.9/intro/tutorial05/#the-django-test-client
2016-07-12 16:49 GMT+02:00 Cron
If you are using
https://github.com/sandlbn/django-bootstrap-calendar/, I assume you
have changed some things. For exemple, the module don't come with an
admin.py file.
All your change would be nice so we can replicate your problem :)
2016-07-13 22:33 GMT+02:00 Cronos Cto :
> Hello Ludovic, what p
A JS library like Jquery or plain javascript.
Listen to event, intercept & cancel them, make the query to django,
insert or remove the appropriate item.
2016-07-13 20:25 GMT+02:00 J Singh :
> I want functionality such as add/delete line items to an order , do not want
> a form resubmit every time
I haven't managed to reproduce your error. In fact, I managed to make
it working.
What output do you get when you hit
http://localhost:8000/calendar/json/?from=146532400&to=149000240
? Adjust the hostname and port to your dev server.
2016-07-14 11:54 GMT+02:00 Cronos Cto :
>
>
>
> Yes htt
You have no variable named PROJECT_DIR your file pressmedia/pm/settings.py.
You might want to remove os.path.join as you already specify the full path.
2016-07-14 17:16 GMT+02:00 Michael Schintler :
> Hi all ,
>
> I m sorry but new to Django and after some learning i came to Jet Admin
> Backend. A
The error should come with a backtrace. Providing the backtrace will
help a lot in finding the error.
2016-07-15 19:52 GMT+02:00 Elros Romeo :
> Hi, i hope you can help me, im trying to make a django post form without
> reloading the page using ajax, but im getting error 500 when submit, can you
>
The code of your model would be more interesting. According to the
error, Post have no method get_absolute_url. That method isn't
provided by models.Model, you have to write it. A way to do it is like
that:
from django.db import models
from django.urls import reverse
class Item(models
It depends on how django and node JS interact together, what they are
used for, etc...
2016-07-18 18:58 GMT+02:00 Arindam sarkar :
> I have a situation where I want to use django with node JS my problem is how
> do I share user session data among django and notes server?
>
> --
> You received this
o
> for the logged in user
>
>
> On Jul 18, 2016 10:39 PM, "ludovic coues" wrote:
>>
>> It depends on how django and node JS interact together, what they are
>> used for, etc...
>>
>> 2016-07-18 18:58 GMT+02:00 Arindam sarkar :
>> >
How do you "open the webpage" ?
2016-07-19 6:10 GMT+02:00 Jose :
> I was watching a Django tutorial video and on the video the guy writes the
> exact same code I have on the picture. In the video whats inside of his
> curly brackets turns to purple. Mine does not turn purple and there is
> somethi
Also, a copy of the error would help us a lot to help you.
2016-07-19 14:52 GMT+02:00 ludovic coues :
> How do you "open the webpage" ?
>
> 2016-07-19 6:10 GMT+02:00 Jose :
>> I was watching a Django tutorial video and on the video the guy writes the
>> exact same
This kind of captcha is easier for bot than it is for human.
This one is especially weak. Single font, Single color for the text.
And the more noise you add on the text, the harder it will be for
human.
https://github.com/ptigas/simple-captcha-solver is a basic tool for
solving these.
I strongly
Like it have been said, it look like there is no object with id 2.
If you want more details, you'll need to share the content of your
view function.
2016-07-19 20:21 GMT+02:00 Sergiy Khohlov :
> Looks like you have deleted artist with Id#2.
>
>
> 19 лип. 2016 18:21 "Jose" пише:
>
>>
>>
>> On Tu
You might have noticed, the calendar view is a generic template view.
It only display an html page.
All the work is done with js. If everything work fine, it fetch the
list of even for the period with ajax and add the event in the
calendar.
/calendar/json should return the list of event. As you ca
it shouldn't be too hard to port it to python3. The module is mainly
javascript, not python.
Once the app can return json, it should work fine.
2016-07-20 20:40 GMT+02:00 Cronos Cto :
> That explains alot of the issues I am having. Since it is a compatibility
> issue, I am guessing there is no
Generic Foreign Key solve a very specific problem. Foreign key to
arbitrary models. Like a tagging system, with the ability to set a tag
to user, article, comment, media in a blog.
For your use, as long as no models can link to notes or counties and
not both, simple foreign key are fine.
And even
ally if I am using the county Foreign key in a few different models
> I am fine. I am not sure what you meant by this
> "as long as no models can link to notes or counties and
> not both, simple foreign key are fine."
>
>
> On 21 July 2016 at 11:13, ludovic coues wrot
https://docs.djangoproject.com/en/1.9/topics/db/examples/many_to_many/
Each student can subscribe to more than one newsletter
Each newsletter have many of students.
2016-07-21 15:20 GMT+02:00 Ant :
> Being a Django "newcomer" I am hoping someone can help us with this simple
> problem.
>
> We h
Est-ce que l'erreur survient aussi si la commande est lancé sans sudo ?
Dans un virtualenv, sudo ne devrait pas etre utilisé, on travail avec
des fichiers que l'on a crée, dans notre dossier personnel.
2016-07-24 16:17 GMT+02:00 :
> Can You, please, in English describe what a problem You have? I
$.get look a lot like Jquery.
Do you mind to share what version you are using ? You can find out with
`alert($.fn.jquery)`
2016-07-25 16:34 GMT+02:00 Gergely Polonkai :
> This sounds to be a JavaScript problem, which is not part of Django in any
> ways.
>
> My idea, however, is that you don’t im
You are suggesting to alter the django library directly. This as two
immediate bad effect.
First, it make upgrading to newer and more secure version of django
harder as the change will be overwritten by the upgrade.
Second, if you want to keep your track of your change, using git for
exemple, you
In /home/ariatel_web/dashboard.ariatel.com.co/apps/did/forms.py, replacing
country = forms.ChoiceField(choices=[ (d.country_name,
d.country_name) for d in DidCountry.objects.filter(is_active=True) ]
with
country = forms.ChoiceField(choices=lambda: [ (d.country_name,
d.country_name) for d i
Hello,
I am trying to test if a view is displaying a form with an input
element with name=username.
Currently, I have tried a lot of variation around
`self.assertContains( response, "",
html=True)` but none work.
I assume that doesn't work because the view have a field input with
name=username bu
ldset = """
"""
self.assertInHTML('', fieldset)
self.assertInHTML('', fieldset)
First input is to have a working exemple, second is taken as is from
my view. Not closing the input in assertInHTML give an error `Couldn't
find ':
html element, not
the raw content returned by the view. I'm quite uneasy to have the
test failing if a class is added or removed from the element. But yes,
your solution work for the current state of the application.
2016-07-31 14:46 GMT+02:00 Andreas Kuhne :
> 2016-07-31 13:56 GMT+02:00 ludov
/accounts/login')
self.assertEqual(response.status_code, 200)
doc = etree.HTML(response.content)
self.assertEqual(len(doc.findall('.//input[@name="username"]')), 1)
2016-07-31 17:46 GMT+02:00 Andreas Kuhne :
> 2016-07-31 15:59 GMT+0
Look like you forget to indent the method inside your class.
2016-08-01 13:43 GMT+02:00 Neil Hunt :
> I've read and reread the tutorial and I'm working on writing a very simple
> banking app by copying and modifying what's in the tutorial. I've started a
> new project and copied what was on the fi
A models file might use a lot of class from the django.db.models
module and importing each class lead to lengthy import line. That's
might be one reason.
The better reason might be that a lot of these class are named the
same in django.forms and django.db.models. When you type
models.CharField, you
You could use an alternative way to login the user, transparent to the
user. Like giving a token to the app when it login.
2016-08-01 18:17 GMT+02:00 Larry Martell :
> I have a view that is accessed both from the browser and from a
> non-browser app. The request from the non browser app come from
The session cookie ?
Or you could use another decorator or a middle-ware doing
authentication based on the ip and some information passed as get
argument. Like a token returned by django when you auth the user.
The request hit the new decorator, the decorator notice the user isn't
logged in and t
Or, you could read either this thread or the doc and take advantage of
the django taking care of you.
Quoting the doc: "If the [choice] argument is a callable, it is
evaluated each time the field’s form is initialized."
That's why I suggested to add "lambda: " before the list
comprehension. To turn
Have you added your app to the INSTALLED_APPS setting ?
2016-08-05 10:05 GMT+02:00 Dimitris Tsiktsiris :
> Here are my view and urls
> app url
> app_name = 'profs'
> urlpatterns = [
> url(r'^$', views.index, name='index'),
> url(r'^contact/', views.contact, name='contact'),
> url(r'^ch
If you haven't done a django tutorial, I highly recommend doing one.
http://tutorial.djangogirls.org/ is really friendly for beginner but
you can do the official one at
https://docs.djangoproject.com/en/1.10/intro/tutorial01/.
if you want more help than that, sharing what you have tried is a good
What you are writing is not valid python syntax.
Here is the problematic code:
urlpatterns += urlpatterns['matricula.views.Courses',
url('^courses$', list_courses, name='courses'),
url('^course/(?P\d+)$', view_course,
name='course'),
That sound like a python problem. How to open a file and write in it.
2016-08-10 12:46 GMT+02:00 Asad ur Rehman :
> I want to create xlm file in django in this path
> "etc/freeswitch/sip_profiles/external" .
>
> Gateway.objects.values_list('name')
>
> this should be included in file. How can i cre
I'm pretty sure talking about telepathy was rude, outside the django's
code of conduct and some excuses would be nice.
The question make a lot more sense with an exemple :)
I assume Gateway is a django model (I missed that first time, sorry)
and you want to fill an xml file.
Do you mind to share
these files should be in the directory learning_log (inner) inside
another learning_log (outer) directory.
manager.py should be in the outer directory.
2016-08-10 17:40 GMT+02:00 Lov Verma :
> In order to create a new project, I'm using this command:
>
> django-admin.py startproject learning_log
Could you detail a bit more what you are trying to achieve ?
What do you mean by "integrating" ? What step have you tried ? Are you
new as in "have never read a single page of the documentation" or new
as in "have only done a pair of small test site" ?
I have trouble do understand what you are tr
if what you are doing is a quote, you don't need to get the total from
the user. I would go one step further, don't get price from the user.
Form can be altered.
I would do the model like that:
class Invoice(models.Model):
user = models.ForeignKey(User, models.CASCADE)
date =
Or it is just you ;)
Why don't you use a less baity title and tell us what is your problem.
What are you trying to do, what have you tried, what is the result,
what does the models look like...
Sometimes, all you need is someone new looking at you code.
2016-08-15 11:03 GMT+02:00 Daniele Procida
This is the doc you are looking for
https://docs.djangoproject.com/en/1.10/ref/csrf/#ajax
2016-08-15 12:42 GMT+02:00 Saeon Tao :
> LoL, thank you everyone! please forgive, i was just having a moment with
> django... you understand, im a real makebelieve hotshot when it comes to
> php, but now with
forms.Form are python class representing an HTML form. You use them to
ask data to your user. Nothing more.
models.Model are python class representing an entry in your database.
You create them in python, always.
Sometimes, you use a form by itself. For exemple, a login form will
ask data, search
Do you have any error with the code you posted ?
It look like you already have a foreign key to your user.
2016-08-17 15:33 GMT+02:00 Shamaila Moazzam :
> Hi,
>
> I am a beginner and please forgive me if my question is not up to the
> standard. I've got two models one is Product which is saved in
Could you share your admin.py file ?
You might be interested into this part of the documentation:
https://docs.djangoproject.com/en/1.10/ref/contrib/admin/#django.contrib.admin.ModelAdmin.formfield_for_foreignkey
2016-08-17 17:20 GMT+02:00 Shamaila Moazzam :
> @Ludovic there is no error. Just I d
.register(ProductImage)
>
>
> admin.site.register(Category)
>
>
> admin.site.register(ProductFeatured)
>
> admin.site.register(color_product)
>
> admin.site.register(size_product)
>
> On Wednesday, August 17, 2016
r this?
>
> Just curious.
>
> Regards,
> Mudassar
>
>
>
>
>
>
> On Wed, Aug 17, 2016 at 2:37 PM, ludovic coues wrote:
>>
>> Ok, sorry, I made a off by one error on the link :)
>>
>> Try that:
>>
>> # shops/admin.py
>> from djan
You might be looking for this
https://docs.djangoproject.com/en/1.10/howto/custom-template-tags/
2016-08-18 12:57 GMT+02:00 Paul Aswa :
> Is there means of encoding an id using hashids in django templates?
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django
Who did you created this ?
Have you run `django-admin startproject mysite` ?
2016-08-18 10:41 GMT+02:00 Ziggo mail :
> Hi There
>
> I’m busy with starting with django.
>
> My first mysite shows me this:
>
> mysite/
>
> manage
>
> mysite/
>
> __pycache__
>
> __init__
>
>
template. The doc have more information on the
subject.
2016-08-18 19:37 GMT+02:00 Paul Aswa :
> Being a newbie to python and django, this seems to be giving me problems
>
> On Thursday, August 18, 2016 at 2:57:56 PM UTC+3, ludovic coues wrote:
>>
>> You might be look
You should add a foreign key to language on translation. To save the
language from the dropbox.
Then I would create a ModelAdmin and set the form value. If I remember
correctly, the save method is on the form and you could save new objet
for each word at the same time as saving the translation obj
You were calling the method in the class definition. The class is
"defined" when the module is imported. That's why things where
"cached". Module is imported only once.
The init method on the other hand is called every time an instance of
the class is created. I believe that method will be called i
You need to check somewhere that the category exist and that your item
belong to the category.
The get object method seems like a good place to do it. Something like
that should do the trick
def get_object(self, queryset=None):
""" Return a 404 code if
* no link with given
Do you have any message in the console where you run "python manage.py
runserver" ?
2016-08-21 12:16 GMT+02:00 Jordi Fernandez :
> hi,
>
> I have my firts application django it's fine. . But! I have a problem with a
> simple form. I think this is a problem the my experience of all entorn (
> htm
1 - 100 of 313 matches
Mail list logo