• hi,

    I have notice that wp_list_categories() will add extra spaces and \n to it output. I have looked everywhere to remove them with no luck.

    Here is a sample of what I get:

    <ul>
    					<li class="first cat-item cat-item-7"><a href="https://dev.kazone.ca/category/produits" title="Catalogue de produits">Catalogue de produits</a>
    </li>
    	<li class="first cat-item cat-item-8 current-cat"><a href="https://dev.kazone.ca/category/conseils" title="Tous nos conseils">Tous nos conseils</a>
    </li>
    	<li class="last first cat-item cat-item-9"><a href="https://dev.kazone.ca/category/promotions" title="Promotions">Promotions</a>
    </li>
    			</ul>

    Any help would be really appreciated

Viewing 1 replies (of 1 total)
  • I also have this problem using wp_list_categories(). It’s pretty annoying and makes the code look messy. Does anyone know to get rid of them?

Viewing 1 replies (of 1 total)
  • The topic ‘wp_list_categories add extra spaces’ is closed to new replies.