【发布时间】:2019-09-20 09:57:45
【问题描述】:
我想从具有多个选项卡的动态网页中提取一些日志数据,当我进行屏幕抓取时它可以工作,但是当我通过 url 传递 url 时,html 不提供某些选项卡中的详细信息(例如,在这种情况下,活动下的详细信息,在所有选项卡中。
library(RCurl)
library(stringr)
library(XML)
library(RCurl)
library(stringr)
library(XML)
library(rvest)
url<- c("https://issues.apache.org/jira/browse/AMQCPP-645")
html<- getURL((url, followlocation = TRUE)
doc = htmlParse(html, asText=TRUE)
evs <- xpathSApply(doc, "//div[@class='issue-data-block']", xmlValue)
我想从网页中提取事件,但 html 不会自动显示选项卡中的信息(位于下部窗格下的所有选项卡下)
我期望输出如下:
rows evs
1 S A created issue - 25/Apr/19 15:48 Highlight in document.
2 Justin Bertram made changes - 25/Apr/19 17:53 Field Original Value
New
Value Comment [ I'm using Firefox, and it's working no problem. It's
just HTML so there shouldn't be any browser compatibility issues.
My guess is that Firefox is holding on to an older, cached version or
something. Try opening a "private browsing" window and trying it from
there. ] Highlight in document.
3 Timothy Bish made changes - 25/Apr/19 18:10 Resolution Fixed [ 1 ]
Status
Open [ 1 ] Closed [ 6 ] Highlight in document.
4 Timothy Bish made transition - 25/Apr/19 18:10 Open Closed 2h 22m 1
有什么建议吗?
【问题讨论】: