Subscribe
Navigation
Social Media
Powered by Squarespace
Products I Use
  • Kindle Wireless Reading Device, Wi-Fi, 6
    Kindle Wireless Reading Device, Wi-Fi, 6" Display, Graphite - Latest Generation
    Amazon.com
  • Jabra EXTREME Bluetooth Headset
    Jabra EXTREME Bluetooth Headset
    Jabra
  • Logitech Harmony One Universal Remote with Color Touch Screen
    Logitech Harmony One Universal Remote with Color Touch Screen
    Logitech, Inc
« Book Review: iPhone Fully Loaded by Andy Ihnatko | Main | MyDellMini • 2gb RAM Upgrade Guide »
Tuesday
Feb102009

WordPress › Support » pressthis error with 2.7

In trying to figure out a WordPress 2.7 Press This error I was getting when selecting text prior to using the 2.7 bookmarklet, I kept getting an error. A little web surfing via Google found this helpful forum post...


When trying to use the pressthis tool I get the error:


Fatal error: Call to undefined function: htmlspecialchars_decode in /home/content/r/o/b/robertbasil/html/wp-admin/press-this.php on line 554


Line 554:


I'm using php4, I thought this was a php5 error?


The original poster then provided this bug-fix tip to resolve the problem...





I figured out a quick fix.


Since htmlspecialchars_decode only works with php 5.10 and above I just removed that part of the code.


In the press-this.php file on line 554 change this:


<?php if ($selection) echo wp_richedit_pre(htmlspecialchars_decode($selection)); ?>


To this:


<?php if ($selection) echo wp_richedit_pre($selection); ?>


Now it works just fine.


The code really should do a check to see if php 5.1 is installed before calling the htmlspecialchars_decode function.




I tested it and it seems to be working for me now.


via WordPress › Support » pressthis error with 2.7.


Reader Comments

There are no comments for this journal entry. To create a new comment, use the form below.

PostPost a New Comment

Enter your information below to add a new comment.

My response is on my own website »
Author Email (optional):
Author URL (optional):
Post:
 
Some HTML allowed: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <code> <em> <i> <strike> <strong>