New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Can not click Element by ClassName or linkText as same Facebook Driver #4
Comments
OK, I solved run PhantomJS via socks 5. But Not solve the first problem. Need support! |
Hi, I would select the set of links in class "one" (a.one), then a sub selection using "nth-of-type(n)" like this:
You could use getElement() and make sure you have the right link. I also saw you wanted to click the link using mouseEventOnElement() before you edited the issue. In the Readme you will see that mouseEventOnElement() can only click elements that cover an area on the page. A vanilla hyperlink is just a link of text, to click use the clickElement() method instead. |
Thanks for fast support. I will check it again. And If error, these folder in WorkDirectory do not delete, may be error for next PhantomJS instances |
What's your OS, version and architecture? Can you send me the string that fails? The fact that the process does not exit is quite odd. There is only two scenarios I can think of that would cause the process to live beyond the lifetime of the PHP script. That would be if the command you execute is the very first one OR if you are using a very old version of MTS. When did you download MTS and are you using master or a specific release? |
Oh, one moment, I create many instances while do not terminate it before.
|
Are you using the current version of master? If not how old is it? Since you customized MTS do you have a repository where I can look at the code? I am puzzled because $windowObj->close() does not invoke terminate of the entire browserObj just that window. |
I'm using latest MTS release. |
The reason I would like to see the code is that the Exception trace shows: Can't find variable: myArray, ECode: 0 in /MTS/Common/Devices/Browsers/PhantomJS.php:111 That variable is not defined in the stock MTS package. It's hard to help you without knowing how you customized the package. |
Thank you, I will track it again, but I do not modifie PhantomJS.php. |
The exception is relayed from the .js executed by phantomJS. It's not a PHP exception originally. |
Yes, I fixed it! Thanks! |
hello, I want click by classname (many classname duplicate). How to click with classname $n
ex:
I Want click link Two
And How do run PhantomJS via Sock 5 proxy?
The text was updated successfully, but these errors were encountered: