Nicolas Steinmetz a écrit :
> 
> Thanks for the answer. I'll implement the 2nd method, which makes far 
> more sens than my first "harsh and straight away" approach ;-)

Solution was finally :

         try:
             tips ={'google': google(request.POST['search'], number),
             'googlefr': googlefr(request.POST['search'], number),
             'dmoz': dmoz(request.POST['search'], number),
             'ask': ask(request.POST['search'], number),
             'yahoo': yahoo(request.POST['search'], number),
             'msn': msn(request.POST['search'], number),
             'excite': excite(request.POST['search'], number)}.get(engine)
         except KeyError:
             tips=google(request.POST['search'], number)


Thanks,
Nicolas


--~--~---------~--~----~------------~-------~--~----~
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 
django-users+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to