Jump to content

Welcome! You're currently a Guest.

If you'd like to join in the Discussion, or access additional features in our forums, please sign in with your Evernote Account here. Have an Evernote Account but forgot your password? Reset it! Don't have an account yet? Create One! You'll need to set your Display Name before your first post.

Photo

Encoding issues depending on note origin : EV Web or EV Apps

encoding utf-8 unicode php regexp

  • Please log in to reply
1 reply to this topic

#1 Clement

Clement

  • Pip
  • Title: Member
  • Group: Members
  • 2 posts

Posted 27 September 2013 - 02:14 PM

Hi,

 

I've noticed a very strange issue using the PHP SDK. I've noticed that the same Regexp works if the note content was created on Evernote Web interface but not if the note is then edited with Mac/Windows apps. I suspect there may be some encoding issues behind this, but it sounds really strange.

 

I don't really know which version of the SDK we're using, may this be linked?

 

Please find below a code example. 

$note = $noteStore->getnote($authToken,$idr,true,false,false,false);
$content = $note->content;
$content = preg_replace('#(<div>)?<en-todo></en-todo>(.*?)</?div>#s', '<ul><li>$2</li></ul>', $content);

Thanks!



#2 Clement

Clement

  • Pip
  • Title: Member
  • Group: Members
  • 2 posts

Posted 27 September 2013 - 03:38 PM

My mistake, that was just red herring!







Also tagged with one or more of these keywords: encoding, utf-8, unicode, php, regexp

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users

Clip to Evernote