Admin page doesn't show calendar popup

2008-03-29 Thread Hoolio
I just installed Django 96.1 on my Mac. When I follow the tutorial and get to the Admin page, the calendar pop ups don't show up. Is there a problem with the install. I'm using Leopard. --~--~-~--~~~---~--~~ You received this message because you are subscribed

Re: Do I need two classes that are identical because I want to use two database tables?

2008-03-29 Thread jeffself
On Mar 28, 9:34 pm, andy baxter <[EMAIL PROTECTED]> wrote: > Peter Rowell wrote: > >> So should I just create two classes that are identical but name one > >> CurrentElectionResults and the other PastElectionResults? > > Can't you just have a single class 'ElectionResults' and add a field >

Re: templatetags

2008-03-29 Thread jeffself
On Mar 29, 11:40 pm, ameriblog <[EMAIL PROTECTED]> wrote: > i have a site that lists candidates for mayor, on the page i have > biographical information, also i want to include recent news for that > candidate. i have news setup as a class in the models.py that has a > ManyToMany relationship

Re: scraping PDF

2008-03-29 Thread jeffself
On Mar 29, 12:56 am, "James Bennett" <[EMAIL PROTECTED]> wrote: > On Fri, Mar 28, 2008 at 11:21 PM, <[EMAIL PROTECTED]> wrote: > > I'm trying to figure out the best way to link-up everything. Any > > suggestions? > > So, since I talked about it at PyCon, I'll take an example from this >

Re: sports ratings

2008-03-29 Thread jeffself
Hey ameriblog, I do ratings as well. My current application was written in C about 10 years ago and I've flirted with rewriting it in Python. In fact, I posted a message on comp.lang.python last year about trying to speed up my app:

Re: templatetags

2008-03-29 Thread Michael Wieher
so... use the view to select (10items) from news items where canidate=john-doe order by date then do whatever On Sat, Mar 29, 2008 at 10:40 PM, ameriblog <[EMAIL PROTECTED]> wrote: > > i have a site that lists candidates for mayor, on the page i have > biographical information, also i want to

templatetags

2008-03-29 Thread ameriblog
i have a site that lists candidates for mayor, on the page i have biographical information, also i want to include recent news for that candidate. i have news setup as a class in the models.py that has a ManyToMany relationship with the candidates (since plenty of news stories cover multiple

FRIENDS YESTERDAY I MAKE $2,000BY TAKE SIMPLE ONLINE SURVEYS. YOU

2008-03-29 Thread donald
FRIENDS YESTERDAY I MAKE $2,000BY TAKE SIMPLE ONLINE SURVEYS. YOU JUST NEED TO JOIN THEIR COMMUNITY AND THEY GIVES YOU PLENTY OF SURVEYS.YOU MAY CHOOSE BEST RATED SURVEY FROM THE LIST.EACH SURVEYRATE BEGINS WITH $200. THE LINK IS BELOW http://jeevaraj.MYSURVEYPR.hop.clickbank.net YOUR LIFE

Re: Is Django thread safe?

2008-03-29 Thread James Bennett
On Sat, Mar 29, 2008 at 3:52 AM, Graham Dumpleton <[EMAIL PROTECTED]> wrote: > The best I have ever been able to get out of anyone associated with > Django development about thread safety is the comments by Jacob Kaplan- > Moss in the following thread: And that's really about the best anyone

GSoC idea for Django-friendly static checkers

2008-03-29 Thread Todd O'Bryan
Sorry I'm so late suggesting this, but... Do people have a desire/see a need for a way to make Pylint or PyChecker handle Django code more robustly? Because so many of the attributes of Django model and form objects are given as class objects or are auto-generated in instance creation, using a

Re: Finding out the index of a model instance in a list

2008-03-29 Thread [EMAIL PROTECTED]
I'd consider grabbing a list of GalleryImage objects and then using the forloop.counter in the template as you iterate over each item. Right now, it looks like you're only grabbing one item with IImage, even though you're using filter(). I'd try it this way: ImageList =

Re: Is Django thread safe?

2008-03-29 Thread Eric
Sorry, I forgot to post the url to the fastcgi docs http://www.djangoproject.com/documentation/fastcgi/ On Mar 29, 7:52 pm, Eric <[EMAIL PROTECTED]> wrote: > I currently use lighttpd and fastcgi, and I noticed that in the django > documentation that they mention using threaded instead of

Re: Is Django thread safe?

2008-03-29 Thread Eric
I currently use lighttpd and fastcgi, and I noticed that in the django documentation that they mention using threaded instead of prefork when running your fcgi server. I had the same fears and I used prefork first, but after some load testing of both, I decided to use threaded. I'm a brave soul

Re: Finding out the index of a model instance in a list

2008-03-29 Thread Colin Bean
> > lImage = GalleryImage.objects.filter(pk=pImageSerial).select_related()[0] > lAlbumImages = GalleryImage.objects.filter(album__id = lImage.album.id) > lImagesInAlbum = lAlbumImages.count() > lImagePosition = None > lPreviousImage = None > lNextImage = None > for

Shell reloading

2008-03-29 Thread Jorge Sousa
Hi, I'm using Django on windows. Is it possible to, once inside the Django Shell (manage.py shell) while testing some bint and changing the code in a model method to have it available to the shell? Kind of autoreload thing. It only work by exiting the shell and entering again. But then have to

Re: Finding out the index of a model instance in a list

2008-03-29 Thread Tim Sawyer
Is there a better way that this? lImage = GalleryImage.objects.filter(pk=pImageSerial).select_related()[0] lAlbumImages = GalleryImage.objects.filter(album__id = lImage.album.id) lImagesInAlbum = lAlbumImages.count() lImagePosition = None lPreviousImage = None lNextImage

Need Help Thinking Through How to Setup URLS and VIEWS

2008-03-29 Thread [EMAIL PROTECTED]
I am stuck trying to think through how to work something out. I want a user to be able to create sections in an admin for a site. A user can assign pages to a section. For instance, create the section About and add the pages About Us and Contact and Staff. That is all done. No problems. The part

Finding out the index of a model instance in a list

2008-03-29 Thread Tim Sawyer
Hi Folks, If I have an image, and a list of images, how can I work out what position in the list my image is so I can do a Image 4 of 24 type annotation? lImage = GalleryImage.objects.filter(pk=pImageSerial).select_related()[0] lAlbumImages = GalleryImage.objects.filter(album__id =

Re: sys.path vraag

2008-03-29 Thread Baurzhan Ismagulov
Hello Jaap, On Sat, Mar 29, 2008 at 06:47:39AM -0700, Jaap wrote: > Path onder Windows XP Home is: > D:\Phyton25\;D:\Python25Scripts;%SystemRoot%\system32;%SystemRoot%; > %SystemRoot%\System32\Wbem > > Als ik de interpreter in PyScripter gebruik, dan krijg ik: > >>> print sys.path >

Re: Clearing the cache

2008-03-29 Thread Mike H
On 29 Mar 2008, at 17:49, Sebastjan Trepca wrote: > > I would use signals for this. For example, you could hook on post_save > signal, so whenever a model gets saved, you refresh the cache etc. Unfortunately it's not as simple as that, we cache groups of models, querysets, portions of html

Re: Is Django thread safe?

2008-03-29 Thread Peter Rowell
> The best I have ever been able to get out of anyone associated with > Django development about thread safety is the comments by Jacob Kaplan- > Moss in the following thread: Sigh. Reading through that thread was singularly unsatisfying. I guess that, for the moment, I'll have to stick with

Re: sports ratings

2008-03-29 Thread shabda
Read this, www.b-list.org/weblog/2007/sep/22/standalone-django-scripts/ , and create a standalone django script. Then set up a cron job to run your script when you want. On Mar 29, 11:53 pm, ameriblog <[EMAIL PROTECTED]> wrote: > i have my own formula used for sports ratings (like jeff sagarin,

sports ratings

2008-03-29 Thread ameriblog
i have my own formula used for sports ratings (like jeff sagarin, the bcs, etc). right now i have an old Visual Basic code that updates the ratings and i just save it as a text file and ftp to the web. i'd really love to make it dynamic, so it presents better ( like http://kenpom.com/rpi.php ),

Re: compiling files when installing to a web server

2008-03-29 Thread andy baxter
Michael Wieher wrote: > I had an intermittent error when using just apache/mod_python, but > haven't had it happen since i started w/django > It looks like the speed issue is to do with memory - with just apache2, mysqld and django running, it was 72M into swap. So I guess I need to get a

Re: compiling files when installing to a web server

2008-03-29 Thread Michael Wieher
I had an intermittent error when using just apache/mod_python, but haven't had it happen since i started w/django On Sat, Mar 29, 2008 at 1:18 PM, andy baxter < [EMAIL PROTECTED]> wrote: > > Michael Wieher wrote: > > Well, if you could describe the error in detail, hopefully with > > copy/paste,

Re: compiling files when installing to a web server

2008-03-29 Thread Michael Wieher
Well, if you could describe the error in detail, hopefully with copy/paste, traceback etc. it would be easier to determine if it was due to memory issues or misconfiguration... On Sat, Mar 29, 2008 at 1:10 PM, andy baxter < [EMAIL PROTECTED]> wrote: > > andy baxter wrote: > > andy baxter wrote:

Re: compiling files when installing to a web server

2008-03-29 Thread andy baxter
andy baxter wrote: > andy baxter wrote: > >> hello, >> >> I have just installed a demo of an app I'm writing to a web server. >> There seems to be an intermittent error, and I'm wondering if this is to >> do with the permissions on the directories - I've tried to set the >> permissions so

Re: compiling files when installing to a web server

2008-03-29 Thread andy baxter
andy baxter wrote: > hello, > > I have just installed a demo of an app I'm writing to a web server. > There seems to be an intermittent error, and I'm wondering if this is to > do with the permissions on the directories - I've tried to set the > permissions so it can create .pyc files, but

Re: Clearing the cache

2008-03-29 Thread Sebastjan Trepca
I would use signals for this. For example, you could hook on post_save signal, so whenever a model gets saved, you refresh the cache etc. Sebastjan On Sat, Mar 29, 2008 at 4:35 PM, Mike H <[EMAIL PROTECTED]> wrote: > > Hi, > > I have models, views and managers that cache various things in the

Re: Unittest test-database not empty

2008-03-29 Thread Emil Stenström
Hi rock, I had the same problem and traced it to one of the contrib.auth tests. It seems they don't delete two of the testusers there. I added a ticket about it (http://code.djangoproject.com/ticket/6923), and will just use another username for my own tests meanwhile. /Emil On 30 Jan, 10:34,

Re: Access control

2008-03-29 Thread Peter Herndon
http://www.djangoproject.com/documentation/authentication/ On Sat, Mar 29, 2008 at 1:04 PM, Wilson Acha <[EMAIL PROTECTED]> wrote: > > Hello, django have any library that allows include a login and enable > restrict access to different parts of the application according to > roles and / or

Newforms

2008-03-29 Thread Rufman
Hey Guys How and when do the django newforms validate forms and add errors to the errors dictionary? Im trying to make a dynamic form, so I add the data after creating the form class and adding the attributes. This means that I will need to 'manually' call the form validation. ex: when I

Access control

2008-03-29 Thread Wilson Acha
Hello, django have any library that allows include a login and enable restrict access to different parts of the application according to roles and / or profiles Wilson --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups

Re: User created in postgresql is not found when Adding Data to the API.

2008-03-29 Thread Chirolo
Hi again. Thank you once again Thomas. I tried what you recommended and nothing worked. Once again the problem was that I'm a newbie trying to learn. Here is what I had done wrong since I started with this problem: One field was never validated in my 'model.py' after running 'manage.py syncdb',

newform dynamic model

2008-03-29 Thread Radim
I need to pass a model to Form class as an attribute, I want to write a generic view. How to do it? class Frm(forms.ModelForm): def __init__(self,model,instance): self.model = model forms.ModelForm.__init__(self,instance=instance) class Meta: model = model # <-

Re: sys.path question

2008-03-29 Thread Jaap
The name 'sys' is confusing. If it had been named 'python.path' instead of 'sys.path' I would have known where to look... I will be asking stupid questions for the next month or so - it's the fate of the newbie. --~--~-~--~~~---~--~~ You received this message

Re: Problem with nested loop

2008-03-29 Thread Brandon Taylor
Thank you SO much for helping Kenneth. I just had to change 'workcategory_set' to 'worksample_set' and it's all good. I never would have found this in the documentation without knowing the '_set' keyword, but for those of you who are interested, it's in the documentation here:

Re: Language code as part of URL

2008-03-29 Thread [EMAIL PROTECTED]
This isn't an answer to your technical query but rather some thoughts on how to do localisation in URLs. Localisation in URLs is tricky because the best way to do it varies enormously depending on the nature of your localisation. If the content is ultimately the same and you're simply offering

Re: sys.path question

2008-03-29 Thread Evert Rol
> Path in Windows XP Home is: > D:\Phyton25\;D:\Python25Scripts;%SystemRoot%\system32;%SystemRoot%; > %SystemRoot%\System32\Wbem > > When I use the interpreter in PyScripter, I see: print sys.path > > ['C:\\Windows\\system32\\python25.zip', 'D:\\Python25\\Lib', 'D:\ > \Python25\\DLLs',

Clearing the cache

2008-03-29 Thread Mike H
Hi, I have models, views and managers that cache various things in the application we're building. It all works fantastically, once everything is cache we got zero queries run until the cache expires. However, if the cache is turned on while we run our unit tests, things start failing as

sys.path question

2008-03-29 Thread Jaap
Path in Windows XP Home is: D:\Phyton25\;D:\Python25Scripts;%SystemRoot%\system32;%SystemRoot%; %SystemRoot%\System32\Wbem When I use the interpreter in PyScripter, I see: >>> print sys.path ['C:\\Windows\\system32\\python25.zip', 'D:\\Python25\\Lib', 'D:\ \Python25\\DLLs',

compiling files when installing to a web server

2008-03-29 Thread andy baxter
hello, I have just installed a demo of an app I'm writing to a web server. There seems to be an intermittent error, and I'm wondering if this is to do with the permissions on the directories - I've tried to set the permissions so it can create .pyc files, but this doesn't seem to be working.

sys.path vraag

2008-03-29 Thread Jaap
Path onder Windows XP Home is: D:\Phyton25\;D:\Python25Scripts;%SystemRoot%\system32;%SystemRoot%; %SystemRoot%\System32\Wbem Als ik de interpreter in PyScripter gebruik, dan krijg ik: >>> print sys.path ['C:\\Windows\\system32\\python25.zip', 'D:\\Python25\\Lib', 'D:\ \Python25\\DLLs',

Re: Problems with Apache + mod_python [SOLVED]

2008-03-29 Thread Ramiro Morales
On Fri, Mar 28, 2008 at 11:45 PM, Graham Dumpleton <[EMAIL PROTECTED]> wrote: > > On Mar 29, 5:04 am, Slayer_X <[EMAIL PROTECTED]> wrote: > > Problem solved! > > > > I deleted the symlinks, delete de django-trunk dir and make a fresh > > install directly in > > > >

distinct UPDATE / INSERT before save() without select to DB

2008-03-29 Thread eat
How to distinct in save() method of the model if the save operation will be update or insert. I want to know it BEFORE doing the save(). I want to know it WITHOUT doing a select to a database. THe reason for that : i want to check the database conditions for the insert to initiate. Currently i

Re: many to many field problem

2008-03-29 Thread Evert Rol
Where or what is the Transparency member in the tableslots you call below? I guess I forgot to ask for that previously. You may also want to check how your Align is defined (in choices=Align). > >{%for tableslots in tableslots_list%} > > {{tableslots.Transparency}} > >

Re: Is Django thread safe?

2008-03-29 Thread Graham Dumpleton
The best I have ever been able to get out of anyone associated with Django development about thread safety is the comments by Jacob Kaplan- Moss in the following thread: http://groups.google.com/group/django-developers/browse_frm/thread/905f79e350525c95/dfed56f8ed65aed2 Graham On Mar 29,

Re: IOError: decoder jpeg not available

2008-03-29 Thread zombat
I solved the problem by using the Python packages from pythonmac.org (pythonmac.org/packages/). There seems to be no more problems with django an PIL. The strange thing was that that PIL worked properly with the standard python from Mac OS 10.5. In the python shell I could retrieve the width and

Re: many to many field problem

2008-03-29 Thread didia lim
hi this is my class for columnsetup and querysetup.. thanks a lot for your help class columnSetup(models.Model): name=models.CharField("Name",max_length=50) width =models.IntegerField("Width",max_length=3) align

Re: many to many field problem

2008-03-29 Thread Evert Rol
> ds = DigitalSignage.objects.get(pk=ds_id) > #Digital Signage config & setting > setting = ds.setting > textslots = ds.textslot_set.all() > slots = ds.slot_set.all() > tableslots = tableSlot.objects.filter(DS_List=ds) > columnsetups =

Re: javascript in django

2008-03-29 Thread Przemek Gawronski
Dnia Fri, Mar 28, 2008 at 09:00:26AM -0700, [EMAIL PROTECTED] napisał: > So if it was called "color" in your model, the field name would be > "id_foo" A mistype above, it would be: color -> id_color Przemek -- AIKIDO TANREN DOJO - Poland - Warsaw - Mokotow - Ursynow - Natolin info:

Re: Problem with nested loop

2008-03-29 Thread Kenneth Gonsalves
On 29-Mar-08, at 11:43 AM, Kenneth Gonsalves wrote: > {% for w in wc %} w.title<-- forgot this > > {% for sample in w.workcategory_set.all %} > sample > {% endfor %} > > {% endfor %} -- regards kg http://lawgon.livejournal.com http://nrcfosshelpline.in/code/

Re: Problem with nested loop

2008-03-29 Thread Kenneth Gonsalves
On 29-Mar-08, at 11:17 AM, Brandon Taylor wrote: > What I would like to accomplish is output that looks as such: > > Category name > > Sample Name > Sample Name > Sample Name > > > Category name > > Sample Name > Sample Name > Sample Name > > wc = WorkCategory.objects.all() for