Hi,

for some reason my hyperlink is not coming out as I expect it to.
Here is my code in my template:

<ul class="little_category">
 {% for category in categories %}
   <a href="{% url category-listing category.name|lower %}">
       <li class="{{ parent.name|lower }}" style="border:solid red
1px;">{{ category.name }}</li>
   </a>
 {% endfor %}
</ul>

The outcome is the following html code:

<ul class="little_category">
  <a href="/listings/category/books/"> </a>
  <li class="goods" style="border: 1px solid red;">
  <a href="/listings/category/books/">Books</a>
  </li>
  <a href="/listings/category/books/"> </a>
</ul>

I've checked and I only have one 'little' category - the Books
category.
I'm expecting the html to appear as the following:

<ul class="little_category">
  <a href="/listings/category/books/">
    <li class="goods" style="border: 1px solid red;">Books</li>
  </a>
</ul>

Does anybody know what might be going on?


Thanks a lot for your help.
--~--~---------~--~----~------------~-------~--~----~
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