Browse Source

Update e-hentai API

spaghetti 8 years ago
parent
commit
4a0260bc20
1 changed files with 2 additions and 2 deletions
  1. 2
    2
      sections/ajax/doujin.php

+ 2
- 2
sections/ajax/doujin.php View File

63
   $cover = $json['thumb'];
63
   $cover = $json['thumb'];
64
   // and let's see if we can replace it with something better
64
   // and let's see if we can replace it with something better
65
   $gallery_page = file_get_contents($url);
65
   $gallery_page = file_get_contents($url);
66
-  $re = '/'.preg_quote('-0px 0 no-repeat"><a href="').'(.*)'.preg_quote('"><img alt="01"').'/';
66
+  $re = '/'.preg_quote('"><img id="img" src="').'([^<]*)'.preg_quote('" style=').'/';
67
   preg_match($re, $gallery_page, $galmatch);
67
   preg_match($re, $gallery_page, $galmatch);
68
   // were we able to find the first page of the gallery?
68
   // were we able to find the first page of the gallery?
69
   if ($galmatch[1]) {
69
   if ($galmatch[1]) {
70
 	  $image_page = file_get_contents($galmatch[1]);
70
 	  $image_page = file_get_contents($galmatch[1]);
71
-	  $re = '/'.preg_quote('"><img src="').'([^<]*)'.preg_quote('" style=').'/';
71
+    $re = '/'.preg_quote('"><img id="img" src="').'([^<]*)'.preg_quote('" style=').'/';
72
 	  preg_match($re, $image_page, $imgmatch);
72
 	  preg_match($re, $image_page, $imgmatch);
73
 	  // were we able to find the image url?
73
 	  // were we able to find the image url?
74
 	  if ($imgmatch[1]) {
74
 	  if ($imgmatch[1]) {

Loading…
Cancel
Save