‘cannot yet handle MBCS in html_entity_decode’ error on WP-DownloadManager Jun 05, 2008 // 4:03 am

I am currently working on a WordPress-powered site. One of its features is a download section. After comparing some WordPress plugins, I decided to use Lester ‘GaMerZ’ Chan‘s WP-DownloadManager.

When I use that plugin on WordPress 2.5.1, I got an error. It’s something like this:

Warning: cannot yet handle MBCS in html_entity_decode()! in /home/.../wp-downloadmanager.php on line 308

Is it a bug? It seems that I got this error message because this plugin needs PHP 5 (I still use PHP 4). Since many hosts having PHP 5-enabled (even it does not always installed as the default version), it should not be that difficult to solve this issue. All I need to do is making all .php files are treated as PHP 5 files. Okey, this is a straight forward solution: add a new line in your .htaccess file. You should find it in your WordPress directory, if not, just add this line:

AddType application/x-httpd-php5 .php

And, the problem solved.

Update: Put AddType application/x-httpd-php5 .php in the first line in .htaccess file. Here is mine:

AddHandler application/x-httpd-php5 .php
# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
# END WordPress

After that, create a new php file e.g. myphpinfo.php and include this line:

<?php phpinfo(); ?>

This will display about PHP version (affected by .htaccess).

  • ismail

    I’m also using php 5. And having the same problem ???

    how to solve this kind of problems ?

  • http://orangescale.net Thomas Arie

    I have no problem at all when using the solution I write here. Currently, it works great on WordPress 2.5.1 and PHP 5.2.2. Just make sure you have the newest version of WP-DownloadManager.

  • ismail

    I would like to ask;

    Where I need to put this line in .htaccess file ?

    # BEGIN WordPress

    RewriteEngine On
    RewriteBase /
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php [L]

    # END WordPress

    I have something like that for .htaccess in wordpress folder.

  • http://lesterchan.net/wordpress/2008/06/09/warning-cannot-yet-handle-mbcs-in-html_entity_decode/ Lester Chan’s WordPress Plugins » Blog Archive » Warning: cannot yet handle MBCS in html_entity_decode

    [...] If you host supports PHP 5 but you are on PHP 4, you can take a look at the solution posted by Thomas Arie Setiawan. [...]

  • http://www.technogeekery.com Cat

    THANK YOU!
    (You rock.)

  • http://www.hepcatventures.com Ricci

    THANK YOU!! I am iframing a script in my wordpress blog that was having this issue. I added the line to that folders’ htaccess and PRESTO, it worked seamlessly.

    I can’t thank you enough!

    Ricci

  • http://frage.cc Ernie

    You. saved. my. life. :D

    Thanks a lot. Though I changed the database to v5 the error continued! But with your bugfix everything is fine.

  • http://www.romainblanchais.com Romain

    Hi

    I have a problem, I uploaded the file .htaccess, but now I can’t access to my website. When I go to http://www.romainblanchais.com the webbrower ask me if I want to open a file ” ” with the type application/x-httpd-php

    Thank you !!!

  • http://www.excelcity.com.my lixdo

    tq this solve my problem

  • http://freewarecollection.co.cc Freeware Collection

    I had the same problem with another plugin of Lester Chans, the Post Ratings. I followed your instruction and solved it. Thank you so much for a wonderful tip.

  • http://mas-miftah.com/allessa Miftah

    mas… maturnuwun yaaa…. it worked for me….

blog comments powered by Disqus

Live search:

I'm @thomasarie on Twitter

Subscribe to RSS

Enter your email address and get recent updates sent to your email in the morning.

This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License.

Designed by Thomas Arie. Icon character by Fredy Sujono.