Hi,
Ive been running into a problem lately (not sure when it started)
where I receive an AttributeError when logging into the admin site.
The circumstances seem to be that I start the application, go to the
admin site (and log in successfully), navigate around the rest of the
application (which doe
On 3/09/2010 2:16pm, Jesse wrote:
I have django and postgres working on the local django server. I had
to install psycopg2-2.2.2.win32-py2.7 in order for that to work. I
don't believe I have access to an earlier version of psycopg. Are you
using postgres?
Yes but a different stack - python 2
I have django and postgres working on the local django server. I had
to install psycopg2-2.2.2.win32-py2.7 in order for that to work. I
don't believe I have access to an earlier version of psycopg. Are you
using postgres?
Jesse
On Sep 2, 5:41 pm, Mike Dewhirst wrote:
> On 3/09/2010 7:46am, Jes
ok Thanks. How about using Register tags. It's in
Django.template.Library.
Is it a good practice to use simple_tag? I want to know the plus
points and drawbacks of simple_tag.
On Sep 2, 8:52 pm, Justin Myers wrote:
> In theory, if the view passed that function to the template (or if it
> were ava
Auth backends fail down the list of middleware. So I'm thinking something
like this.
Maybe, the users that you authenticate using LDAP or AD, append something to
their username, like _xyzuser.
johndoe has LDAP/AD password and logs in.
AD_AUTH_Middleware succeeds with original username and passwd
Account.objects.filter(balance__lt=20) selects accounts with balance
less than $20
Account.objects.filter(balance__lt=jeff.balance) selects accounts with
balance less than the balance of jeff's account
Now, How do I do this?
accounts with balance whose absolute value is greater than the
absolute
On 3/09/2010 7:46am, Jesse wrote:
Hello Graham,
I have the c:/public/apache/apache_django_wsgi.conf working now, at
least apache restarts. Do you know if mod_wsgi has a problem with
these versions:
python 2.7 and apache 2.2, and postgres 8.4, psycopg 2.2.2
My server error is:
TemplateSyntaxEr
That's a huge help in understanding the underlying concepts. Thank
you very much. While attempting to answer my question, you actually
led me to the answer myself.
I was trying to generate an index with South and that was raising the
error. Essentially, I was trying to apply an index to a forei
On 9/2/2010 1:44 AM, Paul Winkler wrote:
> Hah. That was a pretty long message relative to how quickly I found
> the answer myself :-p
> Sorry for the noise.
>
> For posterity, extra(where=...) is indeed the solution. I overlooked
> the obvious:
> the class I was trying to fix is itself a subclass
On Fri, Sep 3, 2010 at 6:03 AM, HiTekElvis wrote:
> Have a db that was generated under 1.0. Hence, foreign keys in MySQL
> have been named [tablename]_[fieldname]_id.
A slight correction - foreign key *indexes* will be named like that;
the fields themselves don't include the table name.
> Howev
Have a db that was generated under 1.0. Hence, foreign keys in MySQL
have been named [tablename]_[fieldname]_id.
However, when upgrading to 1.2, I tried to create an index on that
field and got an error, because 1.2 names its foreign keys
[tablename]_[hash] and its index keys [tablename]_[fieldna
I've written a custom backend for Django auth to hook into our Active
Directory. It works great, but some users can't seem to figure out
that "username" does not equal "email address". Since our AD is kind
of borked, multiple users *might* have the same email addresses, so
simply changing it to als
Don't use [] subscripting, use dot. The template engine tries using
the thing after the dot in various ways, including as a dictionary key
and as a list index. So, for example:
{% ifequal param1_trunc.i "-" %}
On Thu, Sep 2, 2010 at 5:11 PM, Bradley Hintze
wrote:
> Hi,
>
> Django says that t
I am so dense sometimes...
I had forgotten that initial data in a formset is a *list* of
dictionaries.
So I set up the initial data in a loop over the available products,
and created a parallel list of product_descriptions in the same loop.
Then set up the formset, and looped over formset.forms
Hello Graham,
I have the c:/public/apache/apache_django_wsgi.conf working now, at
least apache restarts. Do you know if mod_wsgi has a problem with
these versions:
python 2.7 and apache 2.2, and postgres 8.4, psycopg 2.2.2
My server error is:
TemplateSyntaxError: Caught ImproperlyConfigured whi
So the example you gave of "other peoples" looks like they have a
related table for "Service Checks" and that table has two fields, one
for check and the other for options, from what I can tell.
HTH
J
On Sep 1, 7:03 am, norus wrote:
> Hi all,
>
> I've decided to start learning Django and Python
On 9/2/2010 4:27 PM, adelein wrote:
> When I display the ToolBoxEditForm it uses a multiple select field.
> But what I want is a form that lets the user edit each tool he has in
> the toolbox as a text field. I cant figure out how to do this with the
> many-to-many field.
>
A many-to-many relation
Hi,
Django says that this is a TemplateSyntaxError.
if param1_trunc[i][1]
The i refers to an index of a for loop as shown:
{% for i in pdb1_nums_len_dev6 %}
{% ifequal param1_trunc[i] '-' %}
{% else %}
{% if param1_trunc[i][1] %}
{% else %}
Bill,
thanks a ton for the conversation.
I will try some variations of that set of ideas over the weekend and
report back here with what works.
And you are correct, I am not now creating the formset forms in a
loop, but might try that as one variation.
-Bob
--
You received this message becaus
Well, if you can iterate the forms of a formset in the template, you can
do it in python. I guess the trick is whether there is a public interface
for accessing the model instance of the current form during such an
iteration, (I'm assuming here that the fields you do want to use a fields
comes fr
You can use multiple authentication backends in the same Django
project. All you have to do is write/install a backend that supports
your alternative method, and add it to AUTHENTICATION_BACKENDS in your
settings file.
The info here should help a lot:
http://docs.djangoproject.com/en/dev/topics/au
When I display the ToolBoxEditForm it uses a multiple select field.
But what I want is a form that lets the user edit each tool he has in
the toolbox as a text field. I cant figure out how to do this with the
many-to-many field.
class Tool(models.Model):
tool_name = models.CharField(unique=Tru
On Sep 2, 2:54 pm, Bill Freeman wrote:
> Let's start by agreeing on common terminology. "property" has
> a meaning in Python slightly different than its usage in some
> other languages, and I don't think that's what you mean.
>
> I'm thinking that what you mean by "property" on the form is what
Let's start by agreeing on common terminology. "property" has
a meaning in Python slightly different than its usage in some
other languages, and I don't think that's what you mean.
I'm thinking that what you mean by "property" on the form is what
Python calls an attribute of the instance of the
Patricia wrote:
>
>
> Hi all!
>
> I have a page with some years. I want to click over the year, for
> instance 2000, to see all the information.
> I've build some permalinks in other pages to built the URL, now I
> wanted to do the same thing, but the field I wanted to connect is not
> the year, i
Bill,
Thanks a lot for sticking with this question.
On Sep 2, 1:44 pm, Bill Freeman wrote:
> I guess that what I'm saying is that when you get fussy about rendering, you
> need to write the html/css yourself. Because you say you want read only for
> these fields, don't use the form field's rend
On 09/02/10 17:12, commonzenpython wrote:
> hey, guys
> is it possible to have multiple django projects in one server ?
>
You can also make them using different django versions
check django + virtualenv on google
zalun
--
blog http://piotr.zalewa.info
jobs http://webdev.zalewa.info
twit htt
I guess that what I'm saying is that when you get fussy about rendering, you
need to write the html/css yourself. Because you say you want read only for
these fields, don't use the form field's rendering at all (or use a
hidden field).
Compose a div or span or whatever suits your fancy, and pass w
Hi,
we've started a new open-source project which extends Django's
querying capabilities on NoSQL databases (App Engine, MongoDB, etc.),
so you can use filters like "__month" or "__iexact" even if they're
not natively supported by the database. The advantage is that you
don't need to deal with writ
I have looked at the django documentation and searched the group
archive for my answer, and believe I know how this is supposed to
work, I just cannot figure out why it is not working for me. I want
to pass an extra keyword parameter to my view that contains a filter
value, but it is not getting p
Hello,
Yes you can have many Django projects installed on one server.
On Sep 2, 9:12 am, commonzenpython wrote:
> hey, guys
> is it possible to have multiple django projects in one server ?
Toodle-lo..
creecode
--
You received this message because you are subscribed to the Go
Absolutely! :)
On Sep 2, 2010, at 12:12 PM, commonzenpython wrote:
hey, guys
is it possible to have multiple django projects in one server ?
--
You received this message because you are subscribed to the Google
Groups "Django users" group.
To post to this group, send email to django-us...
Have a read through this article, Dan:
http://www.b-list.org/weblog/2008/nov/09/dynamic-forms/
On Sep 2, 11:19 am, Dan Klaffenbach
wrote:
> On 2 Sep., 16:48, Daniel Roseman wrote:> It's not
> clear exactly what you want. Using RequestContext and the
> > request context processor will ensure th
hey, guys
is it possible to have multiple django projects in one server ?
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to
django-u
Thanks! I did see the hello using the corrected localhost/myapp, so I
at least know that I have the right version of mod_wsgi. Now I'm back
to my original problem. The apache server will not restart when I add
the following line to the http.conf file:
Include "c:/public/apache/apache_django_wsg
In theory, if the view passed that function to the template (or if it
were available as a method on something else that was passed to the
template), I suppose you could. That said, you wouldn't be able to
pass it any arguments.
Once again, the template is _not_ designed for programming logic. It's
On Thu, Sep 2, 2010 at 17:46, Daniel Roseman wrote:
> See here for an explanation:
> http://docs.djangoproject.com/en/1.2/ref/templates/api/#subclassing-context-requestcontext
> especially the "Note" box a screen or so down.
Thanks! Now everything is clear
--
Karim Gojux
www.karimblog.net
--
On 2 Sep., 16:48, Daniel Roseman wrote:
> It's not clear exactly what you want. Using RequestContext and the
> request context processor will ensure that the request is present in
> all your templates. Is that enough?
No. I'll give an example:
I use a custom Acl class for checking the user's pe
On Thu, Sep 2, 2010 at 2:15 PM, Martin Tiršel wrote:
> I tried to create second .po file with manual translations, but had no luck
> either :( `compilemessages` creates the second .mo file, but doesn't use it
> in the app. Only django.mo is used, but all my translations in django.po
> file are com
We have a modelformset created like this:
DocumentFormSet = modelformset_factory(Document, extra=0,
fields=('name', 'category')
with a models.py like this:
class Category(models.Model):
name = CharField(max_length=100)
# other stuff
class Document(models.Model):
name = CharField(max
On Sep 2, 3:30 pm, Daniel Klaffenbach
wrote:
> Hi,
>
> I am developing a Django app which relies on information from the
> request object a lot, especially request.user. I need this object (or
> let's say at least 'REMOTE_USER') in many models and I was wondering
> if there is another way to get t
On Sep 2, 2:45 pm, Karim Gorjux wrote:
> Working on the Coltrane's Book :-) ...
>
> I create two views that do the same thing but the first one use the
> generic view and the second a render to response.
> I don't understand why because both works but the second besides don't
> passe the category
On Thu, Sep 2, 2010 at 3:30 PM, Daniel Klaffenbach
wrote:
> Hi,
>
> I am developing a Django app which relies on information from the
> request object a lot, especially request.user. I need this object (or
> let's say at least 'REMOTE_USER') in many models and I was wondering
> if there is another
Hi,
I am developing a Django app which relies on information from the
request object a lot, especially request.user. I need this object (or
let's say at least 'REMOTE_USER') in many models and I was wondering
if there is another way to get the request object?
In PHP there is something like $_SERV
Working on the Coltrane's Book :-) ...
I create two views that do the same thing but the first one use the
generic view and the second a render to response.
I don't understand why because both works but the second besides don't
passe the category object, don't load the
django.core.context_processo
I've got several tables like the one below, where I initialize it with
"template" values that I copy when I create a new record.
INSERT INTO A VALUES
(19, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, ., 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, '&', '&'),
(20, 0, 0, 0,
I tried to create second .po file with manual translations, but had no
luck either :( `compilemessages` creates the second .mo file, but doesn't
use it in the app. Only django.mo is used, but all my translations in
django.po file are commented out after I run `makemessages`.
In the document
Hi,
I'd strongly advise to try homebrew instead of macports. You can find
it here: http://github.com/mxcl/homebrew .
After installation do: brew up && brew install jpeg and install PIL as
usual.
Since I needed freetype support I had to update PIL's setup.py
FEETYPE_ROOT: FREETYPE_ROOT = libinclude(
Thank You very much.
Tomek
On 2 Wrz, 14:45, Federico Maggi wrote:
> wrote:
> > How to open port 25 in ubuntu?
>
> If you google for "mail ubuntu" or "smtp ubuntu" there is a nice
> community doc/wiki explaining you all the steps for setting up an SMTP server
> on Ububtu.
>
> Otherwise, for
wrote:
> How to open port 25 in ubuntu?
If you google for "mail ubuntu" or "smtp ubuntu" there is a nice community
doc/wiki explaining you all the steps for setting up an SMTP server on Ububtu.
Otherwise, for testing purposes, you could use the debug mail backend in Django
that writes e-m
On 09/01/2010 11:54 PM, Reinout van Rees wrote:
On 09/01/2010 02:00 PM, Reinout van Rees wrote:
Hi,
I'm deploying a site on windows with oracle (and I don't know either of
them well). Simple apache+wsgi setup for now.
I'll have to test it out tomorrow when I'm near the windows machine
again,
I scanned ports of my IP using network tools and seems that only 45784
and 47344 are open. How to open port 25 in ubuntu?
thanks
Tomek
On 2 Wrz, 14:28, Federico Maggi wrote:
> On 02/set/2010, at 14:10, tom84 wrote:
>
> > Unfortunately after sending filled registration form I received 111
> > err
On 02/set/2010, at 14:10, tom84 wrote:
> Unfortunately after sending filled registration form I received 111
> error- connection refused.
Looks lice you're trying to connect to a closed/filtered port (25). Have
you tested the SMTP outside Django (e.g., using telnet localhost 25)?
-- Fede
oh,,,thanks a lot for d reply,,,
On Thu, Sep 2, 2010 at 4:33 PM, Daniel Roseman wrote:
> On Sep 2, 9:49 am, girish shabadimath
> wrote:
> > actually i wanted to access values from database and use those values in
> url
> > unittesting,,,
> >
> > like:
> > response = self.client.get('def/defe
Hello.
I installed django-registration from
http://bitbucket.org/ubernostrum/django-registration/downloads.
Unfortunately after sending filled registration form I received 111
error- connection refused. I found somewhere that it may be because of
the wrong server configuration, so I set some value
Hi,
Ive been running into a problem lately (not sure when it started)
where I receive an AttributeError when logging into the admin site.
The circumstances seem to be that I start the application, go to the
admin site (and log in successfully), navigate around the rest of the
application (which do
Hello,
I can not find in Django documentation a word about translating variables
or strings with variables. I have:
...
{% trans question_category %}
...
django-admin.py makemessages creates .po but without a mention about this
template line ({% trans "some text" %} is ok). It is clear, th
Thank you so much, it worked:)...Now I just have to play with parsing
json that I think I can manage.
Thanks again:)
Irum
On Sep 2, 1:11 pm, Daniel Roseman wrote:
> On Sep 2, 10:37 am, irum wrote:
>
>
>
> > Hi,
> > Thanks for your prompt reply.
> > I have tried both the things but I get the sa
On Sep 2, 9:49 am, girish shabadimath
wrote:
> actually i wanted to access values from database and use those values in url
> unittesting,,,
>
> like:
> response = self.client.get('def/defect/', {'*ID*':*id*})
> self.failUnlessEqual(response.status_code, 200)
>
> how to get id from database..?,,,a
buddy did i convince u..?,,,reply soon...solution to my problem,,
On Thu, Sep 2, 2010 at 2:19 PM, girish shabadimath wrote:
> actually i wanted to access values from database and use those values in
> url unittesting,,,
>
> like:
> response = self.client.get('def/defect/', {'*ID*':*id*})
> self.
actually i wanted to access values from database and use those values in url
unittesting,,,
like:
response = self.client.get('def/defect/', {'*ID*':*id*})
self.failUnlessEqual(response.status_code, 200)
how to get id from database..?,,,and also i want this test to be done for
each id in database,
On Sep 2, 10:37 am, irum wrote:
> Hi,
> Thanks for your prompt reply.
> I have tried both the things but I get the same error.
> With,
> x = json.loads(p.read())
> print x
>
> I get following error: 'HttpResponse' object has no attribute
> 'read'
> Also I get same error with, json.dump
Hi,
Thanks for your prompt reply.
I have tried both the things but I get the same error.
With,
x = json.loads(p.read())
print x
I get following error: 'HttpResponse' object has no attribute
'read'
Also I get same error with, json.dumps(p.read()), and same when I use
loads and dumps as
On Sep 2, 9:57 am, irum wrote:
> Hi,
> I am having problems with extracting json data for parsing from HTTP
> GET request.
>
> What I am doing is that I am receiving json data over HTTP via GET.
> After debugging much, I have realized that the data also has HTTP
> headers and other information th
Hi,
I am having problems with extracting json data for parsing from HTTP
GET request.
What I am doing is that I am receiving json data over HTTP via GET.
After debugging much, I have realized that the data also has HTTP
headers and other information that serializer is not able to
deserialize. How
Hi,
Sorry for late reply. I had to switch to another project so this work
got delayed.
Actually, what I am doing is that I am receiving json data over HTTP
via GET. After debugging much, I have realized that the data also has
HTTP headers and other information that serializer is not able to
serial
Hello, I'm creating the system, which will rely on plugins.
For instance, I have main application with model:
class User(models.Model):
ContractNum = models.PositiveIntegerField(unique=True, blank=True,
null=True )
LastName = models.CharField(max_length=50)
FirstName = models.CharField
On Sep 2, 8:17 am, girishmss wrote:
> Hi folks,im working on django project,,is there a way to access db
> without using fixtures,, as fixtures is not working in my project,,i
> want to test urls of type:
>
> /abc/xyz/123 where '123' comes from database.,
>
>
On Sep 2, 6:58 am, Karen Tracey wrote:
> On Wed, Sep 1, 2010 at 1:23 PM, vgarvardt wrote:
> > Django 1.2.1
>
> > Created new project, set DB settings (postgresql_psycopg2),
> > MEDIA_ROOT, MEDIA_URL, TEMPLATE_DIRS, added django.contrib.admin to
> > INSTALLED_APPS.
>
> > In urls.py uncommented:
>
On Sep 2, 6:58 am, Karen Tracey wrote:
> On Wed, Sep 1, 2010 at 1:23 PM, vgarvardt wrote:
> > Django 1.2.1
>
> > Created new project, set DB settings (postgresql_psycopg2),
> > MEDIA_ROOT, MEDIA_URL, TEMPLATE_DIRS, added django.contrib.admin to
> > INSTALLED_APPS.
>
> > In urls.py uncommented:
Hi folks,im working on django project,,is there a way to access db
without using fixtures,, as fixtures is not working in my project,,i
want to test urls of type:
/abc/xyz/123 where '123' comes from database.,
and that database contains lots of ids( ex:
Thanks Yangmin
I did notice that changes are picked up automatically, but this
particular case the change did not show up automatically. It is my
first time writing a django app to perhaps I did something wrong.
Thanks for the feedback though.
On Sep 2, 5:04 pm, Yangmin Li wrote:
> if you are
if you are django's built-in development server, it will reload the changes
after you've saved the changes.
On Thu, Sep 2, 2010 at 12:42 PM, Kevan Stannard wrote:
> I had the same problem going through the tutorial just now. I quit the
> interpreter and restarted it and it seemed to pick up th
73 matches
Mail list logo