wpalchemy
wpalchemy copied to clipboard
WP 3.3 and wp_editor()
Just wondering about WP3.3 compatibility and using the new wp_editor() function with wpalchemy
Correct me if im wrong... but check this
http://pastebin.com/cHHFYwnj
Should work right?
the problem with this solution is that if you use the "docopy" feature, the copied editor does not work. Has anyone found a solution to this?
for single text areas that don't need to repeat you can use the wp_editor function. though i think you need to adjust the textarea's name to match the alchemy naming scheme.
http://pastebin.com/L25qGD9R
$mb->the_field('additional-content');
$content = $mb->get_the_value();
$id = $mb->get_the_name();
$settings = array('textarea_name'=>$mb->get_the_name(),'textarea_rows'=>10);
wp_editor( $content, $id, $settings );
the problem i am facing is that it rich text is being converted to html characters on save.
so something in bold, becomes
<strong>will this work?</strong>
@helgatheviking -
Read an article on this. The solution was as follows:
$content = utf8_encode(html_entity_decode($mb->get_the_value()));
Using utf8_encode and html_entity_decode solved the issue for me. Hope that helps. You might still have the characters once you add the code, just remove them and then update the post
hi dan, i want to say i solved this somehow, but i haven't used alchemy much lately. thanks for the share! i will have to update my files... https://github.com/helgatheviking/WP-Alchemy-Holy-Grail-Theme