【问题标题】:Printing current WebView page as HTML Cocoa将当前 WebView 页面打印为 HTML Cocoa
【发布时间】:2012-08-31 21:44:15
【问题描述】:

如何打印(或存储为字符串)在 WebView 中显示的当前页面的 HTML?

【问题讨论】:

    标签: macos cocoa webview nsstring


    【解决方案1】:

    我试过这个:

     NSString *test = [webViewTest stringByEvaluatingJavaScriptFromString:@"document.documentElement.outerHTML"];
    有用。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2017-06-07
      • 1970-01-01
      • 2012-04-07
      • 2016-12-05
      • 2019-08-04
      • 2013-02-08
      相关资源
      最近更新 更多