Re: CSS Issues

2008-01-06 Thread zodman
define as /srv/ your documentroot on apache virtualhost. change 755 permission to your /srv/abc/media dir put a symbolic link on /srv/media --> /srv/abc/media/ rember when the navegator search on django.abc.com/media/ search /media dir for /media/ location on your documentroot William

Re: CSS Issues

2008-01-06 Thread zodman
define as /srv/ your documentroot on apache virtualhost. change 755 permission to your /srv/abc/media dir put a symbolic link on /srv/media --> /srv/abc/media/ rember when the navegator search on django.abc.com/media/ search /media dir for /media/ location on your documentroot William

Re: CSS Issues

2008-01-06 Thread William Siegrist
bah, nevermind, I should try reading more carefully, as you're not using the test server. :) Sorry. Might be a conflict with using /media/ for both admin and static files? -Bill On Jan 6, 2008, at 9:12 PM, pacman wrote: Hi, I have a strange issue with my css not loading. CSS and Images

Re: CSS Issues

2008-01-06 Thread William Siegrist
Have you tried this yet? http://www.djangoproject.com/documentation/static_files/ -Bill On Jan 6, 2008, at 9:12 PM, pacman wrote: Hi, I have a strange issue with my css not loading. CSS and Images seem to work fine for the admin portion of the site but when I try to add my own CSS it

CSS Issues

2008-01-06 Thread pacman
Hi, I have a strange issue with my css not loading. CSS and Images seem to work fine for the admin portion of the site but when I try to add my own CSS it can't seem to find it. my variables look as such: MEDIA_ROOT = '/srv/abc/media/' MEDIA_URL = 'http://www.abc.net/media/' ADMIN_MEDIA_PREFIX

Re: Calling a method from the base template

2008-01-06 Thread Peter Rowell
> There is a mechanism available > for that -- context processors -- but people don't want to use it > because they want *something else* that happens for every template. Malcolm's absolutely correct: context processors (I mis-typed when I said content processors) is exactly what you want here.

Re: Calling a method from the base template

2008-01-06 Thread Kenneth Gonsalves
On 06-Jan-08, at 11:01 PM, Michael Hipp wrote: > Attempting to do a method call {% views.get_stuff %} just results > in a 'bad > tag' error. > > Doing it like a variable {{ views.get_stuff }} just seems to be > ignored. make a templatetag -- regards kg http://lawgon.livejournal.com

urlField Broken ever

2008-01-06 Thread zodman
0.97-pre-SVN-unknown rev 7003 i have a proble with de urlfield broken link im make a model as app1 this model haves a UrlField urlflyer = models.URLField("Direccion de la imagen",verify_exists=False) in my develop local server (python manage.py runserver) function fine But on my

Re: "unexpected indent" error not allowing me to add the poll app to the admin site

2008-01-06 Thread Darryl Ross
>> I was having problems with my text editor. For some reason Python >> didn't like the way it handled tabs/spaces. I stopped using tabs and >> started using spaces, and that seemed to fix the problem. Your solution of using spaces instead of tabs to indent worked perfectly! The python

Re: "unexpected indent" error not allowing me to add the poll app to the admin site

2008-01-06 Thread Chris Phillips
Elgringo- Your solution of using spaces instead of tabs to indent worked perfectly! Thank you for saving me additional hours of banging my head against the wall! On Jan 6, 7:06 pm, elgringo <[EMAIL PROTECTED]> wrote: > I just go that to work after wrestling with that for the past day or > two

Re: Django Book: The Django Administration Site

2008-01-06 Thread Mikey3D
Hi Elgringo, Thank you so much it works. :-) One question, why is that I have Auth and Sites are showing up when my "class Admin: pass" were wrong way of coding still works? Hi Ramiro, I wasn't sure what you mean by copy/paste error and inner class but Elgringo clearly what you were saying.

Re: GeoDjango - error running GDAL tests

2008-01-06 Thread David
Excellent. I just updated to 7003 and the error message is gone. I really appreciate your taking the time to help me with this. Cheers! -- David Hancock On Jan 6, 6:01 pm, tlp <[EMAIL PROTECTED]> wrote: > Hello David, > > I was not able to reproduce the error on any Linux, Windows or Solaris >

Error: (1241, 'Operand should contain 1 column(s)')

2008-01-06 Thread Rodrigo Culagovski
I am getting the following error: OperationalError at /lista/ (1241, 'Operand should contain 1 column(s)') Request Method: POST Request URL:http://127.0.0.1:8000/lista/ Exception Type: OperationalError Exception Value:(1241, 'Operand should contain 1 column(s)')

Re: Dynamic forms fields

2008-01-06 Thread Jeff Anderson
[EMAIL PROTECTED] wrote: > The number of features can grow or decrease depending on the user type > so I can't create a static form class with all the features listed. > > Can someone please help to do this. > Sure! I believe this will be a decent starting point for you:

Dynamic forms fields

2008-01-06 Thread [EMAIL PROTECTED]
Hello, I have a database table with a list of features that a user can enable, so I would like to create a form like: Feature1 [ ] Enable [ ] Disable Feature2 [ ] Enable [ ] Disable Feature3 [ ] Enable [ ] Disable Feature4 [ ] Enable [ ] Disable The number of features can grow or

Re: Simple architecture question

2008-01-06 Thread Malcolm Tredinnick
On Sun, 2008-01-06 at 15:51 -0800, Pete McVicar wrote: [...] > Because Django already has the concept of groups/permission my > immediate reaction would be to extend the admin interface to allow > ordinary People to create and mange groups this way. However, from > what I've read that would

Re: Is there a way to limit the number of element in the template

2008-01-06 Thread Alex Koshelev
I'm realy glad:) On 7 янв, 03:15, "Alexandre Forget" <[EMAIL PROTECTED]> wrote: > you are right ! it works now, thanks > > django fresh from svn > > On Jan 6, 2008 7:10 PM, Alex Koshelev <[EMAIL PROTECTED]> wrote: > > > > > Note you must delete *all* spaces in filter expression > > >

Re: Calling a method from the base template

2008-01-06 Thread Malcolm Tredinnick
On Sun, 2008-01-06 at 16:12 -0600, Michael Hipp wrote: > Peter Rowell wrote: [...] > > I recommend rethinking how data is passed into and used in your > > templates. Consider creating your own content processor. Or maybe some > > custom template tags and/or filters. See > >

Re: Is there a way to limit the number of element in the template

2008-01-06 Thread Alexandre Forget
you are right ! it works now, thanks django fresh from svn On Jan 6, 2008 7:10 PM, Alex Koshelev <[EMAIL PROTECTED]> wrote: > > Note you must delete *all* spaces in filter expression > > part.forum.thread_set.all|slice:":5" > > And what is your django version? > > On 7 янв, 02:55, "Alexandre

Re: Trying to display a list

2008-01-06 Thread Malcolm Tredinnick
On Sun, 2008-01-06 at 12:38 -0800, chiefmoamba wrote: > I'm sure this will be very easy for most of you... > > I am trying to display a list. [...] > If I view source, I get this: > > There are books > The title of your books: [, ] That's the default representation of a Python list: using

Re: Is there a way to limit the number of element in the template

2008-01-06 Thread Alex Koshelev
Note you must delete *all* spaces in filter expression part.forum.thread_set.all|slice:":5" And what is your django version? On 7 янв, 02:55, "Alexandre Forget" <[EMAIL PROTECTED]> wrote: > I tried with and without... no difference > > On Jan 6, 2008 6:32 PM, Alex Koshelev <[EMAIL PROTECTED]>

Re: Shared hosting with FastCGI, problems

2008-01-06 Thread Graham Dumpleton
On Jan 6, 9:23 pm, kbochert <[EMAIL PROTECTED]> wrote: > On Jan 5, 5:46 pm, Michael Hipp <[EMAIL PROTECTED]> wrote: > > > > > Hello, > > > I'm hoping to rework my website into Django, but am having trouble at my > > shared hosting provider (HostMonster). > > > They don't support mod_python, so

Re: Django Book: The Django Administration Site

2008-01-06 Thread elgringo
Like Ramiro says. It's an indentation issue. Your nested class Admin: pass statement needs to be one and only one level of indentation below the top class declaration for each class that you're defining: class Publisher(model.Model): ... class Admin: pass class Foo(model.Model):

Re: using re.sub with unicode string in response middleware

2008-01-06 Thread Malcolm Tredinnick
On Sun, 2008-01-06 at 15:25 -0600, Gary Wilson Jr. wrote: > It appears that at this point, response.content is a utf8-encoded bytestring. > I'm playing with a response middleware doing something like: > > MY_RE.sub(u'%s' % text, response.content) > > which raises a UnicodeDecodeError if

Re: "unexpected indent" error not allowing me to add the poll app to the admin site

2008-01-06 Thread elgringo
I just go that to work after wrestling with that for the past day or two as well. Python uses indentation instead of braces to show levels of code. So, the line "class Admin: pass" needs to be only one level of indentation in from the top class declaration. So, your code should be more like

RE: "unexpected indent" error not allowing me to add the poll app to the admin site

2008-01-06 Thread owen
Ummm. -Original Message- From: Chris Phillips <[EMAIL PROTECTED]> Sent: Sunday, January 6, 2008 6:50pm To: Django users Subject: "unexpected indent" error not allowing me to add the poll app to the admin site Hi all, I am following the online

Re: Is there a way to limit the number of element in the template

2008-01-06 Thread Alexandre Forget
I tried with and without... no difference On Jan 6, 2008 6:32 PM, Alex Koshelev <[EMAIL PROTECTED]> wrote: > > Have you put a space between "all" and filter mark? > > On 7 янв, 02:27, "Alexandre Forget" <[EMAIL PROTECTED]> wrote: > > update: it doesn't work in the for loop. > > > >

Simple architecture question

2008-01-06 Thread Pete McVicar
In the course of attempting to learn Django I've decided to attempt to build something resembling Flickr or Facebook groups, e.g Person creates an account, People can create a group/join a group, Person can post start a topic/post a comment if they belong to that group. Fairly basic stuff in the

"unexpected indent" error not allowing me to add the poll app to the admin site

2008-01-06 Thread Chris Phillips
Hi all, I am following the online tutorial and I am unable to add my app to the admin section. When I runserver I get: mysite.polls: unexpected indent (models.py, line 5) 1 error found Here is my models.py: from django.db import models class Poll(models.Model): question =

Re: Is there a way to limit the number of element in the template

2008-01-06 Thread Alex Koshelev
Have you put a space between "all" and filter mark? On 7 янв, 02:27, "Alexandre Forget" <[EMAIL PROTECTED]> wrote: > update: it doesn't work in the for loop. > > -- > TemplateSyntaxError at /parts/8051/ > > 'for' statements should use the format 'for x in y': for t in >

Re: Django Book: The Django Administration Site

2008-01-06 Thread Ramiro Morales
On Jan 6, 2008 5:10 PM, Mikey3D <[EMAIL PROTECTED]> wrote: > [...] > from django.db import models > > class Publisher(models.Model): > name = models.CharField(max_length=30) > address = models.CharField(max_length=50) > city = models.CharField(max_length=60) > state_province =

Re: Is there a way to limit the number of element in the template

2008-01-06 Thread Alexandre Forget
update: it doesn't work in the for loop. -- TemplateSyntaxError at /parts/8051/ 'for' statements should use the format 'for x in y': for t in part.forum.thread_set.all |slice: ":5" -- this is the offending line: {% for t in part.forum.thread_set.all |slice: ":5" %}

Re: Foreign key drop down not updating in newforms

2008-01-06 Thread makebelieve
On Jan 2, 9:48 am, Nathaniel Whiteinge <[EMAIL PROTECTED]> wrote: > On Dec 30 2007, 6:46 pm, makebelieve <[EMAIL PROTECTED]> wrote: > > > Part of a form of mine has a drop down to choose a region which is a > > foreign key to the object I'm updating.  Further, I have a link to add > > a new

Adam Gadahn (Azzam) # An Invitation To Reflection And Repentance # ((IMPORTANT VIDEO))

2008-01-06 Thread jihad
An Invitation To Reflection And Repentance ((IMPORTANT VIDEO)) Adam Yahiye Gadahn (Azzam) For the loading >>> clarity high 404MB http://www.archive.org/download/u5uwII/v.AVI http://www.archive.org/download/u7uwII/v.AVI http://www.archive.org/download/u8uwII/v.AVI

Re: SESSION_SAVE_EVERY_REQUEST creates new session?

2008-01-06 Thread Peter Rowell
Malcolm, please accept my apologies for 1/2 of the problem described in the original article. I, of all people (I wrote debuggers back in the 80's), should know that you have to vet your diagnostic tools before you depend on them. Short version: The high cookie creation frequency was real (I'm

Re: GeoDjango - error running GDAL tests

2008-01-06 Thread tlp
Hello David, I was not able to reproduce the error on any Linux, Windows or Solaris machines so I created a vmware image from scratch using the software versions you specified. The following are steps I took to recreate your problem. [Installation for setting up Whitebox Linux 3.0 with

Re: Is there a way to limit the number of element in the template

2008-01-06 Thread Alexandre Forget
On Jan 6, 2008 5:44 PM, Alex Koshelev <[EMAIL PROTECTED]> wrote: > > First of all, Part.objects.all()[:5] is still lazy. SQL query executes > only when you try to iterate through items. > And you can slice objects in template with "slice" filter > > {% for p in part.object.all|slice:":5" %} >

Re: Is there a way to limit the number of element in the template

2008-01-06 Thread Alex Koshelev
First of all, Part.objects.all()[:5] is still lazy. SQL query executes only when you try to iterate through items. And you can slice objects in template with "slice" filter {% for p in part.object.all|slice:":5" %} On 7 янв, 01:13, "Alexandre Forget" <[EMAIL PROTECTED]> wrote: > Hi, > > I need

Re: Django Book: The Django Administration Site

2008-01-06 Thread Mikey3D
Hi goober, I have done your suggestions before or I won't be able to create a superuser, right? I could login and there is no Ch6 but only Auth and Sites in Admin Interface. So I try again your suggestions: In command: python manage.py sql books "OR" python manage.py sqlall books > the same

Is there a way to limit the number of element in the template

2008-01-06 Thread Alexandre Forget
Hi, I need to limit the number of elements I have to display on an index page. Right now I do something like this in the template. {% for p in part.object.all %} ... {% endfor %} Witch obliviously output all objects in the set. In the view, I can do it this way: Part.objects.all()[:5] I

Re: Calling a method from the base template

2008-01-06 Thread Michael Hipp
Peter Rowell wrote: > It > would probably be better (for any number of reasons) if you put all of > these types of routines in a utils.py module and import/pass that. > E.g. > > import utils > return render_to_response('now.html', RequestContext(request, { > 'utils': utils, >

Re: Getting current user id

2008-01-06 Thread Florian Apolloner
The error message: Invalid value: 'user' should be a instance, not a clearly states you should use a User-instance and not an integer (long). You might wanna show us some code... And yes printing request.user reuturns the username, but that's caused by __unicode__ and has nothing to to with

Re: Getting current user id

2008-01-06 Thread Darthmahon
When I used request.user, it outputs the username of the currently logged in user. When I try and use this as part of the entry into the table, it won't let me as it's expecting an integer. Is that wrong? On Jan 6, 9:33 pm, Florian Apolloner <[EMAIL PROTECTED]> wrote: > You are doing something

Re: Getting current user id

2008-01-06 Thread Florian Apolloner
You are doing something like my_instance.author = request.user.id whereas you should do: my_instance.author = request.user. Why? You are working with the Django ORM and it doesn't expect you to give it an User-Id (although it get's saved as that in the db), but an instance of

using re.sub with unicode string in response middleware

2008-01-06 Thread Gary Wilson Jr.
It appears that at this point, response.content is a utf8-encoded bytestring. I'm playing with a response middleware doing something like: MY_RE.sub(u'%s' % text, response.content) which raises a UnicodeDecodeError if response.content contains non-ascii. I understand that the strings need to

Re: Getting current user id

2008-01-06 Thread Darthmahon
Thanks, should have guessed that! For some reason though it is returning the value as 11L. I just want it to return 11, as it is throwing up an error when trying to use it like that: Invalid value: 'user' should be a instance, not a I'm using a MySQL database, any way of stripping the L off

XML Rendering. Template issue - sub cats

2008-01-06 Thread shocks
Hello I've been using Django for a week. Really liking its flexibility. I'm using it to create a CMS for an ActionScript 3 app. The Flash will read an XML file outputed from Django and maintained through the admin interface. It's all working well but I have a problem structuring the XML

Re: Getting current user id

2008-01-06 Thread Alex Koshelev
User id - request.user.id On 6 янв, 23:43, Darthmahon <[EMAIL PROTECTED]> wrote: > Hi Guys, > > Been looking to get the current id of the user logged in everywhere > but can't seem to find how to do this. > > Basically in my views.py file I want to insert an entry into a table. > Part of this

Re: Trying to display a list

2008-01-06 Thread Alex Koshelev
{% if "book_list" %} - what is "book_list" ? It is string literal, so it is always True. You must write this: {% if book %} And if you want to print books: {{book|join:", "}} On 6 янв, 23:38, chiefmoamba <[EMAIL PROTECTED]> wrote: > I'm sure this will be very easy for most of you... > > I am

Re: Django Book: The Django Administration Site

2008-01-06 Thread goober
Mikey3D, I believe you need to seed the database by typing python manage sql or type python manage sqlall. The you need to type python manage syncdb db again. Cheeers. Did you run python manage syncdb? Did you run python manage sqlall? On Jan 6, 2:10 pm, Mikey3D <[EMAIL PROTECTED]> wrote: >

Getting current user id

2008-01-06 Thread Darthmahon
Hi Guys, Been looking to get the current id of the user logged in everywhere but can't seem to find how to do this. Basically in my views.py file I want to insert an entry into a table. Part of this insert requires the current logged in users id. The only bit of information I seem to be able to

Trying to display a list

2008-01-06 Thread chiefmoamba
I'm sure this will be very easy for most of you... I am trying to display a list. in views.py, I have: from mysite.books.models import Book from django.http import HttpResponse def book_list(request): book = Book.objects.all().order_by('title') return

Re: got unexpected keyword argument 'widget'

2008-01-06 Thread Steve Bergman
Never mind. Clearly, I was confusing my models with my forms. --~--~-~--~~~---~--~~ 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

got unexpected keyword argument 'widget'

2008-01-06 Thread Steve Bergman
I have a model field that I want to change the attrs on when displayed by newforms. I thought I could do something like: class Timesheet(models.Model): date = DateField(widget=forms.TextInput()) and then define my attrs in the widget. But syncdb is complaining: TypeError: __init__() got

Re: Calling a method from the base template

2008-01-06 Thread Peter Rowell
> Attempting to do a method call {% views.get_stuff %} just results in a 'bad > tag' error. Right, because there is no tag with the name 'views.get_stuff'. > Doing it like a variable {{ views.get_stuff }} just seems to be ignored. Not ignored, but it probably fails which the template engine

Django Book: The Django Administration Site

2008-01-06 Thread Mikey3D
Hi, I'm reading thoroughly the new django book and on page 86, the figure 6-2, why didn't the Django Administration Site showing Ch6 except only Auth and Sites showing? I have trying all morning to figure it out but can't. Here are my files: # Django settings for mysite project. DEBUG = True

Re: How to bind data to a form, and not make the validation fire

2008-01-06 Thread Alex Koshelev
"Initial" parameter can be a callable object. So you can create "lazy getter" for your initial data On 6 янв, 19:27, shabda <[EMAIL PROTECTED]> wrote: > But I need the initial data to be dynamic, so I can't just do > text = forms.CharField(widget = forms.Textarea, initial = 'sometext') > > I

Calling a method from the base template

2008-01-06 Thread Michael Hipp
This is probably really simple, but I'm not seeing it. I have my base.html and sub.html templates. The method that services the sub template does it's job fine. But in the base template I have a piece of content that is independent of the sub template. I have a get_stuff() method in views.py

Re: PyAMF nogo, try DjangoAMF

2008-01-06 Thread Joel Hooks
There was a couple bugs in pyAMF that they have squished as of yesterday. Great guys. http://joelhooks.com/?p=5 I'm still using the S2Flex2 RemotingService, but just because it works. On Jan 5, 8:56 am, akaihola <[EMAIL PROTECTED]> wrote: > DjangoAMF almost worked for us except for two

Re: How to bind data to a form, and not make the validation fire

2008-01-06 Thread shabda
But I need the initial data to be dynamic, so I can't just do text = forms.CharField(widget = forms.Textarea, initial = 'sometext') I assume I can do some thing along the lines of overriding __init__ for this form, passing the requored value from the view function and then using something like

Re: How to bind data to a form, and not make the validation fire

2008-01-06 Thread Doug B
> But I need the initial data to be dynamic, so I can't just do > text = forms.CharField(widget = forms.Textarea, initial = 'sometext') A form also has an initial argument. form=YourForm(initial={'formfield1': formvalue1,'formfield2':formvalue2})

Re: How to bind data to a form, and not make the validation fire

2008-01-06 Thread Todd O'Bryan
On Jan 6, 2008 11:27 AM, shabda <[EMAIL PROTECTED]> wrote: > > But I need the initial data to be dynamic, so I can't just do > text = forms.CharField(widget = forms.Textarea, initial = 'sometext') > > I assume I can do some thing along the lines of overriding __init__ > for this form, passing the

Re: ordering ForeignKeys

2008-01-06 Thread marcus
Just seen your answers. Thanks a lot. --~--~-~--~~~---~--~~ 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

Re: Shared hosting with FastCGI, problems

2008-01-06 Thread Michael Hipp
[EMAIL PROTECTED] wrote: >> AddHandler fastcgi-script .fcgi > > Is this the actual name of your fcgi script? Also, there seems to be a > space before ".fcgi", which doesn't seem right. That line came directly from ... http://www.djangobook.com/en/1.0/chapter20/

Re: SESSION_SAVE_EVERY_REQUEST creates new session?

2008-01-06 Thread Malcolm Tredinnick
On Sun, 2008-01-06 at 23:58 +1100, Malcolm Tredinnick wrote: > > On Fri, 2008-01-04 at 14:48 -0800, Peter Rowell wrote: > > It appears that setting SESSION_SAVE_EVERY_REQUEST = True is causing a > > new session to be created on each page access. > > I was intending to have a quiet evening at

Re: SESSION_SAVE_EVERY_REQUEST creates new session?

2008-01-06 Thread Malcolm Tredinnick
On Fri, 2008-01-04 at 14:48 -0800, Peter Rowell wrote: > It appears that setting SESSION_SAVE_EVERY_REQUEST = True is causing a > new session to be created on each page access. I was intending to have a quiet evening at home, but James Bennett convinced me to look at this instead. It should be

Re: Violate DRY in my models

2008-01-06 Thread Brot
Hello, thank you for the fast reply. This is what I am looking for. I know I had to add the fields redundantly, but the function is defined once now. ~Bernd On Jan 6, 1:30 pm, Nikolaus Schlemm <[EMAIL PROTECTED]> wrote: > Am Sonntag, 6. Januar 2008 13:04:38 schrieb Brot: > > > I have a few

Re: Violate DRY in my models

2008-01-06 Thread Nikolaus Schlemm
Am Sonntag, 6. Januar 2008 13:04:38 schrieb Brot: > I have a few models which have the same two fields. Based on these > fields there is always the same function in these models. But this > violates DRY. Is there another possibility for my function/models > > [...] > > Model Inheritance isn't

Form Validation ComboFields

2008-01-06 Thread [EMAIL PROTECTED]
Hello Django Users, I just started working with the form validation from the newforms library. Most of the options are very good documented and easy to implemend the only thing i'm missing is the ComboFields description. In the documentation they say you can look for an example in the unit tests

Re: Violate DRY in my models

2008-01-06 Thread Malcolm Tredinnick
On Sun, 2008-01-06 at 04:04 -0800, Brot wrote: > Hello, > > I have a few models which have the same two fields. Based on these > fields there is always the same function in these models. But this > violates DRY. Is there another possibility for my function/models Sono-ish, we'll have model

Violate DRY in my models

2008-01-06 Thread Brot
Hello, I have a few models which have the same two fields. Based on these fields there is always the same function in these models. But this violates DRY. Is there another possibility for my function/models

Re: Setup Help

2008-01-06 Thread Brett Parker
On 06 Jan 00:38, kbochert wrote: > I get: > > --sys_path-- > ['/home/ktb/py', (...) , '/opt/python/lib/python2.5/site-packages'] > ... > ImportError: No module named django.core.servers.fastcgi > > > If I do: > ls /home/ktb/py/django/core/servers > > I see the file fastcgi.py (among a few

Re: Setup Help

2008-01-06 Thread kbochert
Never mind. In my month of experience with Python, I never quite grasped that each module on the module path needs a __init__.py Ktb On Jan 6, 12:38 am, kbochert <[EMAIL PROTECTED]> wrote: > I am trying to set up Django on a shared site (OCSSolutions.com) using > FCGI. > Needless to say, it

Re: Shared hosting with FastCGI, problems

2008-01-06 Thread kbochert
On Jan 5, 5:46 pm, Michael Hipp <[EMAIL PROTECTED]> wrote: > Hello, > > I'm hoping to rework my website into Django, but am having trouble at my > shared hosting provider (HostMonster). > > They don't support mod_python, so Hostmonster said to add this to .htaccess > for FastCGI: > >

Gratis Erotikforum

2008-01-06 Thread adultdrink
Gratis Erotikforum http://www.flirt-base.at/wbb2/ 1000 Private Amateurgirls ! http://www.adult-drink.com/index1.html http://www.adult-drink.com/vorschau/Vorschau.jpg --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google

Re: How to bind data to a form, and not make the validation fire

2008-01-06 Thread Malcolm Tredinnick
On Sun, 2008-01-06 at 01:32 -0800, shabda wrote: > I have a form, to which I want to pass some data when it is first > dipalyed, > My form is, > class EditPage(forms.Form): > text = forms.CharField(widget = forms.Textarea) > edit_summary = forms.CharField() > > In my view I bind data to

How to bind data to a form, and not make the validation fire

2008-01-06 Thread shabda
I have a form, to which I want to pass some data when it is first dipalyed, My form is, class EditPage(forms.Form): text = forms.CharField(widget = forms.Textarea) edit_summary = forms.CharField() In my view I bind data to this form as if request.method == 'GET': page =

Re: How to mark a model attribute as safe?

2008-01-06 Thread Malcolm Tredinnick
On Sun, 2008-01-06 at 00:34 -0800, shabda wrote: > I have a model attribute of type TextField, where I am storing html > data. While displaying in template I do not want to escape it, and so > should mark this as safe. How can I do this? I read the link at >

Setup Help

2008-01-06 Thread kbochert
I am trying to set up Django on a shared site (OCSSolutions.com) using FCGI. Needless to say, it doesn't work. In my public_html directory, I place the file site.fcgi containing: #!/usr/bin/python import sys, os # Add a custom Python path. sys.path.insert(0, "/home/ktb/py/") print

How to mark a model attribute as safe?

2008-01-06 Thread shabda
I have a model attribute of type TextField, where I am storing html data. While displaying in template I do not want to escape it, and so should mark this as safe. How can I do this? I read the link at http://www.djangoproject.com/documentation/templates_python/#filters-and-auto-escaping , but

Re: SESSION_SAVE_EVERY_REQUEST creates new session?

2008-01-06 Thread Andrew
We're looking into this as well! 10K session rows in one day. Have you noticed the records being in multiples of seven? Also, in our slow query log we've noticed django performing a selection on the entire session table with no WHERE clause. Clues in the puzzle... On Jan 4, 11:51 pm,

Re: Shared hosting with FastCGI, problems

2008-01-06 Thread [EMAIL PROTECTED]
> AddHandler fastcgi-script .fcgi Is this the actual name of your fcgi script? Also, there seems to be a space before ".fcgi", which doesn't seem right. Michael Hipp wrote: > Hello, > > I'm hoping to rework my website into Django, but am having trouble at my > shared hosting provider