Forums

Question and Answer Forum
encoding issues. (9 posts)

  1. nikosgr
    Member
    Posted 1 year ago #

    Hi.
    i just installed the plugin but i am facing an encoding problem when a question is insered in a non english language such as greek.
    my page and my db are both utf-8

    Any reccommendations?

    http://wordpress.org/extend/plugins/question-and-answer-forum/

  2. trevorpythag
    Member
    Posted 1 year ago #

    Thanks for downloading the plugin. The plugin takes the text from the textbox, applies htmlentities and then uses it in the wp_insert_post function which leads me to belive the error is in the use of wp_insert_post. Having searched in the support forums for this problem I think the posts at
    http://wordpress.org/support/topic/using-wp_insert_post-with-special-utf8-characters
    may help.

    The person asking the question there seems to have the same problem. The problem seemed to be that the code
    define('DB_CHARSET', 'utf8');
    define('DB_COLLATE', '');
    was missing from their wp-config file.

    Could you check whether these lines of code are in your wp-config file?

    Thanks,
    Dave

  3. nikosgr
    Member
    Posted 1 year ago #

    Thanks for your response Dave.
    i've checked my wp-config file and it is exactly as you say it should be.

    i've deactivated all of the other plugins for just in case but the problem still exists.

    the encoding problem only apears on the question itself. The title appears fine without any problems.

    regards
    Nikos

  4. trevorpythag
    Member
    Posted 1 year ago #

    Sorry about the delay in reply.
    I'm not too sure about the problem but as I said before it seems to be something to do with the way the plugin implements wp_insert_post. I don't have too much experience with encoding. If you find a solution please post.

    Sorry I can't be of more help,
    Dave

  5. nikosgr
    Member
    Posted 1 year ago #

    No worries!
    i hope i will find a solution Dave. I've seen your plugin in action and i must say it rocks :)

    regards

  6. cosmos0monster@gmail.com
    Member
    Posted 1 year ago #

    Hi,
    Nice plugn.

    I'm install the plugn, But question add text encoding error.

    example:
    Insert "Test question" => "Test question",working / define('DB_COLLATE', 'utf8_unicode_ci');/
    But
    Insert "Энэ бол тест" => "ЭнÑ".
    tnx,

  7. trevorpythag
    Member
    Posted 1 year ago #

    Hopefully version 1.2.5 has now fixed this problem.

    It seems it was to do with the call to htmlentities when the text of the question is added in addquestion.php

  8. cosmos0monster@gmail.com
    Member
    Posted 1 year ago #

    Thanks Dave,

    Good job

  9. cosmos0monster@gmail.com
    Member
    Posted 1 year ago #

    Thanks Dave,
    Upgrade to version 1.2.5. Now working.
    Good job

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic