?i=1
?i=2
?i=3
loadHTMLFile($url);
// Create a DOMXPath object
$xpath = new DOMXPath($dom);
// Define the XPath expression to find the desired element
$expression = '//div[@class="td-module-thumb"]/a/@href';
// Query the XPath expression
$hrefAttributes = $xpath->query($expression);
// Iterate over the results and display the href attribute values
foreach ($hrefAttributes as $hrefAttribute) {
$link = $hrefAttribute->nodeValue;
echo '' . $link . '';
echo '';
echo '
';
// Check if a link is submitted for search and it matches the current button
if ($_SERVER["REQUEST_METHOD"] == "POST" && isset($_POST["link"]) && $_POST["link"] == $link && isset($_POST["search"])) {
$searchDom = new DOMDocument();
// Load the HTML from the submitted link
$searchDom->loadHTMLFile($link);
// Create a new DOMXPath object for the submitted link
$searchXPath = new DOMXPath($searchDom);
// Define the XPath expression to find the desired elements in the submitted link
$searchExpression = '//*[contains(@href, "https://hikarinoakari.com/out")]';
// Query the XPath expression in the submitted link
$searchResults = $searchXPath->query($searchExpression);
// Display the search results below the current button
echo '';
echo '
Search Results:
';
if ($searchResults->length > 0) {
foreach ($searchResults as $result) {
echo $result->getAttribute("href") . "
";
}
} else {
echo 'No results found.';
}
echo '';
}
}
?>
ByPass ouo.press