In the view take an URL from the query:
        query = request.POST.get('q', '')

and in the template I want to print it out in a list
        {% if query %}
                <ul>
                {% for url in query %}
                        <li>{{ url }}</l1>
                {% endfor %}
                </ul>
                {% else %}
                <p>No urls found</p>
        {% endif %}

How do I turn query from a string into a list with one element
(['<query_value>']) in the view?
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to [email protected]
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