Re: I have a problem with the pagination with haystack and apache solr

2010-04-21 Thread Massimiliano della Rovere
What happens if you switch pagination off? On Mon, Apr 19, 2010 at 19:29, Ariel wrote: > Hi everybody: > I have a big problem with pagination using apache solr and haystack, this is > what it is happening: I have a site where the news are being indexing with > haystack and solr, but the problem

Re: where I can find good django video tutorial?

2010-04-21 Thread Thomas Schreiber
Also there are the archives from the conferences. There is more to wade through to find introductory material, but the talks are excellent nonetheless: http://djangocon.blip.tv/posts?view=archive&nsfw=dc http://pycon.blip.tv/posts?view=archive&nsfw=dc Thomas On Tue, Apr 20, 2010 at 13:41, Adnan S

Re: Getting a Blog included in the Django community aggregator

2010-04-21 Thread Daniel Roseman
On Apr 20, 3:36 pm, Russell Keith-Magee wrote: > Obviously this isn't an isolated problem - I'll see what I can do > about changing the advice on the community page so that Jacob's inbox > doesn't become a bottleneck. > > Yours, > Russ Magee %-) Without wishing to pile on, I'm in exactly the same

Re: Getting a Blog included in the Django community aggregator

2010-04-21 Thread Russell Keith-Magee
On Wed, Apr 21, 2010 at 4:28 PM, Daniel Roseman wrote: > On Apr 20, 3:36 pm, Russell Keith-Magee > wrote: >> Obviously this isn't an isolated problem - I'll see what I can do >> about changing the advice on the community page so that Jacob's inbox >> doesn't become a bottleneck. >> >> Yours, >> R

Is South 0.7.1 ready for django1.2?

2010-04-21 Thread Massimiliano della Rovere
I found nowhere information about compliancy of South 0.7.1 to the multiDB support of django 1.2 Did I overlook anything? -- 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 uns

Re: I have a problem with the pagination with haystack and apache solr

2010-04-21 Thread Ray McBride
How many results are returned when you search using the solr admin interface? Are you using the code that I posted for you previously? Ray On Apr 19, 6:29 pm, Ariel wrote: > Hi everybody: > I have a big problem with pagination using apache solr and haystack, this is > what it is happening: I ha

Re: Why not Django with FastCGI?

2010-04-21 Thread Tom Evans
On Wed, Apr 21, 2010 at 3:08 AM, Sven Svenson wrote: > I'm new to the Django world but it seems that FastCGI is not the > preferred way to deploy a Django application. Why is that? I've had > good success using FastCGI with Perl/Catalyst-based applications. > > Thanks. > > /sven > We use FastCGI

Re: Why doesn't my isinstance() work?

2010-04-21 Thread Daniel Roseman
On Apr 21, 7:08 am, Lachlan Musicman wrote: > Hola, > > I'm having trouble getting a subclass to trigger an isinstance(). Code below: > > model.py excerpt: > > from django.db import models > from django.forms import ModelForm > > class Author(models.Model): >   first = models.CharFiel

Using external dbs... is django 1.2 the best solution?

2010-04-21 Thread Massimiliano della Rovere
I am developing a web site that has some of its models in a private database (the one specified in settings.py, populated by the admin interface) but, it has to fetch and filter (etc) data from 2 different databases that are populated (data is added but never modified or deleted) in real-time by ex

Re: Using external dbs... is django 1.2 the best solution?

2010-04-21 Thread David De La Harpe Golden
On 21/04/10 11:21, Massimiliano della Rovere wrote: I am developing a web site that has some of its models in a private database (the one specified in settings.py, populated by the admin interface) but, it has to fetch and filter (etc) data from 2 different databases So what is you opinion, sh

Re: Is South 0.7.1 ready for django1.2?

2010-04-21 Thread Shawn Milochik
On Apr 21, 2010, at 4:35 AM, Massimiliano della Rovere wrote: > I found nowhere information about compliancy of South 0.7.1 to the > multiDB support of django 1.2 > > Did I overlook anything? > If by "overlook" you mean "not read the release notes," then yes. http://south.aeracode.org/docs/re

Re: Generate brochure pdf

2010-04-21 Thread Alessandro Ronchi
2010/4/20 cootetom : > django and and pisa are great for creating PDF's because you can > combine django's templating engine with pisa's HTML to PDF conversion. > Pisa uses the reportlab tool kit. http://pypi.python.org/pypi/pisa/ I think I can't use PISA because I need the pdf to be precise as pi

Re: Why doesn't my isinstance() work?

2010-04-21 Thread Torsten Bronger
Hallöchen! Daniel Roseman writes: > [...] > > This is the expected behaviour. You've asked for an Author object, > so that's what you've got. There's no way to tell from the Author > model that this particular instance of it is also an instance of > Translator. More and more I get the impression

Re: Running django on IIS

2010-04-21 Thread Nick
Hiya I have exactly the same problem as described here. Did you (or anyone) find a fix or workaround for this? Cheers! Nick. On Apr 14, 12:24 pm, Paweł Roman wrote: > > I suspect it is trying to import Http but can't. > > > Fire up python (Start -> Python Interactive Shell, or Start -> Run -

Re: Help with deployment

2010-04-21 Thread dononyx
import os import sys sys.path.append( '/Library/WebServer/Documents/') sys.path.append( '/Library/WebServer/Documents/ess/') print >> sys.stderr, sys.path os.environ['DJANGO_SETTINGS_MODULE'] = 'ess.settings' from django.core.handlers.wsgi import WSGIHandler application = WSGIHandler() On Apr

problem with twitter app

2010-04-21 Thread het.oosten
I am using python-twitter on my site. I have a problem when the Twitter site is down. This results in an error message. I did not found out if the users gets an error message or not. To use Twitter on my site I have this context_processors.py import datetime import time from django.conf import set

Re: Why doesn't my isinstance() work?

2010-04-21 Thread Tim Shaffer
Why should an author instance ever return True for isinsnace(author_instance, Translator). That's not really the way Python or Django are designed to work. Why not just check to see if the author instance has an associated translator instance? That's the proper way. See the docs on multi- table in

Re: Why doesn't my isinstance() work?

2010-04-21 Thread Torsten Bronger
Hallöchen! Tim Shaffer writes: > Why should an author instance ever return True for > isinsnace(author_instance, Translator). That's not really the way > Python or Django are designed to work. Yes, but normally, you have tools like type(instance) or instance.__class__. However, in Django, you d

Re: Why doesn't my isinstance() work?

2010-04-21 Thread Tim Shaffer
On Apr 21, 8:25 am, Torsten Bronger wrote: > Yes, but normally, you have tools like type(instance) or > instance.__class__.  However, in Django, you don't.  That's the > problem. Sure you do... >>> from website.blog.models import Entry >>> e = Entry.objects.all()[0] >>> e.__class__ >>> type(e)

Re: Using external dbs... is django 1.2 the best solution?

2010-04-21 Thread Massimiliano della Rovere
My deadline is 26th, May Anyway the program will constantly grow so, yes I've just finished adding some modifications to make it run on Dj1.2 On Wed, Apr 21, 2010 at 12:49, David De La Harpe Golden wrote: > On 21/04/10 11:21, Massimiliano della Rovere wrote: >> >> I am developing a web site that

Re: Why doesn't my isinstance() work?

2010-04-21 Thread Tom Evans
On Wed, Apr 21, 2010 at 2:15 PM, Tim Shaffer wrote: > On Apr 21, 8:25 am, Torsten Bronger > wrote: >> calls the method of the respective class of "instance".  However, in >> Django, >> >> for instance in RootClass.objects.all(): >>     instance.do_something() >> >> will *always* call RootClass.do

Re: Generate brochure pdf

2010-04-21 Thread derek
On Apr 21, 1:14 pm, Alessandro Ronchi wrote: > 2010/4/20 cootetom : > > > django and and pisa are great for creating PDF's because you can > > combine django's templating engine with pisa's HTML to PDF conversion. > > Pisa uses the reportlab tool kit.http://pypi.python.org/pypi/pisa/ > > I think I

Re: Extending admin views?

2010-04-21 Thread derek
On Apr 20, 10:48 pm, When ideas fail wrote: > If i have an admin form and want to transform some data to another > format using AJAX within the form, what is the best way to do this. In > a normal form I can do this within the view but is there any way to > extend admin views to add new functional

Re: Why doesn't my isinstance() work?

2010-04-21 Thread Tim Shaffer
On Apr 21, 9:28 am, Tom Evans wrote: > On Wed, Apr 21, 2010 at 2:15 PM, Tim Shaffer wrote: > > On Apr 21, 8:25 am, Torsten Bronger > > wrote: > >> calls the method of the respective class of "instance".  However, in > >> Django, > > >> for instance in RootClass.objects.all(): > >>     instance.d

Re: modelForm ordering

2010-04-21 Thread derek
On Apr 20, 4:09 pm, darren wrote: > I am not able to figure out how to order the records that fill the > drop down list in a model form.  On line 112 below, I have attempted > to order the Rotation model by player.  But, the drop down list that > is created for me is not ordered that way.  I also

Re: Is there any way to create char data type in django.

2010-04-21 Thread derek
On Apr 20, 1:31 pm, Huang Stanley wrote: > Hi all: > > I try to find all fields but only IPAddressField is char data type, > but it's a fix-length char data type for 15 characters. > > Is there any field that I can use for this purpose. > > PS. I use django 1.2 beta 1 on Ubuntu. > > Thanks for you

Re: Is there any way to create char data type in django.

2010-04-21 Thread Huang Stanley
Finally, I find out that I can create my own datatype! (I use Django 1.2 beta 1.) in models.py: from django.db import models from django.db.models import * from django.utils.translation import ugettext_lazy as _ class myCharField(Field): def __init__(self, *args, **kwargs): self.max_

Re: Why doesn't my isinstance() work?

2010-04-21 Thread Tom Evans
On Wed, Apr 21, 2010 at 2:35 PM, Tim Shaffer wrote: > On Apr 21, 9:28 am, Tom Evans wrote: >> On Wed, Apr 21, 2010 at 2:15 PM, Tim Shaffer wrote: >> > On Apr 21, 8:25 am, Torsten Bronger >> > wrote: >> >> calls the method of the respective class of "instance".  However, in >> >> Django, >> >> >

Re: Why doesn't my isinstance() work?

2010-04-21 Thread Torsten Bronger
Hallöchen! Tim Shaffer writes: > [...] > a = Author(first="Tim", last="Shaffer") a.translator = Translator(language="English") a.editor = Editor(language="German") > t = Translator.objects.all()[0] > > This works as I would expect it to... > a.do_something() > "I'm going

Re: Best practice for serving restricted or premium media

2010-04-21 Thread Brad Buran
Thanks for the great suggestions. I believe that we will start out with shared hosting the migrate to a VPS (e.g. SliceHost) if scaling becomes an issue. We're not really expecting to become a high-traffic website (our target audience is small). I'm not familiar with any of these approaches, but

Re: Generate brochure pdf

2010-04-21 Thread cootetom
You are right though. In my experience, using Pisa to do HTML to PDF conversion isn't pixel perfect. On Apr 21, 2:29 pm, derek wrote: > On Apr 21, 1:14 pm, Alessandro Ronchi > wrote: > > > > > > > 2010/4/20 cootetom : > > > > django and and pisa are great for creating PDF's because you can >

Setting list_display for InlineModelAdmin

2010-04-21 Thread Brad Pitcher
Hi guys, This is driving me a little crazy, so I hope someone can offer good advice. I've specified an inline class in my admin.py file, and in it I have specified a subset of the classes attributes with list_display. However, what I set in list_display has no effect on what is rendered for the i

Re: Generate brochure pdf

2010-04-21 Thread thanos
I've been doing generating complex catalogs and books from django by using TeX or LaTex. Generating PDF from scratch is a pig. Its not much different from programming in postscript. Latex or Tex make life very easy and are very expressive. They are available on all platforms. I've been using TeX/L

app inheriting from others app's models.py

2010-04-21 Thread Alan
Hi there, I am adding a new app to django project and I thought about inheriting pretty much everything I can, so I did: from ccpngrid.models import GridJobForm from acpype.models import AcpypeJob class IsdJob(AcpypeJob): pass class IsdJobForm(GridJobForm): pass To my (bad) surprise,

add permission to new model instances

2010-04-21 Thread Adonis
hi, I think that what i am trying to do is NOT doable with django existing authentication or authority tools. Before developing my own code i thought of sharing it with the django community. I have a model called 'Layers'. I want a new permission to be created for each new entry in that table. Th

Re: app inheriting from others app's models.py

2010-04-21 Thread Shawn Milochik
You may want to use an abstract base class. If you're inheriting something from another application then they're probably not defined in that way, although it might be possible to subclass them as abstract in your own models.py and then subclass those. But the ORM nicely hides all of this from y

Re: add permission to new model instances

2010-04-21 Thread Shawn Milochik
This can easily be done with signals. http://docs.djangoproject.com/en/1.1/topics/signals/ And, it (rightly) won't be done in the view, because that leaves open the very likely chance of a problem if someone writes a new view and forgets to call your extra code. The only sticky problem at the

Re: Why doesn't my isinstance() work?

2010-04-21 Thread Tim Shaffer
I think then you will run into a problem with you add another media type: class WAVMedia(Media): file = models.CharField() def play(self): # do stuff >>> m = Media() >>> m.wavmedia = WAVMedia() >>> m.mp3media = MP3Media() >>> playlist = Playlist >>> playlist.media_set.append(m) for media

Re: Why doesn't my isinstance() work?

2010-04-21 Thread Tim Shaffer
Sorry, "class MP3Media(object):" should have been class "MP3Media(Media):" -- 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-

[ANN] django_nav release 0.5

2010-04-21 Thread Dj Gilcrease
Django Nav (http://code.google.com/p/django-nav/) extensible, non intrusive, fast system for generation navigation groupings. New in this release: Conditionals to show hide a nav option based on the result of a function call. There are 3 included conditionals to use as examples. arg and kwarg pas

overriding model save(), is an instance available?

2010-04-21 Thread Nick Serra
Hey everyone, thanks for looking. I'm overriding a model save(), and was wondering if there is an instance of the model being passed in that i can access. My situation is that i have a title and a slug. I only want to change the slug when the title is changed. So in my save i want to check: if s

Re: Why doesn't my isinstance() work?

2010-04-21 Thread Torsten Bronger
Hallöchen! Tim Shaffer writes: > [...] > > I think in both these cases (there is no person actually an > instance of "Person", and there should be no actual instance of > "Media"), it would be best to mark the parent class abstract and > use a generic relation (like you said) to join to either MP

Re: overriding model save(), is an instance available?

2010-04-21 Thread Shawn Milochik
One way: Override __init__ and setting self.old_title to be self.title. Then, in your save(), you can see if self.title != self.old_title. Shawn -- 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...

Seeking a Developer

2010-04-21 Thread Yudhvir
MediGrail.com LLC is seeking a Django developer to work in the Indivo X (IndivoHealth.org ) environment. Any language that supports oAuth and REST can be used - Python, PHP, Ruby. LEVEL This is a low-to-mid level developer position. Please respond with your experience, per hour expectation and ava

Re: Why doesn't my isinstance() work?

2010-04-21 Thread Tom Evans
On Wed, Apr 21, 2010 at 5:09 PM, Tim Shaffer wrote: > I think then you will run into a problem with you add another media > type: > > class WAVMedia(Media): >  file = models.CharField() >  def play(self): >    # do stuff > m = Media() m.wavmedia = WAVMedia() m.mp3media = MP3Media()

Re: Why doesn't my isinstance() work?

2010-04-21 Thread Tom Evans
On Wed, Apr 21, 2010 at 5:38 PM, Torsten Bronger wrote: > I think Django should store the fully qualified class name of each > row in the parent table.  For example, the "Person" table would have > a column with entries like "myapp.Author" or "myapp.Translator". > Then, a find_actual_instance meth

Re: overriding model save(), is an instance available?

2010-04-21 Thread Nick Serra
Thank you, that seems like a clean way to do it. I'm getting a weird error when overriding init though. When I simply do this: class Entry(models.Model): title = models.CharField(max_length=255) slug = models.SlugField(max_length=255) body = models.TextField() user

Re: Running django on IIS

2010-04-21 Thread CrabbyPete
I tried for a while, and finally switched to Apache on Windows. It works great and easy to set up. On Apr 21, 6:29 am, Nick wrote: > Hiya > > I have exactly the same problem as described here. > > Did you (or anyone) find a fix or workaround for this? > > Cheers! > Nick. > > On Apr 14, 12:24 pm,

Re: overriding model save(), is an instance available?

2010-04-21 Thread Shawn Milochik
You should probably call that super __init__ first thing. Otherwise the object won't really know how to behave like a Django model. Shawn -- 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...@googleg

Re: Email Field

2010-04-21 Thread CrabbyPete
Yes, but my problem is its defined in contrib.auth.User with no length, which I assume defaults to 60. Facebook proxy email address can be 90 characters long. On Apr 20, 11:03 am, "ge...@aquarianhouse.com" wrote: > did you try: > > email = models.EmailField(max_length=60) > > On Apr 20, 5:00 pm,C

Re: overriding model save(), is an instance available?

2010-04-21 Thread Nick Serra
Ahh, that'll do it. I'm used to the save() where you call super last. Works perfect, thanks for the solution! On Apr 21, 1:19 pm, Shawn Milochik wrote: > You should probably call that super __init__ first thing. Otherwise the > object won't really know how to behave like a Django model. > > Shaw

Re: Why doesn't my isinstance() work?

2010-04-21 Thread Torsten Bronger
Hallöchen! Tom Evans writes: > On Wed, Apr 21, 2010 at 5:38 PM, Torsten Bronger > wrote: > >> I think Django should store the fully qualified class name of >> each row in the parent table.  For example, the "Person" table >> would have a column with entries like "myapp.Author" or >> "myapp.Trans

Re: Setting list_display for InlineModelAdmin

2010-04-21 Thread Daniel Roseman
On Apr 21, 3:20 pm, Brad Pitcher wrote: > Hi guys, > This is driving me a little crazy, so I hope someone can offer good > advice.  I've specified an inline class in my admin.py file, and in it > I have specified a subset of the classes attributes with > list_display.  However, what I set in list

Re: problem with twitter app

2010-04-21 Thread het.oosten
I solved it making this context_processor.py: import datetime import time from django.conf import settings from django.core.cache import cache import twitter def latest_tweet( request ): tweet = cache.get( 'tweet' ) if tweet: return {"tweet": tweet} else:

Re: Problem with RSS feed. (Long Post)

2010-04-21 Thread Nuno Maltez
As you probably have found out by now, since you're using 1.1, just creat the templates feed/_description.html as mentioned in the docs for version 1.1: http://docs.djangoproject.com/en/1.1/ref/contrib/syndication/ On Wed, Apr 14, 2010 at 5:44 PM, Ronnie Betzen wrote: >> Have you tried the obv

bug in defaulttags.py ?

2010-04-21 Thread Paweł Roman
Hi I think I've found a bug in django.template.defaulttags.py get_nodes_by_type() is not implemented for IfEqualNode class. It seems like it should be implemented the same way as in IfNode. Check out this simple test: def test_get_nodes_by_type(self): template_string1 = "{%ifequal x

Re: Email Field

2010-04-21 Thread Tom Evans
On Wed, Apr 21, 2010 at 6:22 PM, CrabbyPete wrote: > Yes, but my problem is its defined in contrib.auth.User with no > length, which I assume defaults to 60. Facebook proxy email address > can be 90 characters long. > http://lmgtfy.com/?q=django+auth.User+email+truncating&l=1 Funnily, the OP the

loading fixtures in Oracle gives IntegrityError because of AUTH_PERMISSION table

2010-04-21 Thread pablo platt
Hi I'm migrating a django1.1 project from MySQL to Oracle xe. I've created fixtures in MySQL and I'm trying to load them to Oracle. When Trying to load the fixtures I'm getting: IntegrityError: ORA-1: unique constraint (USER.SYS_C004253) select TABLE_NAME, COLUMN_NAME from user_cons_columns w

Re: Why doesn't my isinstance() work?

2010-04-21 Thread Tom Evans
On Wed, Apr 21, 2010 at 6:59 PM, Torsten Bronger wrote: > But I think that it's not too expensive if by default Django stored > both the PK and the actual model name in the parent table. > Additionally, find_actual_instance should be built-in based on this > additional column. > > After all, I've

Re: loading fixtures in Oracle gives IntegrityError because of AUTH_PERMISSION table

2010-04-21 Thread pablo platt
When I'm creating the fixtures without contenttypes and auth and loading the fixtures in Oracle I'm not getting an error but nothing is being loaded: python manage.py dumpdata --exclude=contenttypes --exclude=auth > fixture.json On Wed, Apr 21, 2010 at 9:24 PM, pablo platt wrote: > Hi > > I'm m

Re: loading fixtures in Oracle gives IntegrityError because of AUTH_PERMISSION table

2010-04-21 Thread Tom Evans
On Wed, Apr 21, 2010 at 7:24 PM, pablo platt wrote: > Hi > > I'm migrating a django1.1 project from MySQL to Oracle xe. > I've created fixtures in MySQL and I'm trying to load them to Oracle. > When Trying to load the fixtures I'm getting: > IntegrityError: ORA-1: unique constraint (USER.SYS_C

Re: Email Field

2010-04-21 Thread Nick Serra
I think i ran into this issue before. I don't think they define a max_length anywhere, the restriction is just on the database. Just increase the field size in the database and you should be good. On Apr 21, 2:20 pm, Tom Evans wrote: > On Wed, Apr 21, 2010 at 6:22 PM, CrabbyPete wrote: > > Yes,

Re: loading fixtures in Oracle gives IntegrityError because of AUTH_PERMISSION table

2010-04-21 Thread pablo platt
Following your advice I did the following: 1. dumpdata while connected to MySQL: python manage.py dumpdata > fixture.json 2. Created a new Oracle user with an empty schema and switch the db connection to Oracle (didn't do syncdb) 3. loaddata to Oracle with: python manage.py loaddata fixture.json I

Re: bug in defaulttags.py ?

2010-04-21 Thread Karen Tracey
On Wed, Apr 21, 2010 at 2:09 PM, Paweł Roman wrote: > I think I've found a bug in django.template.defaulttags.py > > get_nodes_by_type() is not implemented for IfEqualNode class. It seems > like it should be implemented the same way as in IfNode. > > [snip] > I'm almost sure this missing implement

Re: Setting list_display for InlineModelAdmin

2010-04-21 Thread Brad Pitcher
Thank you for setting me straight. What a dumb mistake. :) On Apr 21, 11:03 am, Daniel Roseman wrote: > On Apr 21, 3:20 pm, Brad  Pitcher wrote: > > > Hi guys, > > This is driving me a little crazy, so I hope someone can offer good > > advice.  I've specified an inline class in my admin.py fil

Re: bug in defaulttags.py ?

2010-04-21 Thread Paweł Roman
> 1.2 does not exist yet so I'm not sure what you mean when you say you > checked there. Current SVN is certainly different from 1.0 and 1.1 in this > area, see changeset 12654: > > http://code.djangoproject.com/changeset/12654 > > Does that change fix the problem you are referring to here? Yup.

Re: Generate brochure pdf

2010-04-21 Thread Alessandro Ronchi
I need to give the user some jpg previews of the results. What's the lightest way to do that? I think reportlab or tex/latex are my only choices. I made my university thesis on latex, and I remember some problems with encoding (solved, finally, with utf8) and graphics to include. I really don't

fastcgi path problems

2010-04-21 Thread Francis Gulotta
I'm deploying my first django app. I'm familiar with nginx and fastcgi's. Currently I get a 404 page regardless of the url and for some reason a double slash For http://www.site.com/admin/ Page not found (404) Request Method: GET Request URL: http://www.site.com/admin// My urls.py from the de

GUI builder for django

2010-04-21 Thread John Finlay
I'm just getting started with django coming from a background of developing desktop apps on *nix. Is there something equivalent to a GUI builder for django? Alternatively, is there a good WYSIWYG html editor that produces editable html so I could quickly create a template and then retrofit it

coltrane sample at "practical django projects" book has a templates error

2010-04-21 Thread xota
Or I do something bad, I was searching in google and some pepople have same/similar error without replies, can you help me, this is my error: Caught an exception while rendering: Reverse for 'coltrane_category_list' with arguments '()' and keyword arguments '{}' not found. If you need more info,

send_mail being a royal jerk

2010-04-21 Thread Nick
I am working on a form that takes a little data and throws it in a database, but before all that jazz it sends an email to a list/tuple of recipients. This is going very well except the send_mail process is raising a very annoying and persistent error: "to" argument must be a list or tuple Here i

Re: GUI builder for django

2010-04-21 Thread andres osinski
No, and it's not a good idea to do WYSIWYG development for HTML. HTML is not a format that produces static content; it varies depending on screen fonts, browser, and platform, and getting that right means sticking to relative layout, making content flow, and taking care of quirks. WYSIWYG editors d

propagating values up the template chain

2010-04-21 Thread David Koblas
I ask this question knowing that it's almost anti-django template patterns, but I ask after spending the last few hours trying to figure a way to shoe horn this functionality in. The basic idea is that I would like to say something like this: {% extends "base.html" %} {% block content %} {%

Re: GUI builder for django

2010-04-21 Thread John Finlay
Does everyone code the html and css by hand for their templates? That seems very time consuming and tedious. Desktop apps have the same issues with variations of languages, fonts, etc. and resizing and the layout containers and other widgets provide for dynamic changes. GUI builders make it ea

Re: GUI builder for django

2010-04-21 Thread Javier Guerra Giraldez
On Wed, Apr 21, 2010 at 5:52 PM, John Finlay wrote: > Does everyone code the html and css by hand for their templates? That seems > very time consuming and tedious. every developer i know does. > Desktop apps have the same issues with variations of languages, fonts, etc. > and resizing and the l

Re: Best practice for serving restricted or premium media

2010-04-21 Thread Graham Dumpleton
On Apr 22, 12:10 am, Brad Buran wrote: > Thanks for the great suggestions.  I believe that we will start out with > shared hosting the migrate to a VPS (e.g. SliceHost) if scaling becomes an > issue.  We're not really expecting to become a high-traffic website (our > target audience is small). >

Re: send_mail being a royal jerk

2010-04-21 Thread Karen Tracey
On Wed, Apr 21, 2010 at 6:09 PM, Nick wrote: > I am working on a form that takes a little data and throws it in a > database, but before all that jazz it sends an email to a list/tuple > of recipients. This is going very well except the send_mail process is > raising a very annoying and persisten

Re: propagating values up the template chain

2010-04-21 Thread Tim Shaffer
Can you put the whole script tag in a block? = template.html = {% block extra-js %} {% endblock %} = base.html = {% block extra-js %}{% endblock %} -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django

Re: GUI builder for django

2010-04-21 Thread Mike Dewhirst
On 22/04/2010 8:10am, andres osinski wrote: No, and it's not a good idea to do WYSIWYG development for HTML. HTML is not a format that produces static content; it varies depending on screen fonts, browser, and platform, and getting that right means sticking to relative layout, making content flow

Re: propagating values up the template chain

2010-04-21 Thread David Koblas
I'm doing that in a few other place (setting the page title, for example). The problem is that I would like to have the extended inside of a block and potentially conditionally (e.g. only include this JavaScript if you're not logged in). --koblas On 4/21/10 4:29 PM, Tim Shaffer wrote: Can y

Re: propagating values up the template chain

2010-04-21 Thread Tim Shaffer
You should be able to do both those with the block tag, unless I'm misunderstanding something, or you have some other requirement. {% extends "base.html" %} {% block content %} {% block extra-js %} {% if user.is_authenticated %} {% endif %} {% endblock %} ... more block content ... {% endblock %

User profile display problem in change user form

2010-04-21 Thread Jx
Hi, i'm new to django and i've met with some problems when i'm trying to display custom fields in the change user admin page. Hope some of u can help me out. 1) I've a country table which is linked the user profile table that i created as below. --

Re: send_mail being a royal jerk

2010-04-21 Thread Nick
Thanks, Karen. Looks like I was a little cart before the horse on this portion of the project. On Apr 21, 6:28 pm, Karen Tracey wrote: > On Wed, Apr 21, 2010 at 6:09 PM, Nick wrote: > > I am working on a form that takes a little data and throws it in a > > database, but before all that jazz it s

Re: User profile display problem in change user form

2010-04-21 Thread Karen Tracey
On Wed, Apr 21, 2010 at 10:20 PM, Jx wrote: > [snip] > When i view the change user page, my country field is displayed as a > drop down box as intended, but the contents of the drop down box is > the "Country Object" instead of my intention to display the name of > the country. > > Your Country m

Re: User profile display problem in change user form

2010-04-21 Thread Jx
Thanks Tracey! it works :) yea actually i did the tutorial, i cant believe i missed out that part. Looks like i need more brushing up. On Apr 22, 10:36 am, Karen Tracey wrote: > On Wed, Apr 21, 2010 at 10:20 PM, Jx wrote: > > [snip] > > When i view the change user page, my country field is dis

DKIM Email

2010-04-21 Thread Simon Meers
For anyone else who learned about DKIM recently [1], I've uploaded a snippet for a DKIM-signing email backend [2]. [1] http://www.codinghorror.com/blog/2010/04/so-youd-like-to-send-some-email-through-code.html [2] http://www.djangosnippets.org/snippets/1995/ -- You received this message because

Re: Why doesn't my isinstance() work?

2010-04-21 Thread Lachlan Musicman
On Wed, Apr 21, 2010 at 19:33, Daniel Roseman wrote: >> >> Any tips? > > This is the expected behaviour. You've asked for an Author object, so > that's what you've got. There's no way to tell from the Author model > that this particular instance of it is also an instance of Translator. I presume

django bitwise operator

2010-04-21 Thread CCC
In django's modelManager I use oracle do bitwise operator,like: select * from MultiRoom m where bitand(m.groupidx,tem ) <> 0 and Now I want to change it to use django's orm ? anyone know how to write? Thanks -- You received this message because you are subscribed to the Google Groups "Django

Working for a startup.

2010-04-21 Thread Joe Goldthwaite
I've been working for a startup for a month or so. The main guy is enthusiastic about technology. He probably runs more applications on his computer than anyone I know. He also switched from a Windows background to a Mac notebook a year ago. He doesn't know a lot about web development or how it

Re: Working for a startup.

2010-04-21 Thread Eric Chamberlain
On Apr 22, 2010, at 12:40 AM, Joe Goldthwaite wrote: > I’d like examples of large systems written in Django or other open source > frameworks. I’d also like stories about companies who tried .net switched > over to open source. It seems like there was a big Microsoft project on some > stock

How to set the sucess message after inserting values to db in django admin site

2010-04-21 Thread Radhikavk
How to set the sucess message after inserting values to db in django admin site like message department added sucessfully model: class mdldepartments(models.Model): class Meta: verbose_name_plural = "Departments" verbose_name = "Department" property = models.ForeignKey(md