Re: Categorize and List if Item Exists

2008-04-23 Thread andy baxter
andy baxter wrote: > you want a tag that would let you write an include file like: > > {% for category in categorybranch %} > sorry that should be {% for category in categorybranch.sub_cats %} > (print category name here) > {% include "self.html" with categor

Re: Categorize and List if Item Exists

2008-04-22 Thread andy baxter
Michael Ellis wrote: > Hello all, > > I have the following models: > > class Category(models.Model): > name = models.CharField(core=True, max_length=100) > parent = models.ForeignKey('self', blank=True, null=True, > related_name='child') > > class Product(models.Model): > name =

Re: A modeling/implementation quiz

2008-04-19 Thread andy baxter
Juanjo Conti wrote: > Hi all, > > I am worried about how to model the next scene (this is an example, but > an appropriated one): In the model we have People, and there are > different kind of people, let's say: Professors, Students and Other. > Each People object has a 'type' attribute. Type c

Re: users and profiles - model structure question

2008-04-18 Thread andy baxter
andy baxter wrote: > Alex Koshelev wrote: > >> I usually make link to User model not profile. And have no problems >> with usage. >> >> >> > I just tried switching to this way of doing it, and have come up against > a problem with gettin

Re: users and profiles - model structure question

2008-04-18 Thread andy baxter
Alex Koshelev wrote: > I usually make link to User model not profile. And have no problems > with usage. > > I just tried switching to this way of doing it, and have come up against a problem with getting the profile data into the template. If I create a list of all users in the view, then pa

users and profiles - model structure question

2008-04-18 Thread andy baxter
Hello, I have built a data model for a virtual library, which contains the following classes (among others): User - the built in user class from django.contrib.auth. Member - a profile for each user, containing extra information about each member. Item - a book, video, or music album Iteminsta

Re: Protecting static files

2008-04-17 Thread andy baxter
Nate wrote: > Hi all, > I've been googling for days and haven't really found a good solution > to my problem. > > I am building a site where a user can view photos and then choose > which of the photos they want to purchase. (Weddings/parties/HS > graduation etc...) My client doesn't want other us

Re: python manage.py runserver

2008-04-16 Thread andy baxter
[EMAIL PROTECTED] wrote: > when i run the command above it shows this message , what is the > problem i have successful installed django and i want step to run the > server and > $ python manage.py runserver > Validating models... > Unhandled exception in thread started by 0xb7a7995c> > Traceback

Re: Search Frameworks

2008-04-15 Thread andy baxter
brydon wrote: > I'm curious what people are currently using for search frameworks on > django based projects. I've done a fair bit of research here and > elsewhere and I still haven't landed on a clear decision. What are > people successfully using with django to get robust search > capabilities a

Re: Application Concepts

2008-04-15 Thread andy baxter
James Bennett wrote: > On Fri, Apr 11, 2008 at 1:09 PM, andy baxter > <[EMAIL PROTECTED]> wrote: > >> What /should/ be inside the project folder? >> > > I often get severely flamed for saying this, but: > > I very rarely have a "project folder&

Re: can i join your group

2008-04-13 Thread andy baxter
a.f wrote: > am intersting in web desgining & puplishing > e books & soft wear > seo & ather stuff > If you can read this, you're already subscribed to the group. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "D

Re: Images and Stylesheets

2008-04-12 Thread andy baxter
Greg Lindstrom wrote: > Hello Everyone- > > I started learning Django at PyCon in Chicago and have worked most of > the way through the "Django Book" and Sams "Teach Yourself Django", as > well as "Head First HTML with CSS and XHTML". It's been quite a lot > for this old dog, but I'd like to t

Re: Django on plesk - Virtual Host

2008-04-11 Thread andy baxter
Tim wrote: > I've got a couple Django apps running on Plesk. It's not the greatest > but it works. > > First, after you set up your subdomain, you'll need to create the > file: > /var/www/vhosts/ domain.fr/subdomains/django/conf/vhost.conf > > Here's the contents of mine: > -- > DocumentRo

Re: Application Concepts

2008-04-11 Thread andy baxter
James Bennett wrote: > On Tue, Apr 8, 2008 at 1:38 AM, jurian <[EMAIL PROTECTED]> wrote: > >> Are django applications meant to be implemented in such a manner as to >> allow the entire application directory to be copied into another >> project and used without having to alter any of the code

Re: unknown encoding: utf-8 error

2008-04-11 Thread andy baxter
Cephire wrote: > Thanks Karen. It helped. But I got another error. > > AttributeError: 'module' object has no attribute 'admin'. Searching > through the net, I found that __init.py__ should be present in the > directory. It does have __init.py__. > > Should all directories (like media, templates)

Re: Two sites, one django project

2008-04-11 Thread andy baxter
Hello, I've been thinking about this - probably the best way is if you can find something built into django (like the i18n framework) which will do this, but failing that you could try this: - for the templates, just have two sets of templates, one for each site. - for strings that are written

Re: middleware that works with Ajax

2008-04-10 Thread andy baxter
Jarek Zgoda wrote: > Chris Hoeppner napisaƂ(a): > > >> This is new to me. Dojo will be the official js toolkit for django? >> Above jQuery? How come? >> > > No. It was stated many times: Django would not have any "official js > toolkit" and will not "be bound to" or "embrace" any single to

Re: middleware that works with Ajax

2008-04-08 Thread andy baxter
Claudio Escudero wrote: > Hi, > > Someone knows there is any middleware that works with Ajax, similar to > RJS of Ruby on Rails? > Do you mean middleware specifically written for django? If so not sure, but it might be worth looking at dojo (http://www.dojotoolkit.org/). It is a javascript tool

Re: Whats wrong

2008-04-08 Thread andy baxter
Sarah Johns wrote: > Hello, im a newbie so sorry to bother anyone, but i have problems with > my site, i cant see the videos that i attached. whats wrong? Thanks > for the help, the site adress is this: http://www.videoriporter.hu > To be honest I thought your message was cleverly targetted spa

django security

2008-04-03 Thread andy baxter
hello, Is there any documentation online about security issues when using django? I'm assuming when writing code for my django app that I don't have to worry about things like quoting strings sent to the database because the django db api will already do that, but other things I'm not so sure

Re: Best practice for databases and distributed development with Django

2008-04-03 Thread andy baxter
andy baxter wrote: > > Not sure if it's quite an answer to your question, but I've been dealing > with a similar problem which is how to keep the test data I've added to > the system between (mostly minor) changes to the database. The approach > I've taken

Re: Best practice for databases and distributed development with Django

2008-04-03 Thread andy baxter
Julien wrote: > Hi, > > We're using SVN between several developers to work on the same project > and it's working quite well. But it's not as simple concerning the > database. > > Each of us has a local database to muck around with, and if one of us > makes a change in the models that implies modi

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 faste

Re: compiling files when installing to a web server

2008-03-29 Thread andy baxter
Michael Wieher wrote: > 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... > What was happening is every now and again mod_python (not django) would generate an erro

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 director

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

compiling files when installing to a web server

2008-03-29 Thread andy baxter
seem to be working. What is the right way to set this up? for example is there a python command you can run to force all the modules in a given path to compile? andy baxter. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Go

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

2008-03-28 Thread andy baxter
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 called 'current'? I'm planning on doing something similar with my a

not receiving email from the list

2008-03-28 Thread andy baxter
hello, I have subscribed successfully to the group, and can read it online, but I'm not receiving emails sent from the group, even though I have asked to when subscribing. Is this a known issue? Can any of you do anything about it or should I contact google? thanks, andy b

ImportError: No module named urls

2008-03-25 Thread andy baxter
line 161 I have checked that the django tutorial app still works, so the problem seems to be with what I've done rather than the django installation. any help appreciated. thanks, andy baxter. --~--~-~--~~~---~--~~ You received this message because you are

Re: dynamically assigning a field value

2008-01-08 Thread andy baxter
pinco wrote: > Hi, > > I'm trying to figure out how to solve the following issue without > succeed. > > I have a model like this: > > class Product(models.Model): >... >measure_cm = models.FloatField(...) >measure_in = models.FloatField(...) > ... > > The fields contain the same info

Re: static on separate what?

2007-12-09 Thread andy baxter
James Bennett wrote: > On Dec 8, 2007 10:57 PM, Carl Karsten <[EMAIL PROTECTED]> wrote: > >> I this text, does "separate Web server" contingent on a 2nd box? If it is >> only >> one box, the same Apache instance would be preferred, right? >> > > No, and no. > > You don't have to have sep

Re: Problem with the django tutorial

2007-12-05 Thread andy baxter
the admin interface, but >> on my system it isn't working - nothing changes on the admin page, even >> when I refresh the page or restart the server. >> >> Can anyone help with this? >> >> andy baxter. >> > > > > --~--~-~--~~

Problem with the django tutorial

2007-12-05 Thread andy baxter
ss Poll(models.Model): # ... class Admin: pass This is supposed to bring the Poll class into the admin interface, but on my system it isn't working - nothing changes on the admin page, even when I refresh the page or restart the server. Can anyone hel