Title: Problem with truncate link text
Last modified: August 21, 2016

---

# Problem with truncate link text

 *  [ApoX](https://wordpress.org/support/users/apox/)
 * (@apox)
 * [12 years, 2 months ago](https://wordpress.org/support/topic/problem-with-truncate-link-text/)
 * Im trying to truncate the link text.
 * function.php
 *     ```
       function entry_header_title( $link = true, $before = '', $after = '', $echo = true, $length = false ) {
   
       	$title = get_the_title();
       	if ( $length && is_numeric($length) ) {
       		$title = substr( $title, 0, $length );
       	}
   
       	if ( strlen($title)> 0 ) {
       		$title = apply_filters('entry_header_title', $before . $title . $after, $before, $after);
       			if ( true == $link )
       			$title = '<a href="' . get_permalink() . '" title="Read Post ' . get_the_title() . '">' . get_the_title() . '</a>';
       			echo $title;
       	}
        }
       ```
   
 * postpage
    `<h2 class="entry-title"><?php entry_header_title( true, '', '...',
   true, '45' ); ?></h2>`
 * I have gotten the nonlink to truncate but i have no idea how to truncate the 
   link text

Viewing 1 replies (of 1 total)

 *  Thread Starter [ApoX](https://wordpress.org/support/users/apox/)
 * (@apox)
 * [12 years, 2 months ago](https://wordpress.org/support/topic/problem-with-truncate-link-text/#post-4703516)
 * No one that can help me ? im still stuck with this :/

Viewing 1 replies (of 1 total)

The topic ‘Problem with truncate link text’ is closed to new replies.

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 1 reply
 * 1 participant
 * Last reply from: [ApoX](https://wordpress.org/support/users/apox/)
 * Last activity: [12 years, 2 months ago](https://wordpress.org/support/topic/problem-with-truncate-link-text/#post-4703516)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
