Listening novels JS hook

Source: Internet
Author: User

It's a bit addictive after listening to some of ebc5's "abnormal videos. But I cannot find any other chapter. Google or below. At last, I found 20 articles in longyin pavilion. Although it is rare, I can still listen for a while. However, this is just like the practice of other audio fiction websites. Let's listen to a few articles first. Then, the page prompts you to recharge your account. However, this site uses the (Alert () pop-up prompt to jump to the login page to recharge your account. Speechless ~~ Disabling cookies does not help. Suddenly think of hook, friends who have used hook programming will know what this stuff is, don't know. Google or below.
I think we can use JS hook to rewrite the JS logic on the page and disable previous prompts. After searching for a long time, I still did not find the prompt. You have no choice but to save the page source code and find the corresponding Js. Later I found the corresponding logic in the play function, but I didn't know what it meant. I just disabled it if I thought it was uncomfortable.
Source codeAs follows:

Code

1 // Play audio
2 Function Play (){
3 If (Songlist. selectedindex <   0 ) Alert ( ' Select the unit you want to play! ' );
4 Else {
5 VaR Varvar, person, collect, song, URL, mfzhangjie;
6 Mfzhangjie = Document. form00.mfzhangjie. value;
7 Varvar = Songlist. Options [songlist. selectedindex]. value. Split ( " | " );
8 URL = Varvar [ 0 ]; Song = Varvar [ 1 ]; Collect = Varvar [ 2 ]; Person = Varvar [ 3 ]; Songid = Varvar [ 4 ];
9 Textgeci. innerhtml =   " <IFRAME name = \ " I5 \ " Height = \ " 340 \ " Src = \ "/ PP / Geci. asp ? ID = " + Songid + " \ " Border = \ " 0 \ " Frameborder = \ " 0 \ " Marginwidth = \ " 1 \ " Marginheight = \ " 1 \ " Width = \ " 100 % \ " > </Iframe> " ;
10 Musictitle. innerhtml = Song +   " -- "   + Collect + Mfzhangjie;
11 Upload. Value = Songid;
12 If (Mfzhangjie >   3 )
13 {
14 Exobud. url =   "" ; Exobud. Controls. Stop ();
15 } Else {
16 Exobud. url = URL; exobud. Controls. Play (); showtlab ();
17 }
18 Return ;
19 }
20 }
21

 

ModifiedCode:

 

1 Play = Function (){
2 If (Songlist. selectedindex <   0 ) Alert ( ' Select the unit you want to play! ' );
3 Else {
4 VaR Varvar, person, collect, song, URL, mfzhangjie;
5 Mfzhangjie = Document. form00.mfzhangjie. value;
6 Varvar = Songlist. Options [songlist. selectedindex]. value. Split ( " | " );
7 URL = Varvar [ 0 ]; Song = Varvar [ 1 ]; Collect = Varvar [ 2 ]; Person = Varvar [ 3 ]; Songid = Varvar [ 4 ];
8 Textgeci. innerhtml =   " <IFRAME name = \ " I5 \ " Height = \ " 340 \ " Src = \ "/ PP / Geci. asp ? ID = " + Songid + " \ " Border = \ " 0 \ " Frameborder = \ " 0 \ " Marginwidth = \ " 1 \ " Marginheight = \ " 1 \ " Width = \ " 100 % \ " > </Iframe> " ;
9 Musictitle. innerhtml = Song +   " -- "   + Collect + Mfzhangjie;
10 Upload. Value = Songid;
11
12 Exobud. url = URL; exobud. Controls. Play (); showtlab ();
13
14 Return ;
15 }
16 };

 

 

 

The following describes the methods:

For example, a function exists in the page:
Function showdata (){
Alert ("this is the message from showdata! ");
}

We can use the following script to override this method (execute the following script in the JS console of IE8 to rewrite functions of the same name on the page ):
Showdata = function (){
Alert ("this is the pop-up content after the rewrite method ");
}
When you call the showdata function on the page, the message "this is the content displayed after the rewrite method" is displayed. If you don't believe it, try it. Hey ~~

 

If you are using IE8, open the iedeveloper toolbar. After executing the rewrite method, we found that it still works. After the script is executed, you can listen to novels as usual. O (character _ blank) O haha!

For example:

 

 

 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.