1

I wanted to restore some of the lost notes that I obtained by using an iTunes backup (of an iphone 4) and opening up the notes.sqlite file. When I query the table that contains the notes text:

select zcontent from znotebody

I get the text that is in html format. How can I convert those entries to a more readable content? It doesnt have to be perfect, just enough to be able to read it. Here is an example of a note:

    Meds fir odd<div>Trazadone</div><div>Effexor (&amp; Cd)</div><div>Buspirone</div><div>Clonodine</div><div>Nortriptyline</div><div>Risperdal</div><div>Straterra&nbsp;</div>

Here is the actual note from above:

Meds fir odd
Trazadone
(Effexor & Cd)
Buspirone
Nortriptyline
Risperdal
Straterra<space here>
Dan
  • 122
  • 2
  • 9

2 Answers2

1

If you just want to retrieve the note text, I would try this

select "" + zcontent + "" from znotebody

Then save to a file and open in browser

NYCChris
  • 649
  • 5
  • 13
0

You have to look some NSString categories, to escape html tags in your text.

Follow this link will help to solve the issue.. Objective C HTML escape/unescape

Community
  • 1
  • 1
vishy
  • 3,241
  • 1
  • 20
  • 25