mhabat
شنبه 20 مهر 1392, 20:44 عصر
سلام. کد زیر میاد به سایت علی بابا لوگین می کنه.
حالا می خوام طوری کوکی ها رو ذخیره کنم که بشه با curl از کوکی ها استفاده کنم.
این کار امکان پذیره؟
سورس:
// ==UserScript==
// @name alibaba
// @namespace copy righted for : boshrast71@yahoo.com
// @description writed by
// @include http*://*.alibaba.com/*
// @version 1.0
// @grant none
// ==/UserScript==
var username = ' ';
var password = ' ';
var subject = 'subject';
var text = '';
var address=location.pathname;
function do_click(){
document.getElementById("send").click()
}
if(location.href=="https://login.alibaba.com/"){
setTimeout(function(){
document.getElementById('xloginPassportId').value= username;
document.getElementById('xloginPasswordId').value= password;
document.getElementById('signInButton').click()},8 000) }
حالا می خوام طوری کوکی ها رو ذخیره کنم که بشه با curl از کوکی ها استفاده کنم.
این کار امکان پذیره؟
سورس:
// ==UserScript==
// @name alibaba
// @namespace copy righted for : boshrast71@yahoo.com
// @description writed by
// @include http*://*.alibaba.com/*
// @version 1.0
// @grant none
// ==/UserScript==
var username = ' ';
var password = ' ';
var subject = 'subject';
var text = '';
var address=location.pathname;
function do_click(){
document.getElementById("send").click()
}
if(location.href=="https://login.alibaba.com/"){
setTimeout(function(){
document.getElementById('xloginPassportId').value= username;
document.getElementById('xloginPasswordId').value= password;
document.getElementById('signInButton').click()},8 000) }