Search
 
 

Display results as :
 


Rechercher Advanced Search

Latest topics
» FlexMonkium Download Not available under Gorillalogic site
Thu Dec 08, 2016 5:40 pm by bhanu.praveen

» Selenium Script issue
Tue Dec 06, 2016 9:48 pm by njain213

» Difference between QTP, Selenium and Silk test
Tue Dec 06, 2016 7:58 pm by jessicacyrus1

» Where does selenium script pick browser from
Tue Dec 06, 2016 1:52 pm by janbaskt

» Safari throws an HTTP ERROR: 404
Tue Dec 06, 2016 1:51 pm by janbaskt

» Access Denied Error in Selenium RC
Tue Dec 06, 2016 1:51 pm by janbaskt

» Automating Flex application through selenium webdriver
Fri Dec 02, 2016 2:06 pm by abhinay.krs

» Starting with Selenium, what is Selenium?
Mon Nov 28, 2016 4:00 pm by Foma

» Getting started with Selenium
Mon Nov 28, 2016 3:23 pm by Rebbelx

Navigation
 Portal
 Index
 Memberlist
 Profile
 FAQ
 Search

Login to twitter account

View previous topic View next topic Go down

Login to twitter account

Post by HemaPen on Thu Jun 20, 2013 6:21 pm

hi, 

I have started my automation project since 2 days. I need to login to twitter account and verify or click on feedpost.
While I am trying to login to twitter, it is taking me to "We gotta check are you human?" page. Since this page
includes image and text to be input for verification, I dont know how to solve this.
Has anyone faced this problem? How can I avoid this authentication.

This doesnt happen when I login to facebook account.

If anyone has information, please reply as I am stuck at this point.

Thanks,

HemaPen

Posts : 7
Join date : 2013-06-20

Back to top Go down

Re: Login to twitter account

Post by lkavitha on Sat Jun 22, 2013 3:57 am

There is a article related to your question, the author has tried rewriting the expected captcha hidden value using javascript, and then did a sendKey to set the actual value (as done by user usually). Something similar should be possible as the twitter site also has a "recaptcha_challenge_field" that stores a hidden value and i am anticipating it to contain the expected value. Yet to try, when time permits

To reach the article do a google for "Automating(Breaking) captcha using Selenium Webdriver", click on the first link.

lkavitha

Posts : 1
Join date : 2013-06-22

Back to top Go down

Twitter Login Script

Post by sree.cs10@gmail.com on Sat Jun 22, 2013 10:08 pm

Hi HemaPen,

I am able to login to Twitter account successfully without taking me to Captcha page. Can you pls try the below code, and let me know if you face any issues.. 

***************
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.firefox.FirefoxDriver;
import org.openqa.selenium.By;

public class LoginToTwitter {
public static void main(String[] args) throws Exception {
WebDriver fd=new FirefoxDriver();
fd.get("https://twitter.com");
fd.findElement(By.xpath("/html/body/div/div[2]/div/div/div[3]/div[2]/form/div/label"))
.sendKeys("twitter-userid");
fd.findElement(By.xpath("/html/body/div/div[2]/div/div/div[3]/div[2]/form/table/tbody/tr/td/div/label"))
.sendKeys("twitter-pwd");
fd.findElement(By.xpath("/html/body/div/div[2]/div/div/div[3]/div[2]/form/table/tbody/tr/td[2]/button")).click();
}
}
***************

sree.cs10@gmail.com

Posts : 3
Join date : 2013-06-10
Age : 27
Location : Hyderabad

Back to top Go down

Re: Login to twitter account

Post by HemaPen on Mon Jun 24, 2013 10:57 am

Hi Sree and Kavitha,


Thank you for your reply.

I am using chrome driver and By.id(). Ideally none of this should matter. 
But still I could not login without captcha screen popping up.

However, when I tried with WebdriverBackedSlenium, I could login successfully without getting captcha screen.

I will have to look at breaking captcha and learn to break if in case I run into captcha anytime.

Thanks again for your reply,
Hema

HemaPen

Posts : 7
Join date : 2013-06-20

Back to top Go down

Re: Login to twitter account

Post by Sponsored content Today at 8:11 am


Sponsored content


Back to top Go down

View previous topic View next topic Back to top

- Similar topics

 
Permissions in this forum:
You cannot reply to topics in this forum