Title: anchor button?
Last modified: August 20, 2016

---

# anchor button?

 *  [Jenn65B](https://wordpress.org/support/users/jenn65b/)
 * (@jenn65b)
 * [14 years, 9 months ago](https://wordpress.org/support/topic/anchor-button/)
 * I am using TinyMCE Advanced as my editor. I was told there would be an anchor
   option in the “link” button, however I do not see where that is? Do I need a 
   special plugin to anchor some text?

Viewing 7 replies - 1 through 7 (of 7 total)

 *  Thread Starter [Jenn65B](https://wordpress.org/support/users/jenn65b/)
 * (@jenn65b)
 * [14 years, 9 months ago](https://wordpress.org/support/topic/anchor-button/#post-2217215)
 * No one can help me with this? Then how do people create anchors to text with 
   this wordpress program? I’m new using this and I was told Tinymce Advanced was
   the plugin to use. However, when I click the spot where I want the anchor to 
   be, then click the anchor button and type in the name, nothing appears (should
   be an anchor box, I’d think) after clicking to insert. I’m us wordpress 3.2.1.
 *  [Jason LeMahieu (MadtownLems)](https://wordpress.org/support/users/madtownlems/)
 * (@madtownlems)
 * [14 years, 9 months ago](https://wordpress.org/support/topic/anchor-button/#post-2217336)
 *     ```
       add_action("admin_init","tinymce_mods_buttons_setup");
   
       function tinymce_mods_buttons_setup() {
       	//only if editing permissions do we bother
       	if (!current_user_can('edit_posts') && !current_user_can('edit_pages')) return;
   
       	if ( get_user_option('rich_editing') == 'true') {
       		add_filter('mce_buttons', 'tinymce_mods_add_buttons');
       	}
       }
   
       function tinymce_mods_add_buttons($buttons) {
          array_push($buttons, "anchor");
          return $buttons;
       }
       ```
   
 * however, I found your post because it isn’t working 100% correctly unfortunately.
   You’ll get the Anchor button, which produces a dialog box when clicked, which
   adds the Anchor to the html – but the Anchor icon in the visual editor isn’t 
   displayed
 *  Thread Starter [Jenn65B](https://wordpress.org/support/users/jenn65b/)
 * (@jenn65b)
 * [14 years, 9 months ago](https://wordpress.org/support/topic/anchor-button/#post-2217337)
 * Thank you for your reply! I guess I’m too new at this because I’m not sure where
   to add what you wrote?! Is there another editor or plugin that will do anchors
   in the visual editor?
 *  [Jason LeMahieu (MadtownLems)](https://wordpress.org/support/users/madtownlems/)
 * (@madtownlems)
 * [14 years, 9 months ago](https://wordpress.org/support/topic/anchor-button/#post-2217338)
 * This could just get plopped into your functions.php
 * but like I said, note the one issue – that after adding the anchor in the Visual
   Editor, you won’t be able to see it there (without switching to html view)
 *  [sunriseweb](https://wordpress.org/support/users/sunriseweb/)
 * (@sunriseweb)
 * [14 years, 1 month ago](https://wordpress.org/support/topic/anchor-button/#post-2217393)
 * Here’s how I did it (can’t remember where I found this). The anchor is visible
   in the editor using this method.
 * Add the following code to functions.php for your theme.
 *     ```
       function enable_more_buttons($buttons) {
         $buttons[] = 'hr';
         $buttons[] = 'anchor';
   
         /*
         Repeat with any other buttons you want to add, e.g.
       	  $buttons[] = 'fontselect';
       	  $buttons[] = 'sup';
         */
   
         return $buttons;
       }
       add_filter("mce_buttons", "enable_more_buttons");
       ```
   
 *  Thread Starter [Jenn65B](https://wordpress.org/support/users/jenn65b/)
 * (@jenn65b)
 * [14 years, 1 month ago](https://wordpress.org/support/topic/anchor-button/#post-2217394)
 * when I plopped that into functions.php I got this. Why?
 * function enable_more_buttons($buttons) { $buttons[] = ‘hr’; $buttons[] = ‘anchor’;/*
   Repeat with any other buttons you want to add, e.g. $buttons[] = ‘fontselect’;
   $buttons[] = ‘sup’; */ return $buttons; } add_filter(“mce_buttons”, “enable_more_buttons”);
   
   Warning: session_start() [function.session-start]: Cannot send session cache 
   limiter – headers already sent (output started at /home/content/99/7000499/html/
   wp-content/themes/2010-weaver/2010functions.php:505) in /home/content/99/7000499/
   html/wp-content/plugins/si-contact-form/si-contact-form.php on line 2075
 * Warning: Cannot modify header information – headers already sent by (output started
   at /home/content/99/7000499/html/wp-content/themes/2010-weaver/2010functions.
   php:505) in /home/content/99/7000499/html/wp-admin/theme-editor.php on line 103
 *  [sunriseweb](https://wordpress.org/support/users/sunriseweb/)
 * (@sunriseweb)
 * [14 years, 1 month ago](https://wordpress.org/support/topic/anchor-button/#post-2217395)
 * Hmmm… I’m guessing it is a syntax error in the copy and paste due to the comment
   section. Try removing the comments in the function and just put in.
 *     ```
       function enable_more_buttons($buttons) {
         $buttons[] = 'anchor';
         return $buttons;
       }
       add_filter("mce_buttons", "enable_more_buttons");
       ```
   
 * If that’s not it then maybe it is a conflict with the si-contact-form plugin?

Viewing 7 replies - 1 through 7 (of 7 total)

The topic ‘anchor button?’ is closed to new replies.

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 7 replies
 * 3 participants
 * Last reply from: [sunriseweb](https://wordpress.org/support/users/sunriseweb/)
 * Last activity: [14 years, 1 month ago](https://wordpress.org/support/topic/anchor-button/#post-2217395)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
