0
我認爲使用JSON解析功能比RSS閱讀器更好,如果你想創建原生移動android應用程序。在後端安裝Wordpress和插件JSON API,然後使用Asynctask vs Volley Library來前端Android。向ListView顯示數據 - OnItemClickListener獲取Item的更多詳細信息。但不幸的是JSON文件在內容數組中有些不同,因爲內容包括img類。使用json api獲取數據wordpress
"content":"<p><img class=\"alignnone size-medium wp-image-7\" src=\"http:\/\/localhost\/novemberproject\/wordpress\/wp-content\/uploads\/2014\/11\/1522040_20130503100310-300x233.jpg\" alt=\"1522040_20130503100310\" width=\"300\" height=\"233\" \/><\/p>\n<p>A sports car (sportscar) is a small, usually two seater, two door automobile designed for spirited performance and nimble handling.<\/p>\n"
如果結果投入的TextView,會得到一個錯誤:
" Invalid escape sequence (valid ones are \b \t \n \f \r \" \' \\) ".
任何人有時間來解釋,如何在這種情況下,研究實現?謝謝。
轉換爲json我在wordpress中使用插件JSON API。問題在於內容中的圖像,我是否必須創建一個自定義的php文件? – Dya 2014-11-04 03:23:00