Search
 
 

Display results as :
 


Rechercher Advanced Search

Latest topics
» why do i get this error
Sun Apr 23, 2017 9:43 pm by anbarasi

» wait property
Sun Apr 23, 2017 12:50 pm by anbarasi

» What is the use of Selenium Remote Control
Fri Apr 21, 2017 7:24 pm by azharuddin

» How can I fix it? TCP PORT Exhaustion
Wed Apr 19, 2017 3:29 pm by JohnSnow

» Difference between QTP, Selenium and Silk test
Wed Apr 19, 2017 2:30 pm by Basilios Will

» Locator for google document
Tue Apr 18, 2017 10:01 pm by SergeyK

» I encountered a mistake: Couldn't register this node
Sat Apr 15, 2017 9:06 pm by skyshine725

» Current version tutorial for just creating a browser instance - Visual Studio
Fri Apr 14, 2017 2:47 am by KilpAr

» cant able to select drop down otions
Thu Apr 13, 2017 6:08 pm by anbarasi

Navigation
 Portal
 Index
 Memberlist
 Profile
 FAQ
 Search

How to Pass parameter in selinium command in (perl )

View previous topic View next topic Go down

How to Pass parameter in selinium command in (perl )

Post by sunny on Fri Feb 12, 2010 8:50 am

Hi All,

I need help in parametering the Link text in selinium.

In my webpage to verify the link for the text i use the selinium command as below

$sel->text_is("link=Logout", "Logout");

I wanted to pass the variable to the $sel->text_is($var).

When i tried below program , its not working.


my @val = ('"link=Logout", "Logout"' ,'"link=Advanced Search", "Advanced Search"');
print "The First Value is $val[0] \n";
$sel->text_is($val[0]);


The print statement prints the correct format , but the sel command execution fails.


I am getting the error.

Error requesting http://localhost:4444/selenium-server/driver/?cmd=getText&1=%22
link%3DLogout%22%2C%20%22Logout%22&sessionId=17a498aa96a9475997f79cc83ae16a3d:
ERROR: Element "link=Logout", "Logout" not found


Can anyone please help to resolve this issue?


I tried below options, but no luck .
$sel->text_is("$val[0]");
$sel->text_is('$val[0]');


Can anyone please let me know what is correct way to pass parameters.


Thanks
Sunitha

sunny

Posts : 1
Join date : 2010-02-12

Back to top Go down

Re: How to Pass parameter in selinium command in (perl )

Post by Adviser on Wed Feb 17, 2010 12:45 pm

Hi,

I have one code which is written in java. You have to just change syntax into perl and understand the logic . It's simple and I am sure you will get it.

checkout this thread
http://seleniumforum.forumotion.net/selenium-rc-discussion-f4/parameterise-you-login-page-using-java-t42.htm

Best of luck

Bye
avatar
Adviser
------------------------
------------------------

Posts : 379
Join date : 2009-07-30
Location : India

http://seleniumforum.forumotion.net

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