Django and flex, modpython and crossdomain.xml

2008-12-13 Thread coulix
Hello djangonauts, I am attempting to use Django and Flex. It went all good until i moved to mod_python on my local machine (127.0.0.1). If i try to upload from the flex component (swf comming from 127.0.0.1) to a django view (also on localhost) i get a security violation error 2048 from flex !

MarkSafe and widget rendering "/" disapeared

2008-12-15 Thread coulix
Hello Djangonauts, I have a custom widget to create a kind of group list which ommits the last "/" at the end of an input field. Making html validation to fail. The important code is here: rendered_cb = cb.render(name, option_value) print rendered_cb output.append(u'%s %s' % (

MarkSafe and widget rendering "/" disapeared

2008-12-15 Thread coulix
Hello Djangonauts, I have a custom widget to create a kind of group list which ommits the last "/" at the end of an input field. Making html validation to fail. The important code is here: rendered_cb = cb.render(name, option_value) print rendered_cb output.append(u'%s %s' % (

Re: Browser timeout on long processes

2008-08-20 Thread coulix
Yes, if you can check the Restfull book from Oreilly there is a good example on using a queue system to submit lengthy job. You submit the work and it gives you back an url that you can check 'repeatedly' to see the progress or completion of the job. Greg On Aug 20, 5:01 am, Julien Phalip <[EMAI

Re: FormWizard Problems

2008-08-23 Thread coulix
1. yes by overlriding the init class myForm(forms.ModelForm): def __init__(self, *args, **kwargs): super(myForm, self).__init__(*args, **kwargs) self.fields.keyOrder = ['foo', 'bar',...] 2. in the same way you could use self.fields['foo'].label = self.fields['foo'].help_text On Aug

Design question, Form using two models.

2008-08-30 Thread coulix
Hi, Like in many projects i use User from auth and my own Profile model. Except i have several profiles so Profile just holds a generic FK relationship; And ProfileFoo model has also a user Fk pointing back to User (its cleaner than using the generic reverse realtion which gives back a list) If

Re: looking for event registration/calendar modules

2008-09-11 Thread coulix
Hi, There was a django calendar app but it is in 'rewriting' right now and will be released soon (from what i heard). For now i built mine based on this snippest http://www.djangosnippets.org/snippets/129/ Greg On Sep 11, 5:59 pm, Marcus <[EMAIL PROTECTED]> wrote: > Hi -- django newbie here put

Re: The User mess

2008-09-12 Thread coulix
I m interested in these questions too. I had three completely different types of profile and i used a generic relationship on a CommeProfile model. I had to do stuff like: user.get_profile().content_object.profile_foo_attribute Its not too much of a pain but i wish there were some better ways. G

Re: django-recommender 0.2, with content based recs

2008-09-24 Thread coulix
Very nice, i was expecting something like this to be released soon, its such a nice book. All the calculation are done on the fly i guess, but it should not bet too hard to move this on a cron job or why not send it for calculation on EC2 for large data set. Good work ! --~--~-~--~~--

Form Wizard, using reverse to pass data to extra_context

2009-01-15 Thread coulix
Hi, I use a formWizard for a signup process: url(r'^signup/student/$', SignupStudentWizard([SignupForm, StudentForm]), {'extra_context':{"type":"student"}}, name='signup_student',), Now, used as it is it works fine. However in one case i need to pass extra_context data at run_time,

Re: Form Wizard, using reverse to pass data to extra_context

2009-01-16 Thread coulix
Perfect ! Then i just do a {% ifequal request.GET.extra_context "foo" %} and it works. Thanks On Jan 16, 3:10 am, Malcolm Tredinnick wrote: > On Thu, 2009-01-15 at 04:13 -0800, coulix wrote: > > Hi, > > > I use a formWizard for a signup process: >

File handling when not using POST form but service call (base64)

2009-03-15 Thread coulix
Hi all, I am using Pyamf to transfer a dynamically generated large image from Flex to Django. On the Django side i receive the encodedb64 data as a parameter: My Item model as an imagefield. What i have trouble to do is saving the data as the File Django Field. def save_item(request, uname, dat

Re: Beginner

2009-03-15 Thread coulix
You have to create a link "ln -s" for /usr/bin/django-admin.py pointing to /usr/lib/python2.5/site-packages/django/bin/django- admin.py Or you can do it the long way "python /usr/lib/python2.5/site-packages/ django/bin/django-admin.py startproject foo" On Mar 15, 3:26 pm, TP wrote: > I have jus

Re: File handling when not using POST form but service call (base64)

2009-03-15 Thread coulix
Solved using from djang.core.files.base import ContentFile Thanks to Guðmundur H On Mar 15, 3:21 pm, coulix wrote: > Hi all, > > I am using Pyamf to transfer a dynamically generated large image from > Flex to Django. > On the Django side i receive the encodedb64 data as a paramet

Dynamic Auth Backend and subdomains

2009-08-08 Thread coulix
Hello Pony Wizards, I am facing a use case where my authentication process is variable depending on the request.subdomain catched by a custom GetSubdomainMiddleware. AAA.example.com/login BBB.example.com/login In this case my subdomain is "AAA", I have the domain name in a model which also has

Re: Dynamic Auth Backend and subdomains

2009-08-10 Thread coulix
no clues or unclear ? :) On Aug 9, 1:44 am, coulix wrote: > Hello Pony Wizards, > > I am facing a use case where my authentication process is variable > depending on the request.subdomain catched by a custom > GetSubdomainMiddleware. > > AAA.example.com/login > BBB.examp

Contrib comments and removing fields for private comments

2009-03-27 Thread coulix
Hi, I am trying to have a simple comment form for loged in user with only one textArea field, I went the way of COMMENTS_APP = 'private_comments' insettings and using my own forms.py with the following code: class PrivateComment(CommentForm): def __init__(self, *args, **kwargs): sup

Django domain handling and shortcut url, strange

2009-04-02 Thread coulix
Hi, i have the following domain www.foo.com and an alias foo.com When i post a comment i want to redirect to the submit page so i use a wrapper for this: def comment_posted( request ): if request.GET.has_key('c'): comment = get_object_or_404(Comment, pk=request.GET['c']) retu

Re: Easy PDF generation using PISA HTML2PDF

2008-03-23 Thread coulix
Thanks ! Easier than reportlab :) Greg On Mar 23, 7:37 pm, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > Hi, > > I updated pisa which now includes a complete Django example. > > http://pypi.python.org/pypi/pisa/3.0.17 > > Enjoy it. > Dirk --~--~-~--~~~---~--~~ Y

Re: ImportError: MySQLdb-1.2.1p2 or newer is required; you have 1.2.1g3

2007-03-25 Thread coulix
Same problem, ImproperlyConfigured: Error importing middleware django.contrib.flatpages.middleware: "MySQLdb-1.2.1p2 or newer is required; you have 1.2.1g3" Apparently we need to upgrade Mysql, which is already the 5.0 on my host and no latest version is available, or put mysql_old in the setting

how could i weakly protect comments

2006-10-04 Thread coulix
Hello, i am using free comments in my app and starting to getting spam :) I dont want to use captcha yet and instead, use some content string scanning method. (sex, viagra, $$$ and other crap will not post the message). What is the best way to this ? exends comments view.py ? Thanks :) --~--~---

Re: how could i weakly protect comments

2006-10-04 Thread coulix
nice ! thanks everyone On Oct 5, 1:22 pm, "Waylan Limberg" <[EMAIL PROTECTED]> wrote: > On 10/4/06, coulix <[EMAIL PROTECTED]> wrote: > > > Hello, i am using free comments in my app and starting to getting spam > > :) > > I dont want to use ca

Re: Ajax

2006-10-08 Thread coulix
I use 4 text area on the same page there http://www.cefinban.net You can get the source here http://www.coulix.net/projects/cefinban/ Ramdas S wrote: > Hi, > > I tried to hack it via the admin base.html by including > the following code in the of the admin/base.html. > > * src="../jscripts/tiny_m

Freecomment need love, it doesnt likes "♥"

2006-10-10 Thread coulix
When i post a comment with " woot♥" it is display well in the comment preview but once posted appears at "woot?", why ? how to solve this ? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To po

Re: Freecomment need love, it doesnt likes "♥"

2006-10-10 Thread coulix
Thanks again, you show the right direction. On sqlite3 it is stored as "woot♥" On my dreamhost solution with mysql, it is stored as "woot?" MySQL client version: 5.0.16 MySQL charset: UTF-8 Unicode (utf8) :/ Any ideas of where to start ? --~--~-~--~~~---~--~~

Re: Django comments system and ajax

2006-10-10 Thread coulix
look here http://code.djangoproject.com/wiki/AjaxDjangoDojoForm --~--~-~--~~~---~--~~ 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

Source of Project using dojo and reportlab

2006-10-14 Thread coulix
Hello, I have to do a comparison between Java EE and what ever framework i like for a simple student report system. I started by Django since i dont know anything about java EE, and here is the result. To see it working http://www.coulix.net/demo Sources http://www.coulix.net/projects/student-re

Re: Alternate colors - when returing a list.

2006-10-19 Thread coulix
cycle around css class name. --~--~-~--~~~---~--~~ 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 email to [EM

Re: how are you handling i18n and m10l content?

2006-11-09 Thread coulix
i like this ! :) very pythonic. --~--~-~--~~~---~--~~ 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 email to

Re: Django + FastCGI Problems

2006-11-18 Thread coulix
mikeb i have the same problem it takes few minutes to come back and i see a lot of python process waiting for whatever. kill kill all ect have no effects. But once it runs its all good. mikeb wrote: > I just did that. Thanks for the pointer :) > > On Nov 18, 6:08 pm, "chasfs" <[EMAIL PROTECTED]>

Fast fcgi on dreamhost --> shauwn of the dead, help me shoot zombies

2006-12-02 Thread coulix
Hello guys, Since a month ago the website hosted on dreamhost was randomly down, for few minutes before i launch a new request or kill all python processes. e.g Tasks: 21 total, 1 running, 12 sleeping, 0 stopped, 8 zombie 3279 coulix 9 0 10976 10m 2612 S 0.0 0.5 0:00.08

Re: Fast fcgi on dreamhost --> shauwn of the dead, help me shoot zombies

2006-12-06 Thread coulix
I did the rename trick, still screw today. I will change my hosting pay a little bite more for a virtual server and set up apache + mod_python. i should have done this since the begining. On Dec 5, 2:38 am, "Phil" <[EMAIL PROTECTED]> wrote: > I stumbled across your post via jeffcrot.com and this

ORM and case study

2006-12-07 Thread coulix
Hello guys, i got an intern ship job in a trading company for summer. They have several servers, and plenty of logs with transactions id and states. My job is to parse all these stuffs get the timings of the states and build an interface to search look at specific transaction. The log are huge fr

Re: Catching m2m chnages

2006-12-11 Thread coulix
last time i look at it they were no solutions :/ --~--~-~--~~~---~--~~ 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 gro

Re: open source disk monitoring application written with Django

2007-01-15 Thread coulix
can we have screenshots :) ? --~--~-~--~~~---~--~~ 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 email to [E

django.po please try this

2006-05-15 Thread coulix
Hi i have a weid translation problem in setting.py language is fr-fr in a template foo i do {% load i18n %} then {% trans "Your name:" %} {% trans "Jumps to the admin page for pages that represent a single object." %} it outputs one non translated, one transalted : Your name: Renvoie à la page

Re: django.po please try this

2006-05-15 Thread coulix
solution: use msgfmt -f so ...po --~--~-~--~~~---~--~~ 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 e

Re: There is no v0.92 or v0.95 release of Django

2006-05-17 Thread coulix
i agree, its not clear at all. Documentation shows 0.95, but no 0.95 on the link. I have been using django long enough to guess i shoud take the svn trunk version but not everyone can do this. A solultin could be to put the doc 0.91 as main doc and the rest ad link on the top of the page (0.92 0.

Re: rss feeds from django handled differently by firefox

2006-06-13 Thread coulix
://127.0.0.1:8000/compte/coulix/ Cookie: sessionid=be7df207bc4edba9e0ca30f189d295aa; __utma=96992031.993593871.1150179699.1150193251.1150210787.4; __utmc=96992031; __utmz=96992031.1150179699.1.1.utmccn=(direct)|utmcsr=(direct)|utmcmd=(none) HTTP/1.x 200 OK Date: Wed Jun 14 00:15:52 2006 Server

overriding-default-model-methods what am i doing wrong ?

2006-06-20 Thread coulix
hello, simple problem : class Tag(models.Model): name = models.CharField(maxlength=200, core=True) total_ref = models.IntegerField(blank=True, null=True) class Admin: ordering = ['name'] def __str__(self): return self.name def get_absolute_url(self):

Re: overriding-default-model-methods what am i doing wrong ?

2006-06-22 Thread coulix
class Tag(models.Model): name = models.CharField(maxlength=200, core=True) total_ref = models.IntegerField(blank=True, null=True) class Admin: ordering = ['name'] def __str__(self): return self.name def get_absolute_url(self): return "/blog/tag/%s/" %

Re: overriding-default-model-methods what am i doing wrong ?

2006-06-22 Thread coulix
i mean never shows up --~--~-~--~~~---~--~~ 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 email to [EMAIL PRO

Re: overriding-default-model-methods what am i doing wrong ?

2006-06-22 Thread coulix
imported file used space.. i was puting tab. --~--~-~--~~~---~--~~ 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, s

save model method for a many to many relationship . how to.

2006-06-22 Thread coulix
Hello, normal schema for a blog app, entry and tag class : TAG class Tag(models.Model): name = models.CharField(maxlength=200, core=True) total_ref = models.IntegerField(blank=True, null=True) class Admin: ordering = ['name'] def __str__(self):

Re: overriding-default-model-methods what am i doing wrong ?

2006-06-22 Thread coulix
yes it was, thanks. --~--~-~--~~~---~--~~ 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 email to [EMAIL PROTE

Many to many and save() overiding method. Entry / Tags

2006-08-04 Thread coulix
Hello everyone, i am creating a django powered blog. Here is my simplified model class Entry(models.Model): [...] tags = models.ManyToManyField(Tag) def save(self): super(Entry, self).save() print self.tags.all() class Tag(models.Model):

Re: Many to many and save() overiding method. Entry / Tags

2006-08-04 Thread coulix
answer is there http://groups.google.com/group/django-users/browse_thread/thread/99680b69d2d4799c/07093d3695163269?lnk=gst&q=many+to+many+save&rnum=3#07093d3695163269 --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups

Re: How to use month/date/year menus for date?

2006-09-01 Thread coulix
Building a menu i dont know, bu getting the data yes exemple the month list of a Entry model with a create date field. month_list = Entry.objects.dates('created', 'month') --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google

Re: which css files are loaded?

2006-09-01 Thread coulix
A javascipt widget may load his own css file. --~--~-~--~~~---~--~~ 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,

Re: Need Template Tag help - I'm making this harder than it has to be.

2006-09-05 Thread coulix
A short cut register = template.Library() class SponsorsListNode(template.Node): def __init__(self, section, varname): self.section = section self.varname = varname def __repr__(self): return "" def render(self, context): context[self.varname] = Secti

UTF-8. french PO file, problem with august : Aôut.

2006-09-17 Thread coulix
Hello, Django.po in french locale has #: utils/dates.py:28 msgid "Aug." msgstr "Aôut" The file is encoded in UTF-8 (which is good). On my website which have setting fr-fr i do le {{ r.pub_date|date:"j M Y" }}, and get e 18 Ao? 2006. Ao? instead off Aôut ! see it: http://www.cefinban.net/recettes

Re: template and special character problem

2006-09-17 Thread coulix
Jorge Gajon wrote: > On 9/16/06, Phil <[EMAIL PROTECTED]> wrote: > > In the base.html template I added in the section a {% block > > extrahead %}{% endblock %}. > > And in the index.html template I added {% block extrahead %} > http-equiv="content-type" content="application/xhtml+xml; > > chars

Re: template and special character problem

2006-09-17 Thread coulix
puting DEFAULT_CHARSET to utf-8 didnt solve the Ao? != Aôut Not that only Aôut orm date generation is liek this all other accesnts in the template are fine. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django

Re: template and special character problem

2006-09-17 Thread coulix
Malcolm Tredinnick wrote: > On Mon, 2006-09-18 at 00:22 +0000, coulix wrote: > > puting DEFAULT_CHARSET to utf-8 didnt solve the Ao? != Aôut > > Not that only Aôut orm date generation is liek this all other > > accesnts in the template are fine. > > I haven't b

generic view how to know if a field is recquired

2006-01-31 Thread coulix
hi, i am writting a generic create object view for my recipe model. i can get the form display well using this kind of code : Nom de la recette {{form.nom}} ect .., But is there a way of automatically checking if {{ form.nom }} is a recquired field ? (and therefore put a star near it like this).

Re: help with urls not working on mod_python

2006-01-31 Thread coulix
i had to took of the leading ^ to make it works 127.0.0.1/cefinban/admin would not match any url if ^admin. SetHandler python-program PythonHandler django.core.handlers.modpython PythonPath sys.path+['/home/greg/Projects'] SetEnv DJANGO_SE

Re: generic view how to know if a field is recquired

2006-02-02 Thread coulix
do i have to hardcode it for every field ?

Re: generic view how to know if a field is recquired

2006-02-02 Thread coulix
ok thanks, i tried a similar thing to get the help admin part of a field to be display form.nom.formfield.help , doesnt seems to work.

Re: Tutorial out of date

2006-02-03 Thread coulix
I am more interested in the generic view for create template.

Tutorial out of date

2006-02-03 Thread coulix
http://www.postneo.com/2005/08/17/django-generic-views-crud I m following this method for my generic view, if there is any outdatted stuff can i know which of them.

generic view and {{ form.errors }}

2006-02-03 Thread coulix
hello, i am writting a basic form using 'django.views.generic.create_update.create_object', dict(info_dict, post_save_redirect="/recette/") ). It works all fine in my template ( http://django.pastebin.com/536725 ) until i decide to show errors, Allr eferences to {{ form.error_dict }} works perfe

_manipulator_validate_FOO() , i need help.

2006-02-04 Thread coulix
Where do we put the function ? I have a model for recipe, i want to validate the image field only, checking the file size as explain in one of the post here. do i have to write a whole manipulator with all the fields and a specific validator for image like in the documentation on "form and man

Re: _manipulator_validate_FOO() , i need help.

2006-02-05 Thread coulix
i just need an example of _manipulator_validate_foo(..).

Re: admin on "/" unable to find media

2006-02-14 Thread coulix
can i see your url.py, cause i had to take off the leading '^' to be able to recognize the admin part at /mysite/admin.

Template check if pluralize is true

2006-02-18 Thread coulix
{{ form.error_dict|pluralize }} works fine by adding an s, but for other languages like french its not good enought we have to adapt the article. le journal = les journaux (newspaper) so i m trying to check if my has several errors to display the appropriate message. This does work {% if {

Re: Template check if pluralize is true

2006-02-18 Thread coulix
... just needed to take of the brackets. --~--~-~--~~~---~--~~ 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

Validator, Form testing needed, cant validate image.

2006-02-19 Thread coulix
Hi, i wrote a form using my cutom Manipulator, all the check behave properly execpt the formfields.ImageUploadField(field_name="image_file", is_required=True, validator_list=[self.isValideImageWeight] ), it always raise [this field is recquired] . address to test the form : http://ozserver.no-i

Re: Validator, Form testing needed, cant validate image.

2006-02-19 Thread coulix
ok some news thanks to #django my model didnt specifie that the image field was needed but the manipulator did. so i updated the line to : formfields.ImageUploadField(field_name="image_file"), now when all recquired fields are present i got an error from django Exception Type: NotImpleme

Re: Validator, Form testing needed, cant validate image.

2006-02-19 Thread coulix
After a search ... i found this def save(self,data): Object=objects.get_object(pk=self.id) for field in self.fields: if field.field_name+'_id' in Object.__dict__: actual_field_name=field.field_name+'_id' else: actual_field_name=field.field_name Object._

Manipulator and views problem, where to save object ?

2006-02-20 Thread coulix
Hello, i have a simple goal, displaying a form, populate it, save it to the database. At the execption of a new validator to check the weight of the image sent. First point i need to write my own manipulator which is pretty much a copy of the model, i only want to add a validator to one field (i

Re: Manipulator and views problem, where to save object ?

2006-02-20 Thread coulix
Thank you !! i was overdoing it ! 2 lines of code. however the validator upon image_file doest seem to work. print recettes.AddManipulator().fields (thks for the trick) give me : [FormField "nom", FormField "categorie", FormField "auteur", FormField "ingredients", FormField "etapes", FormField

Re: Manipulator and views problem, where to save object ?

2006-02-20 Thread coulix
Hum i cant spot the type expect the 500 as comments ? i took off the line "from manipulators import RecetteManipulator" line since i dont need it anymore, it still doesnt raise the expected erro when the file is more than 100kb. hum maybe its somwthing to do with the form template print recett

Re: Manipulator and views problem, where to save object ?

2006-02-20 Thread coulix
Oh true, didnt get the 500 error howerver no way to raise the error isValideImageWeight. all the test get added, when i check in the admin view the field "image" is empty. Is there a way to see what value does all fields have before being inserted to the db, looks like image is empty... my model

Re: Manipulator and views problem, where to save object ?

2006-02-20 Thread coulix
spoted the proble, any validator added will just not work view.py #Validator def isFoo(self, field_data, all_data): raise validators.ValidationError, "!" def create_recette(request): manipulator = recettes.AddManipulator() manipulator.fields[8].validat

Re: Manipulator and views problem, where to save object ?

2006-02-20 Thread coulix
Seems like i was just unlucky in the number 5 - 6 - 8 if i use a field which appears in my model with ,null = True it seems like the validator is not eve called, is it a feature ? otherwise when its called i get an error : isFoo() takes exactly 3 arguments (2 given) Exception Location: /

How to implement this fucntionality ? (current page higlighting)

2006-02-21 Thread coulix
i have this website : http://ozserver.no-ip.com:345/cefinban/recette/1 i would like to highlight the menu link representing the current page, for example if its "contacts" , the ">> contacts link in the menu should be bold. using template i could load a different menu block for each page ? :/ an

Re: Manipulator and views problem, where to save object ?

2006-02-21 Thread coulix
I manage to save the image, first make sure to have : picture: {{form.image_file}} {{ form.image }} in your template then the view : #post a form def create_recette(request): manipulator = recettes.AddManipulator() #12 being image_fil , recettes.AddManipula

Re: How to implement this fucntionality ? (current page higlighting)

2006-02-21 Thread coulix
thanks ! thats cool --~--~-~--~~~---~--~~ 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 email to [EMAIL PROTE

Re: adding page

2006-02-21 Thread coulix
did you run pythob manage.py install flatpage ? --~--~-~--~~~---~--~~ 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

Re: adding page

2006-02-21 Thread coulix
how come it is looking for a template, is it wanted ? --~--~-~--~~~---~--~~ 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

Re: How to implement this fucntionality ? (current page higlighting)

2006-02-21 Thread coulix
d in each section of the site, assign a class to > the body tag based on the section you're in. > > Then you can create CSS rules for the "current" section something like this: > > .about #nav-about, .contact #nav-contact { font-weight:bold; } > > On 2/21/06, co

url.py parsing and mod_python, recurent problem.

2006-02-22 Thread coulix
hi, i ll just describe a basic installation of django on apache and point the strang behavior. django version : 0.91 Apache 2.0.54 Mod_python 3.1 + create a django project "cefinban" in /home/greg/django/ (django-admin.py startproject cefinban) + initialise everythng add a fake app model, and

Re: How to implement this fucntionality ? (current page higlighting)

2006-02-22 Thread coulix
Method 1 - the current page (or section) in the context. You can do it in your urls.py url.py : r'recette/$', 'cefinban.recettes.views.index',{'section': 'index'}), -> result in Exception Type: TypeError Exception Value:create_recette() got an unexpected keyword argum

Re: How to implement this fucntionality ? (current page higlighting)

2006-02-23 Thread coulix
Got it working, i was using some flatpage but since only flatpage.content or flatpage.title is possible if i wanted to define , since the flatpage template extend my base.html it would haev been anoying create som {{ block body }} and rewrite everything in the flatpage. so i deleted the flatpages

Built in comments half working, Template-loader postmortem error.

2006-03-05 Thread coulix
Hello, I tried to implement basic free comments into my web apps using the following links : http://www.rossp.org/blog/2006/feb/17/building-blog-django-3/ http://www.dobbes.com/blog/2005/jul/23/django_comments/ I got the "comments post comments" displaying well (check http://ozserver.no-i

Re: Built in comments half working, Template-loader postmortem error.

2006-03-05 Thread coulix
It seems to work only with the built in server from manage.py. Something wrong with my apache config ? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to djang

Re: Built in comments half working, Template-loader postmortem error.

2006-03-05 Thread coulix
current solution : ln -s ~/Projects/cefinban/templates/comments /usr/lib/python2.4/site-packages/Django-0.91-py2.4.egg/django/contrib/admin/templates/comments Any better fix .. ? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the G

Re: Built in comments half working, Template-loader postmortem error.

2006-03-06 Thread coulix
An other probel i didn' spot. the comments i thought i added for one object (recipe) only, are actualy mapped to all recipes. its like one comment aply to all entries ! even better, when i go to the admin part / free comments i get this : AssertionError at /cefinban/admin/comments/freecomments/

Re: Built in comments half working, Template-loader postmortem error.

2006-03-06 Thread coulix
FIXED : all of this was because of the slug field wich was pk. It needed ID to be pk, i therfore changed name and slug to unique. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this

url config and generic views and non generic views.

2006-03-11 Thread coulix
hello, if i want to use simple generic view only for certain url, but the normal view.py def for others how to combine both without errors. urlpatterns = patterns('django.views.generic.simple', (r'^cefinban/recettes/$', 'cefinban.recettes.views.index') (r'^cefinban/faq/$', 'direct_to_template

Re: url config and generic views and non generic views.

2006-03-11 Thread coulix
urlpatterns = patterns('', (r'^cefinban/recettes/$', 'cefinban.recettes.views.index'), ) urlpatterns.extend(patterns('django.views.generic.simple',r'^cefinban/login_ok/$', 'direct_to_template', {'template': 'login_ok'})) give me an error when accessing login_ok: __init__() takes at most

Re: url config and generic views and non generic views.

2006-03-11 Thread coulix
my mistake, urlpatterns.extend(patterns('django.views.generic.simple', (r'^cefinban/login_ok/$', 'direct_to_template', {'template': 'login_ok'})) ) forgot brackets. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Grou

using context_instance=DjangoContext(request) in generic view url.

2006-03-11 Thread coulix
hello i want to replace this view methods : def faq(request): return render_to_response('faq', {'section':'faq'}, context_instance=DjangoContext(request),) by a generic view in url.py, the problem is adding the extra_context part. urlpatterns.extend(patterns('django.views.generic.simpl

basic model with user foreign key.

2006-03-12 Thread coulix
from django.core import meta from django.models.auth import users ??? class Recette(meta.Model): slug = meta.SlugField("Slug", prepopulate_from=('nom',) ,unique=True, blank=True) nom = meta.CharField(maxlength=80,help_text=_('Nom de la recette'), unique=True) []

Re: using context_instance=DjangoContext(request) in generic view url.

2006-03-12 Thread coulix
hum to reformulate simpler, how can i tell in url.py to use generic.simple, and a extra_context which will replace context_instance=DjangoContext(request) i was using in my view method. def faq(request): return render_to_response('faq', {'section':'faq'}, context_instance=DjangoContext(r

Am i doing the right thing. Form working, advice needed.

2006-03-18 Thread coulix
Hello i was writing a changePasswordForm manipulator when i realised there were already one. The problem is that the raise Validator error message are in english. Is there a way to translate them ? apart of rewriting the class in my view. Now here is my mehod code in my application view.py what

Re: Am i doing the right thing. Form working, advice needed.

2006-03-18 Thread coulix
forgot this line in "if not errors" manipulator.save(new_data) --~--~-~--~~~---~--~~ 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

Re: Quick thanks to django team - I deployed my first app

2006-03-18 Thread coulix
please do. --~--~-~--~~~---~--~~ 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 email to [EMAIL PROTECTED] For

Re: Quick thanks to django team - I deployed my first app

2006-03-18 Thread coulix
do post a full example :) --~--~-~--~~~---~--~~ 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 email to [EMAIL

Re: Web framework frustration

2006-03-18 Thread coulix
i got the calendar js working fine in my app, copy all admin/js to your media folder. and you can even change the aspect of it by adding some css in your main shylesheet. now, i dont have the code anymore ... i remember i ahd to do a trick about the /js18/ stuff. --~--~-~--~~---

  1   2   >