WordPress.org

Forums

WP VeriteCo Timeline
[resolved] accent don t display (4 posts)

  1. salmon.ronan
    Member
    Posted 2 years ago #

    I'm using WP VeriteCo Timeline V1 and there is a problem with encoding accents. They look like somthing like this : u00ef

    Try the following : ï é ç €

    Also, I can see lots of 'n' appearing in the text. Here is a possible fix:
    wp-veriteco-timeline.php:__construct

    -- $text = preg_replace('/\v+|\\\[rn]/','',$text);
    ++ $text = preg_replace('/\s+/','',$text);

    http://wordpress.org/extend/plugins/wp-veriteco-timeline/

  2. salmon.ronan
    Member
    Posted 2 years ago #

    sorry, wrong fix in previous post.

    -- $text = preg_replace('/\v+|\\\[rn]/','',$text);
    ++ $text = trim(preg_replace('/\r|\n/','',$text));

  3. gotgotf
    Member
    Posted 2 years ago #

    Replace ligne 362 wp-verito-timenine.php :
    $string .= stripslashes($entry->toJSON());

    by
    $string .= $entry->toJSON();

  4. salmon.ronan
    Member
    Posted 2 years ago #

    thanks gotgotf,
    here is a patch that covers all issues I was having :

    --- wp-veriteco-timeline.php.org	2012-11-30 18:01:51.000000000 +0100
    +++ wp-veriteco-timeline.php	2012-12-17 11:54:37.000000000 +0100
    @@ -29,7 +29,8 @@
     			$this->headline = get_the_title( $this->post_id );
    
     			$text = apply_filters('the_content', $post->post_content);
    -			$text = preg_replace('/\v+|\\\[rn]/','',$text);
    +//			$text = preg_replace('/\v+|\\\[rn]/','',$text);
    +			$text = trim(preg_replace('/\r|\n/','',$text));
     			$text = $this->undoTexturize($text);
    
     			$this->text = $text;
    @@ -66,7 +67,8 @@
     				'’' => '\'',
     				'‚' => ',',
     				'“' => '\"',
    -				'”' => '\"'
    +				'”' => '\"',
    +				'…' => '...'
     			);
     			// Fix Word pasting
     			$content = strtr($content, $wp_htmltranswinuni);
    @@ -357,7 +359,7 @@
     				$loop->the_post();
     				$entry = new wpvtEntry( $post );
    
    -				$string .= stripslashes($entry->toJSON());
    +				$string .= $entry->toJSON();
    
     				if($loop->current_post < $loop->post_count - 1) {
     					$string .= ',';
    @@ -407,5 +409,3 @@
     	}
     	add_shortcode('WPVT', 'wpvt_sc_func');
    
    -
    -?>

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • WP VeriteCo Timeline
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic

Tags

No tags yet.