【发布时间】:2012-02-06 06:22:20
【问题描述】:
我使用的 RichTextEditor 与此 link 中的详细信息完全相同,我需要在单击按钮时在其他类的表格视图中显示书面内容,但在表格视图单元格中,出现了相应的 html 字符串。以下是我的代码
-(void)submitClicked{
contentObject.webCOntent=webView;
contentObject.savedMessage=SAVED;
contentObject.str = [webView stringByEvaluatingJavaScriptFromString:
@"document.body.innerHTML"];
NSLog(@"created %@",contentObject.str);
}
在tableView cellforRowAyIndexPath,
cell.textLabel.text = [[notesArray objectAtIndex:indexPath.row]str ];
当我运行应用程序时,它在 tableview 中显示 Oiuo8
其中,contentObject 是模型类对象,str 是字符串,webcontent 是模型类中的UIWebView
【问题讨论】:
-
你的 NSLog 语句是怎么说的?您如何将 contentObject 放入 notesArray?
标签: iphone html-parsing richtextediting