@browser.button(:text, /Delete account/i).when_present(10).click




________________________________
 From: Vamsi Mandapati <[email protected]>
To: [email protected] 
Sent: Friday, August 30, 2013 4:27 AM
Subject: [wtr-general] Unable to click on a button using css and its name
 


Here is my snippet 

 delete_account= @browser.element(:css => "p.actions > button[name:'delete']")
  delete_account.click


and here is my html 

<html><head>
     
  <body>
    <div class="header-wrapper">
      <div class="header">Update your Profile</div>
    </div>
      <form method="post" action="">
    <input type="hidden" name="_utf8" value="☃">
          <p>
      <p class="actions">
        <input style="float: right" id="submit" type="submit" name="Create 
account" value="Update profile">
        <button name="cancel" style="padding: 10px 10px" 
onclick="window.close(); return false">Cancel</button>
        <button name="delete" style="padding: 10px 10px" 
onclick="window.location.href = 
'https://ww.mysite.com/plugins/social/profile/delete?sessionKey=52205ce9e4b04782e12a79ec&webSocketIdentifier=52205ce9e4b04782e12a79eb';
 return false">Delete account</button>
      </p> 

-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.
 
[email protected]
http://groups.google.com/group/watir-general
[email protected]
 
--- 
You received this message because you are subscribed to the Google Groups 
"Watir General" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.

-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

[email protected]
http://groups.google.com/group/watir-general
[email protected]

--- 
You received this message because you are subscribed to the Google Groups 
"Watir General" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to