Excuse me Patrick: is this a new question or a reply to my question? From within the change_form template I need to access the manipulator to be able to create the form data entry fields. I have no way to pass a Context from within my urls.conf since the template is instantiated and handled from within contrib.admin.
Anyone can help? Patrick Lauber wrote: > I have the following view and i want to prepulate the selected Country, > City, and Languages > > > > def details(request): > manipulator = UserPrefs.AddManipulator() > if request.method == 'POST': > ... > ... > else: > cacheGeo(request) > errors = {} > # Prepolulate country, city, languages > new_data = {} > new_data['city']=request.session['geo_city'] > new_data['country_id'] = Countries.objects.get( > name__exact=request.session['geo_country']).id > print new_data > # Create the FormWrapper, template, context, response. > form = forms.FormWrapper(manipulator, new_data, errors) > return render_to_response('accounts/register_details.html', {'form': > form,'user':request.user}) > > > but there seams that the selection fields dont get selected.... how do i > solve this problem? > > Cheers > > Pat > > > > > > -- Mario Graziosi, mailto:[EMAIL PROTECTED] FG&A srl (http://www.fgasoftware.com/) [EMAIL PROTECTED]: The agile PBX (http://www.voiceatwork.eu/) Tel: 02 9350-4780 interno 101, Fax: 02 9139-0172 --~--~---------~--~----~------------~-------~--~----~ 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 more options, visit this group at http://groups.google.com/group/django-users?hl=en -~----------~----~----~----~------~----~------~--~---