• Resolved rAjAh

    (@rajah)


    I have a problem to customize my sidebar. I used the wp_list_pages function to show the pages, and for the titles in bold the title_li parameter:

    <?php wp_list_pages_pres('title_li=<h2>Title<h2>' ); ?>

    The problem is i write in french and have to put accents. If i put the accents, or their HTML code, it bugs.

    for “Assemblée Générale”, per example:
    <?php wp_list_pages_pres('title_li=<h2>Assembl&eacute;e G&eacute;n&eacute;rale<h2>' ); ?>

    So i arranged it manually in the following way:
    <h2>Assembl&eacute;e G&eacute;n&eacute;rale<h2> <?php wp_list_pages_assgen('title_li=<h2></h2>' ); ?>

    It works very well in Firefox, but in IE the spaces between the lines become irregular, so i can’t use this solution. Any idea?

Viewing 9 replies - 1 through 9 (of 9 total)
  • I don’t think there are functions like these:
    wp_list_pages_pres
    wp_list_pages_assgen

    Also, make sure you save your files with an editor that has support for the encoding of your blog. Usually, it is utf-8, unless you’ve changed.

    Thread Starter rAjAh

    (@rajah)

    Thanks moshu, you answered even before i finished fixing the code in my post…
    The functions you quote are personalized functions on the model of wp_list_pages: they list the pages that are under a certain parent page. You can see what i mean on the site itself, https://www.studentsun.org

    I edit my code with Dreamweaver 8. Under page properties, encoding, i have: DTD: XHTML 1.0 Transitional, Encoding: Western Europe

    Scrap the DW.
    Just plain text editors!
    And what is the setting for encoding in your blog?

    Thread Starter rAjAh

    (@rajah)

    It’s UTF-8 Is there another way to post the accent than “&eacute;” ?

    So, that’s why you have problems.
    You save a file with iso-8859-1 encoding and you try to display it with utf-8 encoding. Wrong…

    When you edit template files make sure you save them with utf-8 encoding!

    You don’t need to use entities for accented characters. UTF-8 is the universal encoding, just type your whatever characters and they will work.

    Thread Starter rAjAh

    (@rajah)

    The problem persists… look now: https://www.studentsun.org

    Thread Starter rAjAh

    (@rajah)

    Ah i just saw your last post, i try like you say

    Thread Starter rAjAh

    (@rajah)

    Great, it works!! Thank you very much, have a nice day

Viewing 9 replies - 1 through 9 (of 9 total)
  • The topic ‘Accents Problem’ is closed to new replies.