Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $cookie = sys_get_temp_dir().'/m2fcookie.txt';
- $url = 'https://'.$this->wikid_host.'/WiKIDAdmin/j_security_check';
- $postfields = array(
- 'j_username' => $this->wikidadmin_user,
- 'j_password' => $this->wikidadmin_pass
- );
- curl_setopt($ch, CURLOPT_URL, $url);
- curl_setopt($ch, CURLOPT_POST, true);
- curl_setopt($ch, CURLOPT_TIMEOUT, 300);
- curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
- curl_setopt($ch, CURLOPT_COOKIEJAR, $cookie);
- curl_setopt($ch, CURLOPT_POSTFIELDS, $postfields);
- curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
- curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, false);
- $data = curl_exec($ch);
Advertisement
Add Comment
Please, Sign In to add comment