Ready to get started?Download WordPress


the_editor decode content from database (3 posts)

  1. iivvvii
    Posted 4 years ago #

    In a custom page i'm using the_editor function to edit database elements. First i get the content from the database with $wpdb->get_results. This content is put into the editor like this: the_editor($content). The problem is that urls and html elements are escaped by $wpdb->update. If i place for example an image and try to load the content and edit it again it isn't readable anymore.

    So i need to de-escape the content before place it into the_editor. Anyone knows a function for this?

  2. iivvvii
    Posted 4 years ago #

    nobody knows?

  3. iivvvii
    Posted 4 years ago #

    I resolved this problem with some php functions: htmlspecialchars_decode(html_entity_decode(stripslashes($content))). But if someone knows the wordpress solution?

Topic Closed

This topic has been closed to new replies.

About this Topic