clicking on link which is defined by another tag than a href

archel

Client
Регистрация
02.05.2011
Сообщения
175
Благодарностей
22
Баллы
18
Hello

I'm working on a platform in which the the actual link (a href in source) is variable on the different sites, but a class tag is not.

Problem is that I can't make zenno to click on the link when I define another tag than the a href one.

Now, I have solved this by pulling the link out of the source via regexp and the 'get page source' function, but does someone know a handier way?
Like making zenno click on a link which has a certain tag (which is not a href tag)?

thx
archel
 

bigcajones

Client
Регистрация
09.02.2011
Сообщения
1 216
Благодарностей
683
Баллы
113
Have you tried using Innertext for attribute name and the name of the link as attribute value. It would go in the html properties of the branch in the template editor.
 

archel

Client
Регистрация
02.05.2011
Сообщения
175
Благодарностей
22
Баллы
18
I get what you mean but the name is also different on different sites.
It's a bit like this:

first site:
<class="a"><a href="b">signup</a></class>
second site:
<class="a"><a href="c">get you account</a></class>

so all is variable except for <class="a">
thx for your help though
 
Регистрация
01.02.2011
Сообщения
99
Благодарностей
15
Баллы
0
I do alot of universal templates that have huge language variations. I would regex that link to create a regex thats not depended on the innerhtml. Then go to some example sites in the recorder & use pro branch constructor & insert the regex in the "attribute value" & then dial-in the rest of the "elements search" dropdowns in to get a positive lock. Then do a test with the "action selection" with a rise + click.

On the super bitch platforms you can do a cascading logic error thru a couple of variations, but normally you can nail it in with one good regex in the pro branch constructor.
 

archel

Client
Регистрация
02.05.2011
Сообщения
175
Благодарностей
22
Баллы
18
Wow, I think you are a few levels higher than me in the zenno learning process, since I'm not getting most of what you say.
Guess I'm going to stay with the inner html solution. ;-)
 

bambinou

Client
Регистрация
22.08.2011
Сообщения
436
Благодарностей
21
Баллы
18
Hi CaptainObvious,

I double what Archel is saying, I also think your level is much higher than ours :-)
If you have an example of the above your are welcome.

BigcatJones, in reply to your question, yes I have already tried all the basic InnerText, Outhtml and others...nothing works.


Thank you,


BamBam
 

gcomm

Client
Регистрация
01.03.2011
Сообщения
332
Благодарностей
93
Баллы
28
If you read Captain Obvious statement slowly you will get it.... s-l-o-w-l-y..... ;-)
 
Регистрация
01.02.2011
Сообщения
99
Благодарностей
15
Баллы
0
Use the regular expression engine to get a regex of the href link thats not dependent on the base url. Inner & outerhtml is dependent on the sites template/skin, which is going to change from site to site, the code underneath the templates isn't going to chnage from site to site.

After you get a regex of the link insert it into the pro branch constructor in the "attribute value" & use the regex search, etc and then do a rise>click test on a few different sites with different templates.
 

bambinou

Client
Регистрация
22.08.2011
Сообщения
436
Благодарностей
21
Баллы
18
Ok Thanks I am going to give it a go now and see how it works.

BamBam
 

bambinou

Client
Регистрация
22.08.2011
Сообщения
436
Благодарностей
21
Баллы
18
Ok I have this regex:

(?<= \<a href\=\").*(?=\"\>View Profile\<\/a\>)


now the problem is that the pro construction does not find it.
Could you please tell me if my settings are correct:

from left to right:

Tab: page
document : 0
form number : -1
Comete tag: a
attribute name: innerhtml
attribute value: (?<= \<a href\=\").*(?=\"\>View Profile\<\/a\>)
search type:Regexp


Thanks,

BamBam
 

bambinou

Client
Регистрация
22.08.2011
Сообщения
436
Благодарностей
21
Баллы
18
Ok Guys, Thank you all for your great help, I got it working, in fact it was very simple.

Inner html regex set to View .*Profile and not all the html stuff I added before. Then click and not Onlick...strangely "onclick" does not work. Job done :-)

Thanks again! Great community


BamBam
 

Кто просматривает тему: (Всего: 1, Пользователи: 0, Гости: 1)