On Mon, Jul 27, 2009 at 4:38 AM, Russell
Keith-Magee wrote:
> Perhaps I'm missing some of the "neat tricks" that are only possible
> using this approach, but my immediate reaction is that you appear to
> be going to great lengths to avoid the obvious solution - a method
>
2009/7/24 Rusty Greer :
> that bug actually doesn't fix my case. if i alter the patch to just
> do a file.close() in all cases, it works. is there another patch to
> close the file opened outside of this class?
I'm not sure I follow; let me make sure I understand you:
*
If you're not using the development server (python manage.py
runserver), make sure that you have set a template_dir in settings.py
and make sure the webserver can read it...
On Jul 26, 3:15 pm, LuXo Jarufe wrote:
> Hi, I want to use the admin but I have this problem, I
First you create a ModelForm:
from django.forms import ModelForm
from myproject.myapp.models import MyModelClass
class MyFormClass(ModelForm):
class Meta:
model = MyModelClass
there you have your form_class that you need to pass to the view you want:
Hi all,
I am wondering how can i use form_class with generic views?
FOr example, according to the online doc,
http://docs.djangoproject.com/en/dev/ref/generic-views/
we can use form_class as a required argument for create_object ,
update_object, delete_object
But the online doc stopped short
On Sun, Jul 26, 2009 at 9:17 PM, Amitay Dobo wrote:
> So to sum up: I vote up connection pooling. Where do I sign up?
On some other project's mailing list?
Connection pooling doesn't belong in Django. I've outlined one reason
for that above. Google a bit for things like
I was quite surprised to find out there isn't any connection pooling
built in to Django or (at least some of) its DB beack-ends when I've
first researched about it.
Other people have correctly pointed out that this is a latency issue
that affects both low and high traffic sites. Since there is
problem solved. Type
On Jul 26, 10:05 pm, nixon66 wrote:
> ran into this error. Anyone familiar with it.
>
> TemplateSyntaxError at /lobby/lobbytype/public-relations/
>
> Caught an exception while rendering: Error binding parameter 0 -
> probably unsupported type.
>
>
ran into this error. Anyone familiar with it.
TemplateSyntaxError at /lobby/lobbytype/public-relations/
Caught an exception while rendering: Error binding parameter 0 -
probably unsupported type.
Original Traceback (most recent call last):
File
On Mon, Jul 27, 2009 at 7:55 AM, Alexandru Nedelcu wrote:
>
> Hi,
>
> I'm a newbie when it comes to Django ... I picked it up for a personal
> project because it seemed like a good fit.
>
> I do miss a feature from Catalyst ... chained actions.
> I added this functionality to
On Mon, Jul 27, 2009 at 6:17 AM, Vitaly Babiy wrote:
> Hey,
> I have replaced the default auth backend with my own that requires a field
> to be set on my own custom user objects. So when I run my test suite ( which
> includes the auth app ) most of the auth test fail. Due to
Good afternoon list,
I'm putting together my first django application: a simple blog engine
to replace my current WordPress installation. I am rolling my own
application as an learning exercise. I am currently thinking of using
Markdown with Pygments (via the CodeHilite extension) for managing
Hi, I want to use the admin but I have this problem, I was following
the tutorial in djangoproject but when I execute the admin this
appears:
TemplateDoesNotExist at /admin/
admin/login.html
Request Method: GET
Request URL:http://127.0.0.1:8000/admin/
Exception Type:
Hi,
I'm a newbie when it comes to Django ... I picked it up for a personal
project because it seemed like a good fit.
I do miss a feature from Catalyst ... chained actions.
I added this functionality to Django by myself (just a few hours
hack), see here (example + code):
On Sun, Jul 26, 2009 at 9:42 PM, Shivaraj wrote:
>
> Django doesn't allow urlecode or urlopen when there is a non-ASCII/
> international characters in the url.
Django does no such thing.
Firstly, urlencode and urlopen aren't part of Django's API, so this
isn't an issue of
i thought of something along those lines. that's exactly the kind of
thing that i was originally searching for -- a way to do it without
cluttering things up and without building a bunch of unnecessary
infrastructure or hacking core django code.
unfortunately, when you do those nice reset
Hi, I have a form based on a model which allows users to add comment.
A comment is made up of the comment is about, the body, the date and
time and also who made the comment.
I am mainly interested in the datetime and user fields. What i would
like to know is how i can automatically have these
On Sun, Jul 26, 2009 at 9:13 PM, Vitaly Babiy wrote:
> How does one go about registering a namespace?
Not quite sure what you mean by that, but my guess is that you are assuming
you need to register your namespace (modules?) before being able to import
them. If this is what
See this:
http://docs.djangoproject.com/en/dev/topics/http/urls/#defining-url-namespaces
On Mon, Jul 27, 2009 at 12:13 AM, Vitaly Babiy wrote:
> How does one go about registering a namespace?
> I can't seem to find it in the docs.
> Thanks,
> Vitaly Babiy
>
> >
>
On Sun, Jul 26, 2009 at 3:55 PM, Rams3377 wrote:
>
>
> In Django 1.0.2, what is the best way to perform a user submitted
> search? For instance if someone wanted to search through a profile
> which has several parameters that the user may or may not fill out.
> What is the
Hey,
I have replaced the default auth backend with my own that requires a field
to be set on my own custom user objects. So when I run my test suite ( which
includes the auth app ) most of the auth test fail. Due to the fact that
djangos fixtures don't create user object of my custom type. What is
How does one go about registering a namespace?
I can't seem to find it in the docs.
Thanks,
Vitaly Babiy
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to
Hello and thanks for any assistance in advance.
I've been learning Django and Python this summer and i've pretty much
am addicted. I've used PHP and some experience with C in the past but
haven't ever had this much fun coding EVER. So props to the people who
create to these wonderful
There's a sample project[1] in the github repo.
[1] http://github.com/jtauber/django-email-confirmation/tree/master/devproject
On Jul 25, 6:35 pm, kk wrote:
> Hi,
>
> Is there any tutorial document about how to use this module?
I would like to use generic views to allow users to upload images,
with the image linked ( via ForeignKey ) to the user id.
The following is my code: ( a link to dpaste is here: http://dpaste.com/71693/
)
# models.py
class PressRelease(models.Model):
title = models.CharField(max_length=100)
Hi Hebert,
ok thanks i got what u mean.
But what happens if my model is now like this:
# models.py
class Images(models.Model):
title = models.CharField(max_length=200)
images = models.ImageField(upload_to='userimages')
user = models.ForeignKey(User)
public =
Scot Hacker wrote:
> On Jul 22, 8:13 am, Topa wrote:
>
>> I'd like to require that userpasswordsbe of a certain level of
>> complexity when they're added to or changed on the admin site. I see a
>> way to do this fairly easily with the password reset view since I can
>>
Ronghui Yu wrote:
> How about writing a decorator?
That's possible, although there is an easier way:
The best way imho is to generate a random password when you
create the user, and to send them a password reset email.
Which can be implemented using django.contrib.auth.
That way they don't have
Django doesn't allow urlecode or urlopen when there is a non-ASCII/
international characters in the url.
http://www.djangosnippets.org/snippets/1048/ which uses text.encode
('utf-8') helped.
Reported this in http://code.djangoproject.com/ticket/2078 .
Just wanted to know if this can be included
On Sat, Jul 25, 2009 at 9:23 PM, Adi wrote:
>
> I'm running a couple of django sites on a VPS with nginx and fastcgi
> and I'm a little concerned because of the memory usage.
> According to the "free" command, each site uses about 50MB of RAM
> (I've ran free before and
On Jul 26, 12:46 pm, ramanathan wrote:
> I stored the username, password, email id fields in auth_user table
> using
>
> User.objects.create_user(username,email,password)
>
> But i was not able to store the first_name field..
>
> I tried User.objects.create_user
>
I stored the username, password, email id fields in auth_user table
using
User.objects.create_user(username,email,password)
But i was not able to store the first_name field..
I tried User.objects.create_user
(username,first_name=firstname,email,password)
But it didnt work out..
How to store
It's amazing for me, But I found a best solution!
django-registration have form with checking unique email:
RegistrationFormUniqueEmail
http://bitbucket.org/ubernostrum/django-registration/issue/13/password-reset-issues-emails-should-be#comment-15422
On 26 июл, 15:09, ramusus
Thanks, Andy and Parag!
Validate email field via AJAX - very good idea.
Could you describe case with pre-save signal in more detail, please!
If I understand correctly, you are offering to use pre-save signal
and raise ValidationError if email of new User exists in DB or smthing
else?
Could
On Jul 26, 9:56 am, django user wrote:
> How would I make a formset for exactly the # of images I have in a
> queryset?
Just pass the queryset into the formset instantiation, as described on
the page I referenced:
>>> from django.forms.models import modelformset_factory
How would I make a formset for exactly the # of images I have in a
queryset?
On Jul 26, 1:37 am, Daniel Roseman wrote:
> On Jul 26, 6:13 am, django user wrote:
>
>
>
> > I have a basic form with that shows user's uploaded images:
>
> >
> >
> >
Hi,
AFAICS, it's nearly impossible to do this in the way you want to.
set_pub_date is an another view which does a CRUD operation like
generic view create_object and you pass it to extra_context which is
relevant to a template operation.
extra_context declares new objects in the template and
On Jul 26, 6:13 am, django user wrote:
> I have a basic form with that shows user's uploaded images:
>
>
>
> {% for photo in photos %}
> class="handle2" width="150" height="90" alt="test">
> Order: label> value="{{ photo.position }}" name="image" />
>
>
oh, i missed out my def set_pub_date() in views.py.
Here is the revised version of my code: ( link to dpaste is here:
http://dpaste.com/71532/ )
#urls.py
press_detail_dict = {
'queryset': PressRelease.objects.all(),
'template_name':'press/detail.html',
Hi T,
I found this in the tagging issues from 2008 but it worked:
if your like me then you get this message from within the python
interpreter. Well I
figured out that I need to be running the"python manage.py shell"
command from within
the site DIR to get all the environment variables correct.
hi Dan,
than may i know what is the code like in my views.py for the function
set_pub_date?
Also, from the urls.py, how do i call the set_pub_date() ?
( in urls/py i am using generic view )
Best Regards.
On Jul 26, 12:33 pm, Dan Harris wrote:
> Assuming that you
A few links that might help...
http://groups.google.com/group/django-users/browse_thread/thread/4ba5652bcbd1f958
http://www.djangosnippets.org/snippets/947/
2009/7/26 Jonas Obrist
>
> Is there a builtin way in django to get a list of other users who are
> currently
42 matches
Mail list logo