Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

I'm trying to include wp_editor in a settings page.

public function addEditor($content = '')
{       
    $editor_id = 'createposteditor';

    $args = array(
        'textarea_rows' => 15,
        'teeny' => true,
        'quicktags' => false,
        'editor_class' => 'createpost-editor'
    );

    return wp_editor( $content, $editor_id, $args  );
}   

and then I echo it out on the settings page:

<tr>                    
    <td align="left" scope="row">                                                                 

        <h1>Add content (optional)</h1>
        '. $poster->addEditor() .'                                           
    </td>
</tr>

My issue is, the editor always gets rendered at the top of the page, not from within the <td> as I require.

share|improve this question
1  
From the source it is absolutely clearly stated that this method renders the editor. You need to call it exactly where you want it. But to see your real problem you need to show the surroundings as well. –  kaiser Aug 19 '13 at 13:43
    
Yes, post the surrounding code. Something is wrong with the code you have. It is pasted as HTML but is almost certainly a PHP string. –  s_ha_dum Aug 19 '13 at 13:58
add comment

Know someone who can answer? Share a link to this question via email, Google+, Twitter, or Facebook.

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.