Hello dbee,

If on lines above that you wrote:

errors = new_data = {}

then Python will use reference and make errors and new_data point to
the same object.

Thus, writing new_data['drop_selection'] = 'US' renders
errors['drop_selection'] = 'US' since they are in fact the same
object.

Instead of errors = new_data = {}, write out:
errors = {}
new_data = {'drop_selection': 'US'}

I hope this helps!

Cheers,
Mike Axiak

On May 2, 9:34 pm, dbee <[EMAIL PROTECTED]> wrote:
> Guys, I'm trying to preselect a value for a drop down menu by passing
> that menu a value. Problem is though, that the value comes out
> preselected AND it also comes out as an ***error beside the drop down
> menu. I'm entering the value with new_data NOT with errors...
>
> It looks something like this ...
>
> new_data = {}
>
> new_data['drop_selection'] = 'US'
>
> form = FormWrapper(form, new_data, errors)
> return HttpResponse(...)
>
> Output comes out as something like this ...
>
> Country: |UnitedStates| **US
>
> Can anyone suggest a solution to keep the selected value but to get
> rid of the **US error ?
>
> 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 PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to