On 6/26/07, leif <[EMAIL PROTECTED]> wrote:
> My main problem, though, is figuring out how to create a text input
> lookup field for the ZIP code foreign key.
> Do I need to code a new
> widget? A new form field class? A function to hook into newforms'
> validation?
> And if I create a widget
Check it out: www.BrandonsMansion.com
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send
On 6/26/07, Rand Bradley <[EMAIL PROTECTED]> wrote:
> This is occurring wherever I test a redirect. If I comment out the admin
> line in urls.py , the errors disappear. I am on the latest development
> version to date (5541).
>
> Any insight or help would be greatly appreciated! Thanks.
Looking
Hi Kyle, I've run into the same problems before. I think you'll find
Django admin is great for simple operations involving single records
and the most basic relations. But for anything beyond that, you'll
probably need to roll your own admin page.
On Jun 25, 1:15 am, Kyle Fox <[EMAIL PROTECTED]>
On Tue, 2007-06-26 at 11:22 -0700, robo wrote:
> Hopefully you guys can spot an error I've not been able to. This is
> the error I get:
>
> AttributeError at /vendor/Chef/1/
> 'Order_DetailForm' object has no attribute 'save'
> Request Method: POST
> Request URL:
On 6/26/07, Michal <[EMAIL PROTECTED]> wrote:
>
> Hello,
> I try to write test together with coverage [1]. This tool could tell me,
> which lines of code was or wasn't executed and therefore tell, how my
> tests are (or aren't) "superior".
>
> I put initial code for coverage into setUp, and
On Tue, 2007-06-26 at 18:12 +, Justin wrote:
> I've just been screwing around with my urlpatterns, trying to clean
> them up. Mostly, I've been trying to remove all hard coded urls
> wherever they are, in templates and whatnot, by adding a name="foo" to
> my urlpatterns and then accessing
On Tue, 2007-06-26 at 16:34 +, Charles Wesley wrote:
> I want a model where a single table has two OneToOne fields pointing
> back to another table. Here's the trivial example:
>
>
> class Trivial(models.Model):
> pass
>
> class Multiple(models.Model):
> one_trivial =
On 6/25/07, rob <[EMAIL PROTECTED]> wrote:
>
> We upload all of our images via the Admin app and would like all
> uploaded images to be renamed to a set of numbers. We can generate the
> random numbers fine, but is there an easy way to rename the file once
> it's uploaded in the Admin app?
Not
On 6/22/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
>
> Hi,
>
> Since serializer has query set as parameter. If data is not query
> from database, How to construct data structure (query set) and pass to
> serializer ?
The Django serializers accept any iterable, not just query sets. You
On 6/21/07, Dirk van Oosterbosch, IR labs <[EMAIL PROTECTED]> wrote:
>
> On 20-jun-2007, at 22:19, SanPy wrote:
>
>
> File and image uploading for newforms, AFAIK, is not implemented in
>
> 0.96. There is a ticket for this (#3297). If you look in the django-
>
> developers newsgroup and search
On 6/20/07, Chris Brand <[EMAIL PROTECTED]> wrote:
>
> I'm running into problems with the test client's login method.
> Specifically, within a single test method, the first login succeeds but the
> second one fails.
> Is this something that should work ? Am I doing something wrong ?
Apologies
Very good point, Tim. I'll consider that issue as I move forward with
my application.
My main problem, though, is figuring out how to create a text input
lookup field for the ZIP code foreign key. Do I need to code a new
widget? A new form field class? A function to hook into newforms'
> My question, then, is this: What's the most elegant way to
> pull off this hack? By the way, I am using newforms and the
> newforms-admin branch. (I want my customizations to work with
> 1.0 and beyond.)
Generally, zip-codes and cities have a one-to-one correspondence.
However, this isn't
Hi there. I'm new to Django and Python, so I appreciate any help you
guys can provide.
I am working on an app that allows a user to create extended profiles
with text and photos. In addition, each profile is associated with a
single ZIP code via a ForeignKey.
As it stands now, the admin
On Jun 27, 12:59 am, "Vladimir Pouzanov" <[EMAIL PROTECTED]> wrote:
> Hi all,
>
> I'm running several django sites on lighttpd server. Sites are simple
> and I don't like the idea of spawning so much python processes that
> eat my precious memory. Is it possible somehow to run several sites in
>
By the way, I did find the hook in django/branches/newforms-admin/
django/contrib/admin/options.py for specifying the form field for a
given database field. But that's different than allowing a developer
to specify the widget for a given field in the model itself.
Replying myself to add some information and ask some extra questions.
I just had contact with the maintainer of my shared host. He warned
that memory exceeding the (shared usage) limit could cause strange
errors. And that memory usage should be dealt with carefully.
He adviced me to save the
On Jun 26, 11:00 pm, "Nimrod A. Abing" <[EMAIL PROTECTED]> wrote:
> On 6/26/07, Malcolm Tredinnick <[EMAIL PROTECTED]> wrote:
>
> > I don't want to sound discouraging, but if the answer is at all critical
> > to your operation, you can't trust any numbers you get here. They will
> > not have the
On 6/25/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
> Ben Ford is working on merging in changes from the trunk in with the
> branch... at this time neither he or myself ( I had planned on doing
> this but found he was farther ahead of me ) have commit permissions to
> the project... but
> However, because the theme names aren't unique and there can
> be multiple themes with the same name associated with
> different categories, it makes it impossible to choose the
> correct theme when adding an image.
>
> For example, if I have the following categories and themes:
>
> Contact
Thanks for the help - I actually read abount unique_together shortly
after creating this post. I did have one more question, however.
Each theme has a number of images associated with it (with an Image
model and a theme ForeignKey), so naturally when you go to add an
image via the Admin app,
I am trying to get http://svn.zyons.python-hosting.com/trunk/
working under the current django svn. I'll send .patch to zion's way when I am
done.
I need a recommendation from someone who has an understanding of what this code
does. (I could probably hack it into submission, but that's not
On Tue, 2007-06-26 at 19:58 +, Justin wrote:
> On Jun 26, 12:12 pm, Justin <[EMAIL PROTECTED]> wrote:
> > I'm wondering though, is it possible to use reverse() and pass it some
> > args, to use it as the post_save_redirect in generic views?
>
> On second thought, this is kind of a stupid
> I have a "Category" and "Theme" table. Each category can have a number
> of themes, and while a theme with the same name can belong to
> different categories, more than one theme with the same name shouldn't
> belong to the same category. I'm having a hard time figuring out how
> to set this up
> class Category(models.Model):
> name = models.CharField(maxlength=50, unique=True)
>
> class Theme(models.Model):
> category = models.ForeignKey(Category)
> name = models.CharField(maxlength=50, unique=True)
>
> And an example of what I'd like:
>
> This obviously doesn't work
I have a "Category" and "Theme" table. Each category can have a number
of themes, and while a theme with the same name can belong to
different categories, more than one theme with the same name shouldn't
belong to the same category. I'm having a hard time figuring out how
to set this up with
On Jun 26, 12:12 pm, Justin <[EMAIL PROTECTED]> wrote:
> I'm wondering though, is it possible to use reverse() and pass it some
> args, to use it as the post_save_redirect in generic views?
On second thought, this is kind of a stupid thing to do in the first
place... why would I want to avoid
On Jun 25, 7:30 pm, Francis Lavoie <[EMAIL PROTECTED]> wrote:
> OperationalError: unable to open database file
An addition to the page that Ramiro pointed to: the webserver user
needs (at least) execute permission (d--x--x--x) on every directory
below the one that holds the database file.
Hopefully you guys can spot an error I've not been able to. This is
the error I get:
AttributeError at /vendor/Chef/1/
'Order_DetailForm' object has no attribute 'save'
Request Method: POST
Request URL: http://192.168.1.104:8000/vendor/Chef/1/
Exception Type: AttributeError
Exception Value:
Good Luck and have fun.
Make sure you post all your pictures on www.tabblo.com (a django site
of course).
J
On Jun 25, 9:20 pm, Kelvin Nicholson <[EMAIL PROTECTED]> wrote:
> Dear Djangoers:
>
> I have thoroughly enjoyed the last few months on this list, yet I must
> take a temporary leave.
Upgraded mod_python to latest version and upgraded python 2.4.x ...
problem gone away.
Go figure.
Thanks all!
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send
I've just been screwing around with my urlpatterns, trying to clean
them up. Mostly, I've been trying to remove all hard coded urls
wherever they are, in templates and whatnot, by adding a name="foo" to
my urlpatterns and then accessing them with {% url %} and reverse().
I'm wondering though, is
Thanks again guys - you guys are awesome!
On Jun 26, 1:49 pm, Christian Markwart Hoeppner <[EMAIL PROTECTED]>
wrote:
> > Apparently the mysite.fcgi file was not being automatically created
> > when I used the fcgi startup script to start the site. So I went into
> > the directory and did a
Hello,
While looking at the Lost Theories source code (thanks Jeff Croft!) I
saw he's using what looks like a real handy library called "taglib".
I can't find taglib and it may well be a personal library.
But one use case caught my eye:
In theories/theory_list.html he's defining a "paginator"
> Apparently the mysite.fcgi file was not being automatically created
> when I used the fcgi startup script to start the site. So I went into
> the directory and did a `touch mysite.fcgi` then a good old chown
> lighttd:lightd mysite.fcgi and it a magical thing happened - it
> started working.
hello,
i remember i got this error when i tried to save a file because my
database's auto field sequences were not set up correctly. i am using
postgresql and i use fixtures to populate the database. so there were
a bug in fixtures that did not set sequences in postgresql correctly
(i think it
Hey Just and update:
Apparently the mysite.fcgi file was not being automatically created
when I used the fcgi startup script to start the site. So I went into
the directory and did a `touch mysite.fcgi` then a good old chown
lighttd:lightd mysite.fcgi and it a magical thing happened - it
On 6/26/07, Carl Karsten <[EMAIL PROTECTED]> wrote:
> didn't grep enough:
>
> django/contrib/contenttypes/generic.py:
> class GenericForeignKey()
>
> How do I 'use' generic.py ?
Just change the import. There was a backwards incompatible change made
to Generic keys recently, and I guess Ian
HI Thanks for the reply - I really appreciate it. The problem however
still occurs:
Here's whats happening:
1. user "apache" is added to group "lighttpd"
2. when I chmod 777 it seems to work
3. when I change the file permissions back and save using the django
admin the 500 errror occurs. but i
I want a model where a single table has two OneToOne fields pointing
back to another table. Here's the trivial example:
class Trivial(models.Model):
pass
class Multiple(models.Model):
one_trivial = models.OneToOneField(Trivial,
related_name="one_trivial")
two_trivial =
I managed to solve this:
from Manager.utils.newforms import TemplatedForm
Thanks for the help!
Ana
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to
El mar, 26-06-2007 a las 08:14 -0700, john-f escribió:
> Hi all,
>
> I'm getting 500 errors when trying to upload a image file with the
> django admin.
> I think this has to do with user/group permissions on the media
> directory (currently they are owned by lighttpd:lighttd)
> Does anyone know
I am using MySQL. Thanks for clearing that up!
charles
On Jun 25, 3:02 pm, Brian Rosner <[EMAIL PROTECTED]> wrote:
> On 2007-06-25 14:10:30 -0600, Charles Wesley <[EMAIL PROTECTED]> said:
>
>
>
>
>
> > Hello,
>
> > I'm a Django newbie, and I'm trying to set up a model that includes
> > the
Hi All,
I deployed an app with uploading functionality to a server running
FastCGI.
When I had it tested by my users, the site became completely
unresponsive, returning nothing but Error 500's.
In the log I find a lot of these:
Unhandled exception in thread started by >
Traceback (most
First check your browser settings. Is javascript enabled? Clear your
cache and then see if you can still load the js files directly. When
faced with situations like this I like to use the "Live HTTP Headers"
extension for Firefox to see whats really going on. Of course, you
could always avoid the
Hum... I tried to test the imports on IDLE but I couldn't import the
file in anyway I tried..
I went to the Path Browser on IDLE and I couldn't find the
newforms.py file that I created. I then noticed that in all the other
folders there was a file named __init__.py, so I copied one of those
init
ok, I'll do that. thanks
-E
On Jun 26, 5:13 am, Malcolm Tredinnick <[EMAIL PROTECTED]>
wrote:
> On Mon, 2007-06-25 at 16:10 +, abe wrote:
>
> > I'm using the newforms-admin branch, and have specified
> > some admin options for a Experiment model like this
>
> > class
Christopher schrieb:
> class Menu(models.Model):
> display_text = models.CharField(maxlength=50)
> url = models.URLField(verify_exists=False)
> parent_menu_item = models.ForeignKey(Menu)
>
> totalimpact.menu: name 'Menu' is not defined
"""
If you need to create a relationship on a model
This gets even more weird.
I copied the send_mass_mail() code from django.core.mail into my
module so I could orchestrate it.
I changed the DNS_NAME lookup to a hardcoded string and then got the
15s delay on the smtplib.SMTP(settings.EMAIL_HOST,
settings.EMAIL_PORT) line?!
So, perhaps the
Hi all,
I'm running several django sites on lighttpd server. Sites are simple
and I don't like the idea of spawning so much python processes that
eat my precious memory. Is it possible somehow to run several sites in
one fcgi server?
--
Sincerely,
Vladimir "Farcaller" Pouzanov
This is probably a zyons problem, but maybe someone here can help this nifty
project.
[EMAIL PROTECTED]:~/django/zyons/zilbo$ ./manage.py syncdb
Error: Couldn't install apps, because there were errors in one or more models:
zilbo.common.comment: 'module' object has no attribute
On 26 Giu, 16:24, "va:patrick.kranzlmueller"
<[EMAIL PROTECTED]> wrote:
> see:http://code.djangoproject.com/wiki/PyCallTag
>
> patrick
>
Really really bad (and OT). Please don't encourage the use of this
tag, it breaks MVC. Never mix html with programming logic.
On 6/26/07, Moses Ting <[EMAIL PROTECTED]> wrote:
>
> That's what I thought, but running the following command via a web
> request returns lines of length 0.
>
> command = 'c:\path\plink -ssh [EMAIL PROTECTED] -pw password dir'
> lines = os.popen(command).readlines()
>
> The exact command works
> That's what I thought, but running the following command via a web
> request returns lines of length 0.
>
> command = 'c:\path\plink -ssh [EMAIL PROTECTED] -pw password dir'
> lines = os.popen(command).readlines()
A couple things I'd check:
1) use raw strings when subjecting yourself to DOS
Dear Django web developers,
I'm currently part of a research team at the Free University of
Berlin, looking into the ways in which the major web development
platforms differ. In addition to our work with the Plat_Forms contest,
we're now looking for some actual professional opinions.
If you
sorry, didn´t read carefully enough.
the cookbook example refers to a template (not a view).
patrick
Am 26.06.2007 um 16:24 schrieb va:patrick.kranzlmueller:
>
> see:
> http://code.djangoproject.com/wiki/PyCallTag
>
> patrick
>
> Am 26.06.2007 um 16:22 schrieb Moses Ting:
>
>>
>> Does anyone
That's what I thought, but running the following command via a web
request returns lines of length 0.
command = 'c:\path\plink -ssh [EMAIL PROTECTED] -pw password dir'
lines = os.popen(command).readlines()
The exact command works just fine when ran from either a regular
python prompt or within
Malcolm Tredinnick schrieb:
> On Tue, 2007-06-26 at 23:28 +1000, Malcolm Tredinnick wrote:
> [...]
>> The code itself is not catching all the right exceptions that can be
>> raised: the idea was that if getdefaultlocale() returns something we
>> can't use, it should just return no timezone. I'll
see:
http://code.djangoproject.com/wiki/PyCallTag
patrick
Am 26.06.2007 um 16:22 schrieb Moses Ting:
>
> Does anyone know if it's possible to make a system command call from a
> Django view? For example, I'd like to make the following call
> straight from Django.
>
> import os
>
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA256
THANKS!
I will try that!
Manuel
Am 26.06.2007 um 15:36 schrieb Aidas Bendoraitis:
>
> Use the {% with %} template tag for that:
>
> {% with variable|some_filter as some_list %}
>{% for el in some_list %}
>{% do_something el %}
>
Does anyone know if it's possible to make a system command call from a
Django view? For example, I'd like to make the following call
straight from Django.
import os
os.system('echo Hello World')
Thanks
--~--~-~--~~~---~--~~
You received this message because
That was it :)
Thanks a lot
On Jun 26, 4:15 pm, Horst Gutmann <[EMAIL PROTECTED]> wrote:
> Christopher wrote:
> > Hi,
>
> > I am pretty new to both Python and Django and have a quick and
> > hopefully easy question. Is it possible to create a Model with a link
> > back onto itself?
>
> >
Hum... ok, thanks a lot! :)
Ana
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email
Christopher wrote:
> Hi,
>
> I am pretty new to both Python and Django and have a quick and
> hopefully easy question. Is it possible to create a Model with a link
> back onto itself?
>
> Check the code below which does not seem to work.
>
> class Menu(models.Model):
> display_text =
Hi,
I am pretty new to both Python and Django and have a quick and
hopefully easy question. Is it possible to create a Model with a link
back onto itself?
Check the code below which does not seem to work.
class Menu(models.Model):
display_text = models.CharField(maxlength=50)
url =
On Tue, 2007-06-26 at 07:03 -0700, AnaReis wrote:
[...]
> I have a question, do you think I should get the newer version? I
> would if I knew it was easy to update... Because I'm working on linux
> and I'm not very used to work with this os and sometimes those path
> things make me crazy, so what
On Jun 26, 12:30 pm, Malcolm Tredinnick <[EMAIL PROTECTED]>
wrote:
> On Tue, 2007-06-26 at 04:57 -0700, AnaReis wrote:
> > Hi,
> > I've been trying to compare two passwords, but I always get the same
> > error. This was taken from the django test web page and I tried to run
> > it on my idle
Hi Jens,
On Tue, 2007-06-26 at 23:28 +1000, Malcolm Tredinnick wrote:
[...]
>
> The code itself is not catching all the right exceptions that can be
> raised: the idea was that if getdefaultlocale() returns something we
> can't use, it should just return no timezone. I'll give it another look
>
Use the {% with %} template tag for that:
{% with variable|some_filter as some_list %}
{% for el in some_list %}
{% do_something el %}
{% endfor %}
{% endwith %}
Regards,
Aidas Bendoraitis aka Archatas
On 6/25/07, Manuel Meyer <[EMAIL PROTECTED]> wrote:
>
> -BEGIN PGP SIGNED
On Tue, 2007-06-26 at 15:09 +0200, Jens Diemer wrote:
>
> Woops... I used apache2 and django via cgi...
>
> This works fine so far. Until now.
> locale.getdefaultlocale() returns (None, None)
> Don't know why. A restart of apache doesn't change anything.
That's a recent change to the code
Woops... I used apache2 and django via cgi...
This works fine so far. Until now.
locale.getdefaultlocale() returns (None, None)
Don't know why. A restart of apache doesn't change anything.
So i get a django traceback:
-
On 6/26/07, Malcolm Tredinnick <[EMAIL PROTECTED]> wrote:
> I don't want to sound discouraging, but if the answer is at all critical
> to your operation, you can't trust any numbers you get here. They will
> not have the same usage patterns as yours. Benchmark, benchmark,
> benchmark is the only
On Tue, 2007-06-26 at 04:57 -0700, AnaReis wrote:
> Hi,
> I've been trying to compare two passwords, but I always get the same
> error. This was taken from the django test web page and I tried to run
> it on my idle shell:
>
> class UserRegistration(Form):
> username =
I would like to edit templates online. So i used newforms and
.form_for_instance() to build a html form.
The Problem: If there are django template tags in the content, the tag rendered
by the template engine. But i don't want that. I want to edit the tag in a html
textarea.
Here a small cut
On Tue, 2007-06-26 at 13:40 +0200, Bram - Smartelectronix wrote:
> hey guys,
>
>
> due to some unfortunate events we will have to release our current
> django-based site on one server instead of two. We were planning to put
> postgres on another machine, but that's not possible for now.
>
>
> AttributeError: 'UserRegistration' object has no attribute
> 'clean_data'
My first guess: are you using a recent version (the last two months)
from SVN? clean_data was renamed to cleaned_date.
Take a look here:
http://code.djangoproject.com/wiki/BackwardsIncompatibleChanges
Kelvin
--
On 6/26/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
>
> Hi,
>
> I use class_prepared in django-multilingual
Thanks. :)
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this
Hi,
I've been trying to compare two passwords, but I always get the same
error. This was taken from the django test web page and I tried to run
it on my idle shell:
class UserRegistration(Form):
username = CharField(max_length=10)
password1 = CharField(widget=PasswordInput)
I have a weird problem where if i run django standalone, i see the
calendar widget by a DateField entry in the admin form, but when run
from mod_python, i lose it. (i lose the calendar date picking widget,
and the "today" shortcut)
/media *is* working - the css gets loaded properly. I'm using
hey guys,
due to some unfortunate events we will have to release our current
django-based site on one server instead of two. We were planning to put
postgres on another machine, but that's not possible for now.
The machine is a dual opteron 1.8GHz (dualcore) with 4GB of RAM. Running
On Jun 26, 3:09 am, Malcolm Tredinnick <[EMAIL PROTECTED]>
wrote:
> On Mon, 2007-06-25 at 08:22 -0700, AnaReis wrote:
> > Hi,
> > I was trying to change the way in which the errors are presented in a
> > form.
> > I tried to put them in:
> > {{field.label}}:{{field}}{% if
> >
Hi,
On Jun 26, 10:41 am, "Jeremy Dunck" <[EMAIL PROTECTED]> wrote:
> I'm having some trouble finding any uses of class_prepared.
> I imagine this is because the class_prepared signal is sent so early
> in Django's startup, but am curious:
I use class_prepared in django-multilingual to
The trunk version of django-registration has been modified and it is
now even more simple to create a profile object.
Edit registration/urls.py :
# Import your profile object
from profile.models import Profile
# add the dict with your profile creation function
Hello all,
I'm trying to document uses of django signals in preparation for a
presentation.
I'm having some trouble finding any uses of class_prepared.
I imagine this is because the class_prepared signal is sent so early
in Django's startup, but am curious:
Does anyone know of an example
Jens Diemer schrieb:
> I would like to make a newforms user select list, from every existing django
> users, looks like this:
I have found a solution:
class MailForm(forms.Form):
users = forms.ModelMultipleChoiceField(
queryset=User.objects.all(),
2007/6/22, Ramiro Morales <[EMAIL PROTECTED]>:
>
> On 6/21/07, Jeremy Dunck <[EMAIL PROTECTED]> wrote:
> >
> > I don't speak French, but this is very nice to see.
> >
> > Is there any interest in a #django-es for Spanish? I speak a little
> > of that and would like to improve. I could help with
2007/6/22, Chris Brand <[EMAIL PROTECTED]>:
>
> > > I just wonder why this permission is not part of the default
> > > permissions (like add, change and delete)?
> > >
> > > David
> > >
> > No more thoughts about that? I'm really surprised that it only happens
> > to me, maybe I will be luckier
I would like to make a newforms user select list, from every existing django
users, looks like this:
--
username1 - mailto:[EMAIL PROTECTED]">[EMAIL PROTECTED]
89 matches
Mail list logo