parent
d4c6637eb2
commit
44c1073dca
@ -130,7 +130,7 @@ public class PhotobucketRipper extends AlbumRipper {
|
|||||||
}
|
}
|
||||||
pageIndex++;
|
pageIndex++;
|
||||||
if (pageIndex > 1 || pageResponse == null) {
|
if (pageIndex > 1 || pageResponse == null) {
|
||||||
url = theUrl + String.format("?sort=3&page=", pageIndex);
|
url = theUrl + String.format("?sort=3&page=%d", pageIndex);
|
||||||
logger.info(" Retrieving " + url);
|
logger.info(" Retrieving " + url);
|
||||||
pageResponse = Http.url(url).response();
|
pageResponse = Http.url(url).response();
|
||||||
}
|
}
|
||||||
@ -139,10 +139,10 @@ public class PhotobucketRipper extends AlbumRipper {
|
|||||||
String jsonString = null;
|
String jsonString = null;
|
||||||
for (Element script : albumDoc.select("script[type=text/javascript]")) {
|
for (Element script : albumDoc.select("script[type=text/javascript]")) {
|
||||||
String data = script.data();
|
String data = script.data();
|
||||||
|
// Ensure this chunk of javascript contains the album info
|
||||||
if (!data.contains("libraryAlbumsPageCollectionData")) {
|
if (!data.contains("libraryAlbumsPageCollectionData")) {
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
// Ensure this chunk of javascript contains the album info
|
|
||||||
// Grab the JSON
|
// Grab the JSON
|
||||||
Pattern p; Matcher m;
|
Pattern p; Matcher m;
|
||||||
p = Pattern.compile("^.*collectionData: (\\{.*\\}).*$", Pattern.DOTALL);
|
p = Pattern.compile("^.*collectionData: (\\{.*\\}).*$", Pattern.DOTALL);
|
||||||
|
Loading…
Reference in New Issue
Block a user