use GuzzleHttp\Client;
use GuzzleHttp\Cookie\CookieJar;
$client = new Client([
'base_url' => $baseUrl,
'cookies' => true,
'allow_redirects' => false
]);
$vars = array(
'email' => $login,
'password' => $password,
'_csrf' => $csrf
);
$reg = $client->request('POST', 'https://www.peek-cloppenburg.at/myaccount/login/', $vars);
$cookies = $reg->getHeader('Set-Cookie');
foreach ($cookies as $cookie){
$cookie = explode(';',$cookie);
$cookie = explode('=',$cookie[0]);
$cookie_did[$cookie[0]] = $cookie[1];
}
$cookieJar = CookieJar::fromArray($cookie_did, '.peek-cloppenburg.at');
$client = new Client([
'base_url' => $baseUrl,
'cookies' => true
]);
$account = $client->request('GET','https://www.peek-cloppenburg.at/myaccount/', ['cookies' => $cookieJar]);
echo $account->getBody();
function switchTabsListTov(data){
var classBstPrice = $(data).attr('class');
var classBstPrice = classBstPrice.replace(' active','');
var classBstPrice1 = classBstPrice.split('_');
console.log(classBstPrice1[0]+' '+classBstPrice1[1]);
// $.ajax({
// type: "GET",
// url: "/ajx/specMainTov",
// data: {
// type:classBstPrice1[0],
// idr:classBstPrice1[1]
// },success: function(data){
// $('div.item__tabs_modMain.'+classBstPrice1[0]+' ul li').removeClass('active');
// $('div.item__tabs_modMain.'+classBstPrice1[0]+' ul li.'+classBstPrice).addClass('active');
// $("div.mycarousel-"+classBstPrice1[0]).html("<ul>"+data+"</ul>");
// $(".mycarousel-"+classBstPrice1[0]).jcarousel();
// }
// });
}