django.views.generic.list_detail.object_list and coltrane url reverse lookups

2009-07-30 Thread andreas schmid
hi to all, im going through the practical django projects and i arrived at the part where im setting up generic views for the object listing of the categories. my problem now is that i have the navigation in the base.html which creates (or should) the url with Categories my urls.categories.

cab snippet add gives error

2009-08-03 Thread andreas schmid
hi, im trying to build the cab code sharing app with the practical django projects book, at the moment i have a problem adding snippets bc i get this error: http://dpaste.com/74671/ solutions? thx --~--~-~--~~~---~--~~ You received this message because you are su

Re: cab snippet add gives error

2009-08-03 Thread andreas schmid
dont know what it was but cleaning the tables and make a new sqlall cab solved the problem! prabhu S wrote: > Appears like a data type mismatch. Are you entering some string value > in a integer field or something of that sort? > > On Aug 3, 12:45 pm, andreas schmid wrote: >

problems with generic object_detail view

2009-08-06 Thread andreas schmid
hi, im trying to build an app which basically is based on the practical django projects weblog. my problem now is that i have a "Project" model and i can get the archive_index view but i cant solve the object_detail url and i dont understand where im doing wrong. my model: class Project(models

generic views - please bring me to the point

2009-08-07 Thread andreas schmid
hi all, im really going crazy now i cant figure out where the code is wrong... i have a really simple model: from django.db import models import datetime class Post(models.Model): title = models.CharField(max_length=250) excerpt = models.TextField(blank=True) body =

model get_absolute_url strange behaviour

2009-08-18 Thread andreas schmid
hi to all, i have a weird problem with my urls. my model has a get_absolute_url like this: * def get_absolute_url(self): return "%s/%s/" % (self.pub_date.strftime("%Y"), self.slug )* and the url conf is this one: *(r'^(?P\d{4})/(?P[-\w]+)/$', 'myapp.views.projects.project_detail',

Re: model get_absolute_url strange behaviour

2009-08-18 Thread andreas schmid
Daniel Roseman wrote: > On Aug 18, 11:08 am, andreas schmid wrote: > >> hi to all, >> >> i have a weird problem with my urls. >> >> my model has a get_absolute_url like this: >>* def get_absolute_url(self): >> return &quo

UnicodeEncodeError on csv export

2009-08-20 Thread andreas schmid
hi, i successfully made a csv export view for a queryset but i have the problem with some characters... how can i encode the queryset passed to the csv writer to solve my problem? #my csvexport.py import csv from django.http import HttpResponse from django.contrib.auth.decorators im

Re: UnicodeEncodeError on csv export

2009-08-20 Thread andreas schmid
t; http://docs.djangoproject.com/en/dev/howto/outputting-csv/ > > Kindly Yours > Marc > > On Aug 20, 12:06 pm, andreas schmid wrote: > >> hi, >> >> i successfully made a csv export view for a queryset but i have the >> problem with some characters...

question about custom save() and unique slug

2009-08-25 Thread andreas schmid
hi, i have a custom add method for a front end editing of my project model. now i have the problem that my url is composed by /year/slug and slug is set as unique for pub_date__year in the model. obviously this is not respected by my form so i want to check if the slug already exists for the giv

Re: unicode problem?

2009-08-26 Thread andreas schmid
take a look at that discussion: http://groups.google.com/group/django-users/browse_thread/thread/1de89cdee99b1086 lerner wrote: > def output(request): > response = HttpResponse(mimetype='text/csv') > response['Content-Disposition'] = 'attachment; filename=%s' % > 'address.csv' > t = l

remove fields from django.contrib.comments

2009-09-02 Thread andreas schmid
hi list, im trying to customise the django comment form and i have no problems subclassing the Comment model and add my custom fields but i would need to remove the name, url and email fields because i will let only logged in users add and see comments in my project and the app fills the fields i

django profiles question and http404

2009-09-03 Thread andreas schmid
hi, im trying django-profiles and i like it but im not understanding why if a profile does not exist it has to output a http404. i think it doesnt has really much sense because if a profile is not yet created or not public it shouldnt give a 404 but a "im sorry but the profile is not available be

practical django and snippet rating problems

2009-09-07 Thread andreas schmid
hi list, im experiencing problems with the rating functionality described in the code sharing site in the practical django projects book: if i try to get the score of a snippet with {{ object.get_score }} in the template i get a result like: {'rating__sum': -2} why is that? def g

Re: practical django and snippet rating problems

2009-09-07 Thread andreas schmid
hi karen, thank you for the answer! Karen Tracey wrote: > On Mon, Sep 7, 2009 at 5:45 AM, andreas schmid <mailto:a.schmi...@gmail.com>> wrote: > > > hi list, > > im experiencing problems with the rating functionality described > in the > c

questions about django-ratings

2009-09-11 Thread andreas schmid
hi , i have a few questions about how to use django-ratings but i dont really understand a few things: from djangoratings import RatingField class MyModel(models.Model): rating = RatingField(range=5) # 5 possible rating values, 1-5 that part is clear! then it comes to adding

django and model field translations

2009-09-14 Thread andreas schmid
hi list, i have to develop a multilingual site and it works well on a single language now... but i have to do it for 3 languages translating some fields of the models. can you give me some tips for good available apps? my usecase is very simple. if a model has fields * title * descript

Re: django and model field translations

2009-09-16 Thread andreas schmid
at a first look... >> >> is there anybody with a bit of experience using those apps which could >> me point to the right choice? >> >> thx >> >> On Sep 14, 1:54 pm, andreas schmid wrote: >> >> >>> hi list, >>> >>>

get the logged in user in my models custom save

2009-09-16 Thread andreas schmid
hi, can i get the actual logged in user in a custom save in my model? like: def save(self, force_insert=False, force_update=False): self.author = request.user self.slug = self.title.lower().replace(' ','-') super(Project, self).save(force_insert, force_update) tha

Re: get the logged in user in my models custom save

2009-09-17 Thread andreas schmid
David De La Harpe Golden wrote: > andreas schmid wrote: > >> hi, >> >> can i get the actual logged in user in a custom save in my model? >> >> like: >> >> def save(self, force_insert=False, force_update=False): >> self.author =

need help for a realted queryset

2009-09-17 Thread andreas schmid
hi, i have 3 models topic, project, technology. a topic contains projects and projects have technolgies. the 3 models are related to each other by foreignkeys in the project model. in the topic detail view i need to have the projects within the given topic which works with a wrapper around the o

Re: need help for a realted queryset

2009-09-17 Thread andreas schmid
that doesnt work here because im first looping trough every project in the given topic and of couse more projects have the same technology and it shows up multiple times. i guess i have to filter that in the view... mrts wrote: > > On Sep 17, 1:04 pm, andreas schmid wrote: > >&

developing and deploying django with zc.buildout

2009-09-21 Thread andreas schmid
hi list, i used buildout for a while now to create, develop and deploy plone sites. today i wanted to try it for django because i think being able to have repetible buildouts for projects is a nice thing and you dont have to get a headache between your local machine and the server setup. anyway

wierd apache and mod_python problem with templates

2009-09-22 Thread andreas schmid
hi, im expierencing a strange problem on my server with mod_pyton. while testing my project on the server launching it with runserver everything looks fine. using apache and mod_python the templates at the root of the templates dir in my project are loaded but all the others (templates/myprojec

Re: wierd apache and mod_python problem with templates

2009-09-23 Thread andreas schmid
thank you... i solved it using the django.wsgi script created by the buildout! its a lot easier deploy django with wsgi and not to mention how much better it is with a buildout in a clean isolated folder!! love it! Graham Dumpleton wrote: > > On Sep 22, 11:41 pm, andreas schmid

problems with mysql and wsgi

2009-10-09 Thread andreas schmid
hi, im experiencing problems with my project while im using mysql and wsgi. the problem happens when i want to create a user profile with an avatar. it works fine if i start the process with the runserver command. this is the error: http://www.pastebin.org/41177 OSError: [Errno 13] Permissi

Re: [solved] problems (with mysql and) wsgi

2009-10-09 Thread andreas schmid
right... i set write permissions to all for the folder /media/avatars and it works!! many thanks Bayuadji wrote: > Hi, > > On 10/9/09, aschmid wrote: > >> sry... mysql is not the problem. it should be a strict wsgi issue... >> anyway i cant understand the problem. could it be that root should

Re: Uploading an Image.

2009-10-11 Thread andreas schmid
i had the same issue a few days ago and i solved it by simply adding write permission to all for the given directory, not for the whole /media/ or even home. your error differs a bit from mine... does the directory /imageupload/ exist in /home/Djangoprojects ?? Chirolo wrote: > Hi Bayuadji. >

popup forms

2009-10-13 Thread andreas schmid
hi, how can i achieve a behaviour like in the admin backend where i can add a related object through a popup window and have it selectable after i saved the related form? for example: im copleting the form book and i have to select the author but it doesnt exist yet... so i click on the + (add)

Re: popup forms

2009-10-13 Thread andreas schmid
thx mate... but i need it on the front end ;) nabucosound wrote: > This is the default behaviour in Django Admin, dude... > > On Oct 13, 9:43 am, andreas schmid wrote: > >> hi, >> >> how can i achieve a behaviour like in the admin backend where i can add >&

Re: popup forms

2009-10-13 Thread andreas schmid
08). > > I hope this helps. > > - Andrew Ingram > > > > > > > 2009/10/13 nabucosound : > >> This is the default behaviour in Django Admin, dude... >> >> On Oct 13, 9:43 am, andreas schmid wrote: >> >>> hi, >>&g

Re: popup forms

2009-10-13 Thread andreas schmid
Emily Rodgers wrote: > > On Oct 13, 1:20 pm, andreas schmid wrote: > >> thank you very much for pointing me to the right path!! >> ill try to understand the behaviour and report about my progress... >> >> Andrew Ingram wrote: >> >>> I&#x

looking for simple comment app

2009-10-14 Thread andreas schmid
hi, im looking for a simple comment app. i need commmenting for instances only by logged in users and the author is obviously request.user, dont need any preview or whatever. maybe a mail notification on instances i commented on. what are you using? i tried django.contrib.comments but its alrea

Re: Custom Comments

2009-10-19 Thread andreas schmid
check this link: http://www.yashh.com/blog/2008/nov/21/django-comments-authenticated-users/ simonecare...@gmail.com wrote: > Post more information about errors you get, including you traceback. > It will be more helpful. > > Bye. > > On Oct 19, 4:34 pm, ToTmX wrote: > >> Hi, I'm new django us

form with loop over fields?

2009-11-11 Thread andreas schmid
hi , i need to create an input form with a input field for every month for lets say 10 years. so the form has 10*12 = 120 exact same input fields. is there a way to define the field only once or maybe define a year with 12 fields and loop over it to avoid having a huge model? thx --~--~---

Re: form with loop over fields?

2009-11-11 Thread andreas schmid
wrong). the values of the form should be stored and re-edited when necessary. that would be only a part of the whole thing, i implemented the rest of the form through a model and generating the form trough it. David De La Harpe Golden wrote: > andreas schmid wrote: > >> hi ,

Re: Imports, works from directory but not from file

2009-11-11 Thread andreas schmid
im experiencing the same problem. i started with a simple app and the modules.py was at the root of the app package, so everything was fine. now i extended the app and restructured the files in it by making a subfolder app/models and inside an __init__.py and the mymodel.py in the urls.py which i

Re: form with loop over fields?

2009-11-11 Thread andreas schmid
Nick Arnett wrote: > > > On Wed, Nov 11, 2009 at 6:48 AM, andreas schmid <mailto:a.schmi...@gmail.com>> wrote: > > > i would need something like: > > jan feb mar apr may > 2007 [...] [...]

Re: Imports, works from directory but not from file

2009-11-11 Thread andreas schmid
, rather than appending it, so that when you > mention a possibly installed app, such as django_microblogging, but > which you have customized in a copy in your apps folder, you can say > 'microblogging' in your INSTALLED_APPS and it will find yours rather > than the syste

Re: Imports, works from directory but not from file

2009-11-12 Thread andreas schmid
> or something else, but, especially on Windows, I don't take it for > granted that environment > settings will be properly respected/available. > im on a unix system and i can import it on the django shell but it makes troubles when running the django server which doesnt mak

Re: Making the case for Django (vs. Drupal)

2009-11-16 Thread andreas schmid
hi mike, sry i dont want to be unkind but could you please turn the mail delivery confirmation off when you write to a list?! thx Mike Ramirez wrote: > On Monday 16 November 2009 20:12:57 Kenneth Gonsalves wrote: > >> anyway, in pitching for django (in particular), python and postgresql in >>

Re: Multiple sites on a single server

2009-11-19 Thread andreas schmid
i would suggest to everyone start using buildout to develop or deploy. it gives so many advantages about separation between projects. a huge advantage is the repetibility of the project and you dont have to touch the pythonpath of your server, everything is done by the buildout configuration! Stod

Re: Translate models

2009-11-25 Thread andreas schmid
ciao alessandro, i am using transmeta for a project im developing and it seems to fit my needs. transmeta is easy to use and it creates a db column for every field you defined as translatable. the default and required language is the one you define as site language in settings.py, and its also the

strange style difference between development and production

2009-11-26 Thread andreas schmid
hi, i just noticed that the css is interpreted differently between my development environment on my local machine and the deployment on the server. locally i run the django project trough runserver and on production im using wsgi with apache. the proportions are all right but everything is bigge

Re: strange style difference between development and production

2009-11-26 Thread andreas schmid
rebus_ wrote: > 2009/11/26 andreas schmid : > >> hi, >> >> i just noticed that the css is interpreted differently between my >> development environment on my local machine and the deployment on the >> server. >> >> locally i run the django projec

distinct related objects

2009-11-26 Thread andreas schmid
hi, i have a question about retrieving related objects avoiding double entries. actually i have 3 models: topics projects technologies the projects model has foreignkeys to topics and technologies. i have a view for the topic detail like this: def topic_detail(request, slug):

Re: popup forms

2009-11-30 Thread andreas schmid
Emily Rodgers wrote: > > On Oct 13, 1:20 pm, andreas schmid wrote: > >> thank you very much for pointing me to the right path!! >> ill try to understand the behaviour and report about my progress... >> >> Andrew Ingram wrote: >> >>> I'm

Re: multilingual flatpages

2009-12-01 Thread andreas schmid
hi, i didnt work on that yet but i will in the next weeks because ill need the content translated on flatpages. wouldnt it be easier to subclass the flatpages model or to get the flatpages package and make the modifications there to get a custom_flatpages app? im thinkin that because im already u

inlineformset and related instance creation at once

2009-12-02 Thread andreas schmid
hi, im trying to create a form based on 2 models where model B will be a inlineformset related to model A. how can i tell the formset forms (model B) that the related instance is the just created instance based on model A? lets say i want to create the author and assign him many books in one shot

Re: inlineformset and related instance creation at once

2009-12-03 Thread andreas schmid
fa7f86?pli=1 > > which is about adding additional formset forms. > > > > On Dec 2, 4:59 pm, andreas schmid wrote: > >> hi, >> >> im trying to create a form based on 2 models where model B will be a >> inlineformset related to model A. >> how can i tell

Re: looping over forms in a formset

2009-12-03 Thread andreas schmid
ok ppl i need an advice about my form view: def myform(request): idea_form = ProjectideaForm activity_formset = inlineformset_factory(Projectidea, Activity, extra=5) if request.method == 'POST': form= idea_form(request.POST) formset = ac

Re: distinct related objects

2009-12-10 Thread andreas schmid
gt; It's a little hard to understand at first, but I think it's pretty > much what you're trying to do. You would be able to remove the > ".distinct" part of your query because dictionary keys are already > can't be doubled. > > Hope that helps. > >

Re: Raise error based on both form and inline_formset

2009-12-10 Thread andreas schmid
this is my form+formset and the validation/error display works for both at the same time. maybe you can get yours working by comparing it def myform(request): idea_form = ProjectideaForm activity_formset = inlineformset_factory(Projectidea, Activity, extra=5) if r

custom css class on all form fields

2010-05-19 Thread andreas schmid
hi, is it possible to programmatically add a custom css class to each label and field in a djangoform? i know i can add a class to a specific widget with attrs={} but i need such a class on all labels and fields for many forms. im using django newforms on appengine with its default version ...

Re: If Statements inside For Loops

2010-01-11 Thread andreas schmid
i think ifequal does not accept an else in the statement. Dave Merwin wrote: > I have the following: > > {% for group in user.groups.all %} > {{ group.name }} > {% ifequal group.name "subscribed" %} > I'm subscribed > {% else %} > {{ group.name }} > {% endifequal %}

Re: where to put the username password data

2010-01-24 Thread andreas schmid
in your projects settings.py harryos wrote: > hi > I was going thru bennet's practical django book..In the weblog app it > mentions that the DELICIOUS_USER ,DELICIOUS_PASSWORD values should be > set in settings file.The book mentions an import like > from django.conf import settings > When I look

which way to go?

2010-01-25 Thread andreas schmid
hi, i have to create a modificable database of parents and children (a tree basically). this is easy to achieve trough a modelclass with a Foreignkey to the model itself like: class Element(models.Model): title = models.CharField(max_length=50, unique=True) parent = models.ForeignKey('se

Re: which way to go?

2010-01-25 Thread andreas schmid
Daniel Roseman wrote: > On Jan 25, 2:30 pm, andreas schmid wrote: > >> hi, >> >> i have to create a modificable database of parents and children (a tree >> basically). this is easy to achieve trough a modelclass with a >> Foreignkey to the model itself li

Re: Models, forms and inlineformset

2010-01-27 Thread andreas schmid
is this an add or an edit form? or both? i have a similar inlineformset and i need to loop over the inline objects to set the foreignkey to the parent object like: if form.is_valid() and formset.is_valid(): # All validation rules pass new_idea = form.save(commit=False)

Re: Models, forms and inlineformset

2010-01-28 Thread andreas schmid
and your form works on edit too? i really cant understand why mine isnt... its giving me this MultiValueDictKeyError which i dont understand. Stefan Nitsche wrote: > On Wed, Jan 27, 2010 at 14:04, andreas schmid <mailto:a.schmi...@gmail.com>> wrote: > > is this an add o

Re: Models, forms and inlineformset

2010-01-28 Thread andreas schmid
rojectidea) return render_to_response('fslform/fslform.html', { 'form': form, 'formset': formset ,'add': False }, context_instance=RequestContext(request)) andreas schmid wrote: > and your form w

Re: popup forms

2010-01-28 Thread andreas schmid
askar Gara wrote: > Hi Andrew, Do you have any luck on this. I need same functionality. > > On Nov 30 2009, 5:40 am, andreas schmid wrote: > >> Emily Rodgers wrote: >> >> >>> On Oct 13, 1:20 pm, andreas schmid wrote: >>> >>>

Re: Models, forms and inlineformset

2010-01-30 Thread andreas schmid
Stefan Nitsche wrote: > > > On Thu, Jan 28, 2010 at 10:15, andreas schmid <mailto:a.schmi...@gmail.com>> wrote: > > and your form works on edit too? > i really cant understand why mine isnt... > > its giving me this MultiValueDictKeyError which

Re: Models, forms and inlineformset

2010-01-30 Thread andreas schmid
it works now :) thank you!! Stefan Nitsche wrote: > On Sat, Jan 30, 2010 at 11:23, andreas schmid <mailto:a.schmi...@gmail.com>> wrote: > > Stefan Nitsche wrote: > > > > > > On Thu, Jan 28, 2010 at 10:15, andreas schmid > mailto:a.schm

Re: how to work with css

2010-01-31 Thread andreas schmid
stylesheets are importet like ordinary html pages. you should provide more details like a code snippet and explain if you are experiencing these problems on development or production. chiranjeevi.muttoju wrote: > Hi, >I want to import the external style sheets in the template page. i > importe

Re: how to work with css

2010-01-31 Thread andreas schmid
u. > > On Mon, Feb 1, 2010 at 12:46 PM, andreas schmid <mailto:a.schmi...@gmail.com>> wrote: > > stylesheets are importet like ordinary html pages. > you should provide more details like a code snippet and explain if you > are experiencing these problems on develop

django and ldap

2010-02-03 Thread andreas schmid
hi, i need to authenticate users through ldap but i need also to store their preferences in the database, i cant really understand if django-auth-ldap (http://packages.python.org/django-auth-ldap) only authenticats the users over ldap or if it creates a real user object in django. i even found th

Re: django and ldap

2010-02-03 Thread andreas schmid
tarts, i get no error messages, no success messages, no users in the db, really no signal at all. how can i check if i am connected or not? what is the username if i dont set it explicitly in the AUTH_LDAP_USER_ATTR_MAP? David De La Harpe Golden wrote: > On 03/02/10 13:41, andreas schmid wrote: >

Re: django and ldap

2010-02-03 Thread andreas schmid
thanks... ill check this asap. David De La Harpe Golden wrote: > On 03/02/10 14:45, andreas schmid wrote: > > >> AUTH_LDAP_BIND_DN = "" >> AUTH_LDAP_BIND_PASSWORD = "" >> AUTH_LDAP_USER_SEARCH = LDAPSearch("dc=example,dc=

Re: django and ldap

2010-02-04 Thread andreas schmid
@brad: can you show me some sample code for this? @david: i tried different configuration options but with no luck, i can bind and search manually over python-ldap so i can definitely connect. ive seen that the requirements for django-auth-ldap are python2.3 and django1.0 so maybe thats one of th

Re: django and ldap

2010-02-04 Thread andreas schmid
Mike Dewhirst wrote: > On 4/02/2010 11:14pm, David De La Harpe Golden wrote: >> On 04/02/10 08:33, andreas schmid wrote: >>> @brad: can you show me some sample code for this? >>> > > David > > I am using Peter Herndon's django-ldap-groups successfu

Re: django and ldap

2010-02-05 Thread andreas schmid
ok django-ldap-groups works perfectly now! Mike Dewhirst wrote: > On 4/02/2010 11:14pm, David De La Harpe Golden wrote: >> On 04/02/10 08:33, andreas schmid wrote: >>> @brad: can you show me some sample code for this? >>> > > David > > I am using Peter He

Re: RequestContext and user.is_authenticated confusion

2010-02-14 Thread andreas schmid
Kev Dwyer wrote: > On Sun, 14 Feb 2010 01:19:41 -0800, Achim Domma wrote: > > >> Hi, >> >> depending on if a user is logged in or not, I want to display a "login" >> form or a "logout" button. I tried to use this code snippet: >> >> http://docs.djangoproject.com/en/1.1/topics/auth/#id6 >> >> If

strange 404 on favicon.ico in the admin

2010-02-15 Thread andreas schmid
hi, i cant understand why but when i access my projects admin interface i continiously get a 404 error on the favicon. everything works fine but i get a lot of error mails from django everytime i access the site on production. [15/Feb/2010 12:34:07] "GET /de/admin/ HTTP/1.1" 200 7758 [15/

Re: Templates design question

2010-02-15 Thread andreas schmid
you could create a template module where you put in the logic to dipslay the content of the post: Hello, > > I'm writing some simple webblog, just for self teaching, and I have a > question how to do better. Here is the situation, I have base.html, I > have blog.html which extends base. Now i

Re: strange 404 on favicon.ico in the admin

2010-02-15 Thread andreas schmid
thx for that, i have a favicon for the frontend of my site and i really dont understand why and where its searching for /favicon.ico it should be /media/favicon.ico for the admin anyway. i solved it by putting a django.views.generic.simple.redirect_to to rewrite the url for the favicon. Shawn Mil

Re: about sending email

2010-02-17 Thread andreas schmid
this doesnt seem a django problem but a failure in the connection to the mailserver. check your email setup in your settings.py danin wrote: > hi guys, > I am new to Django. I am working on mini project where i > need to send some mail , i used the send_mail but i m not able to send > an

special characters in urls

2010-02-19 Thread andreas schmid
how do i have to deal with special characters in urls? for example if i would have programming languages like C, C++ or C# if i use SlugField the characters are escaped and each of the 3 slugs becomes C. what is the way to go? -- You received this message because you are subscribed to the Google

NoReverseMatch is making me crazy

2010-02-22 Thread andreas schmid
im experiencing a problem since today: my model : class Technology(models.Model): title= models.CharField(max_length=250, help_text=_('Type in the technology title')) body = models.TextField(help_text=_('Type in the description of the technology'))

Re: NoReverseMatch is making me crazy

2010-02-22 Thread andreas schmid
Tom Evans wrote: > On Mon, Feb 22, 2010 at 11:01 AM, andreas schmid wrote: > >> im experiencing a problem since today: >> >> my model : >> >>class Technology(models.Model): >> title= models.CharField(max_length=250, >&

Re: django and ldap

2010-02-22 Thread andreas schmid
Peter Herndon wrote: > On Feb 5, 2010, at 5:45 AM, andreas schmid wrote: > > >> ok django-ldap-groups works perfectly now! >> >> > > That's great to hear! If you run into any issues, I'll be happy to help > troubleshoot. > > ---Peter &g

Re: django and ldap

2010-02-22 Thread andreas schmid
Peter Herndon wrote: > On Mon, Feb 22, 2010 at 9:40 AM, andreas schmid wrote: > > >> im experiencing strange problems now. the user is able to authenticate >> against ldap only if in the active directory the displayName == username >> why this? i dont get any error

avoid pre filled registration form

2010-02-23 Thread andreas schmid
hi, im using django registration to allow people to register to my site. the ugly thing is that the registration form is pre filled by the browser in a wrong way. the form has the usual 4 fields (username, email, pwd1 and pwd2) the prefilled fields are email with the username (wich is really bad)

Re: avoid pre filled registration form

2010-02-24 Thread andreas schmid
thx i put the autocomplete definition directly in the tag and its inherited by all input fields Andrius A wrote: > > Hi, > > Use autocomplete="off" attribute in your input fields. > >> On 24 Feb 2010 07:58, "andreas schmid" > <mailto:a.schmi...@gma

Re: Adding a new language to Django?

2010-02-24 Thread andreas schmid
and what if im using a third party app like django-registration and i want to get a better translation without the need to copy the app my repository and customize it? could i override the default django-registration .mo files? derek wrote: > Thanks Daniel - I missed that part {sound of head slap

Re: django and ldap

2010-02-24 Thread andreas schmid
Peter Herndon wrote: > On Feb 22, 2010, at 3:13 PM, andreas schmid wrote: > > >> Peter Herndon wrote: >> >>> On Mon, Feb 22, 2010 at 9:40 AM, andreas schmid >>> wrote: >>> >>> >>> >>>> im experiencing st

Re: Django with Jquery

2010-02-28 Thread andreas schmid
Alexis Selves wrote: > Hello, > I am totally helpless. I am trying to use JQuery in my django > templates, but I always get in firebug this: $ not defined. > > In my template I am linking jquery : > > > where do you have your static files? did you serve them as static files? maybe ur only missi

Re: open()

2010-03-03 Thread andreas schmid
zubin71 wrote: > >From a method defined in a view i need to get the source of an html > file in the templates directory. This is how i tried it out. An error > occurs at the line, > > f = open(os.path.join(os.getcwd(), '../templates/test.html'), 'r') ; > the output of your os.path.join is someth

Re: Multiple views files

2010-03-04 Thread andreas schmid
Kenny Meyer wrote: > Wiiboy (jordon...@gmail.com) wrote: > >> Hi guys, >> I'm thinking about making multiple views files. I'm just wondering >> whether: >> a. There's any problems with that >> b. many people do it. >> >> -- >> You received this message because you are subscribed to the Google

unique slug creation and check

2010-03-08 Thread andreas schmid
hi, im thinking about how to make my slug generation a bit more functional. I dont want my users to think or write their slugs so they have to be generated by a field in the model. usually this is the title field. Now the problem is that there is the possibility that a slug could be the same as o

Re: unique slug creation and check

2010-03-08 Thread andreas schmid
it looks like what i want to do. did you set the slug field as blank=True or null=True? adamalton wrote: > Here's some code that I wrote a few days ago: > > class MyModel(models.Model): > #various fields and stuff here > > def save(self, *args, **kwargs): > if not self.slug: >

Re: Custom widget for a modelform field

2010-03-08 Thread andreas schmid
i have customized multiselect widget on a model field and it works like this: class MyModelForm(ModelForm): field = ModelMultipleChoiceField(MyOtherModel.objects, required=False, widget=MultipleSelectWithPop) class Meta: model = MyModel let me know! Odd wrote: > It works

Re: buildout and django

2010-03-13 Thread andreas schmid
you can use iw.recipe.subversion like this: parts= site-packages django eggs= ... [site-packages] recipe = iw.recipe.subversion urls = svn checkout */http/*://django-mptt.googlecode.com/svn/trunk/ django-mptt [django] ... egg

Re: django and buildout

2010-03-14 Thread andreas schmid
rror: Couldn't find a distribution for 'django-mptt>0.2.1'. > > I have an extra-paths statement as suggested by Andreas Schmid, but > it doesn't use the installed parts/site-packages/django-mptt. > > Here's the buildout config -- would you please p

Re: Django With Google App Engine

2010-03-16 Thread andreas schmid
http://www.google.com/search?hl=en&q=google+app+engine+django&aq=f&aqi=g1g-c1g3g-c3g2&aql=&oq= Tsolmon Narantsogt wrote: > How to use the Django with Google App Engine ? > -- > You received this message because you are subscribed to the Google > Groups "Django users" group. > To post to this grou

MultiWidget and MultiValueField in django admin?

2010-03-16 Thread andreas schmid
hi, can i use the MultiWidget approach in the django admin? (i guess it should work) im trying to build a widget composed by a textinput and a select but with no luck. can someone provide me a working example? im trying to find what i need on google but i cant find a simple example which combines

Re: MultiWidget and MultiValueField in django admin?

2010-03-16 Thread andreas schmid
http://www.djangosnippets.org/snippets/217/ i found this simple example which explains it pretty good. andreas schmid wrote: > hi, > > can i use the MultiWidget approach in the django admin? (i guess it > should work) > im trying to build a widget composed by a textinput and a se

Re: mr.developer

2010-03-16 Thread andreas schmid
John Griessen wrote: > If you run buildout it checks out what you made changes to -- wiping > the changes. > Am I supposed to be using any particular version control with > buildout? It seems > to mention many kinds. right if you run buildout it checks if there are changes in some app or configura

Re: django buildout trouble

2010-03-17 Thread andreas schmid
did you run ./bin/django syncdb? did you edit the cottagematic_com.urls to get the admin working? ViewDoesNotExist: Could not import cottagematic_com.django.contrib.auth.views. this one looks strange to me because cottagematic_com is your project dir (right?) and django is located in cottagematic_

Re: django buildout trouble

2010-03-18 Thread andreas schmid
John Griessen wrote: > Kevin Teague wrote: >>> I'm looking into why buildout would leave the pythonpath incomplete >>> and think it is just a buildout.cfg problem. The same site >>> structure worked >>> in a non-buildout form. >>> >> can you provide your buildout or a sample of your project on git

  1   2   >