![]() |
![]() ![]() |
![]() |
![]()
Post
#1
|
|
Grupa: Zarejestrowani Postów: 2 Pomógł: 0 Dołączył: 28.12.2015 Ostrzeżenie: (0%) ![]() ![]() |
Witam, próbuje wykombinować coś z przelewaniem środków na mintshost.pl
Problem to jest input type hidden name token, jak go pobrać ![]() Kod <?php $link = "http://mintshost.pl/"; $login = "twoj mail"; $pass = "haslo"; $kwota = 1; $odbiorca = "mail odbiorcy"; $cookieFile = 'cookies/' . uniqid(true) . '.txt'; /* NIE WIEM CZY TO ZADZIAŁA $tags = $doc->getElementsByTagName('input'); foreach ($tags as $tag) { if($tag->getAttribute('name') === 'token') { $token = $tag->getAttribute('value'); } } */ // Login $curl = curl_init(); curl_setopt($curl, CURLOPT_URL, $link.'clientarea.php'); curl_setopt($curl, CURLOPT_COOKIEJAR, $cookieFile); curl_setopt($curl, CURLOPT_RETURNTRANSFER, true); curl_setopt($curl, CURLOPT_HEADER, true); curl_setopt($curl, CURLOPT_POST, true); $postVars = array('username' => $login, 'password' => $pass, 'token' => $token, '' => 'Zaloguj się'); curl_setopt($curl, CURLOPT_POSTFIELDS, $postVars); $resp = curl_exec($curl); curl_close($curl); // Parse sid from cookie file $match = explode('sid', file_get_contents($cookieFile)); $sId = trim($match[1]); // Post $curl = curl_init(); $temat1 = "$link.'transfer_srodkow.php"; curl_setopt($curl, CURLOPT_URL, $link); curl_setopt($curl, CURLOPT_COOKIEFILE, $cookieFile); curl_setopt($curl, CURLOPT_RETURNTRANSFER, true); curl_setopt($curl, CURLOPT_HEADER, false); curl_setopt($curl, CURLOPT_POST, true); $postVars = array('kwota' => $kwota, 'email_2' => $odbiorca, 'token' => $token, '' => 'Przelej'); curl_setopt($curl, CURLOPT_POSTFIELDS, $postVars); $result = curl_exec($curl); curl_close($curl); $pattern = '#<a href="(.*?)">Tutaj</a>#'; $ile = preg_match_all($pattern, $result, $matches, PREG_PATTERN_ORDER); //print_r($matches); //echo $matches[1][0]; $zwrot = $link . $matches[1][0]; echo "$i. $zwrot <br>"; //echo $resp; ?> pomoże ktoś? Ten post edytował b0bs0n 28.12.2015, 20:57:00 |
|
|
![]() ![]() |
![]() |
Wersja Lo-Fi | Aktualny czas: 18.07.2025 - 03:59 |