Disable cmseasy copyright Removal

Source: Internet
Author: User
Tags php foreach

 

I wrote the first two simple articles on how to remove copyrights. Today I will explain how to completely remove copyright concerns.

Some friends and QQ asked me why he could not copyright him. This is because your version is not 3.5. I am talking about copyright only for version 3.5.

No more nonsense. Start copyright. The previous two articles mentioned how to remove copyrights on the page, but the copyright issues in the title were not considered.

You can also remove the copyright response in the title today. If you are patient, you can start from scratch and learn. Skip to the end without patience. There are detailed methods.

First, use a black knife to decrypt and find lib/admin/template _. php under the directory.

The content is as follows:

 

 

<? PHP

If (! Defined ('root') Exit ('can \'t access! ');

Class template _{

Static function _ compile _ ($ source ){

$ Authkey = self: _ getauthkey _();

$ Authdate = self: _ getauthdate _();

$ Authperiod = self: _ getauthperiod _();

If ($ authkey! = Self: md5tocdkey () | ($ authdate + $ authperiod) <time ()){

Preg_match_all ('/<title> (. *)-(. *) <\/title>/', $ source, $ out ); // use the preg_match_all function to match the content between <title> and </title> and assign the value to $ out

If (! $ Out [2] [0] | $ out [2] [0] = 'powered by cmseasy '){

$ Source = str_replace ('</title>', '-powered by cmseasy </title>', $ source ); // If the matched string does not contain powered by cmseasy, use the str_replace function to add-powered by cmseasy before </title>. Now everyone knows how to change it.

}

$ Source = preg_replace ('/

 

 

 

$ Pos = strpos ($ source, '</body>'); // search for </body> in $ source and return the first position to $ POS.

If ($ Pos = false ){

$ Source = str_replace ('

} Else {

     $ Pos = strpos ($ source, '<a href = "http://www.cmseasy.cn" Title = "powered by cmseasy" target = "_ blank"> powered by cmseasy </a> '); // search for copyright information in $ source and return the first position to $ POS

     If ($ Pos = false ){

     $ Source = str_replace ('

// If no copyright information is found, replace

}

}

 

 

 

$ Pos = strpos ($ source, '

If ($ POS ){

$ Pos = strpos ($ source, '<a href = "http://www.cmseasy.cn" Title = "powered by cmseasy" target = "_ blank"> powered by cmseasy </a> ');

If ($ Pos = false ){

$ Source = $ source. '<a href = "http://www.cmseasy.cn" Title = "powered by cmseasy" target = "_ blank"> powered by cmseasy </a> ';

// If yes, search for the copyright information in $ source. If no, connect the copyright information to the $ source string.  "." Is used to connect strings.

}

}

 

$ Source = preg_replace ('/<\/body>/I', "<". "SC ". "R ". "IPT ". "S ". "RC ". "= \"". config: Get ('base _ url '). "/J ". "s /". "Co ". "M ". "M ". "On ". ". J ". "s \" Lan ". "Gu ". "ag ". "E = \" Ja ". "va ". "S ". "CRI ". "PT ". "\" ty ". "pe ". "= \" T ". "ex ". "t/J ". "Av ". "". "cr ". "ip ". "t \"> ". "</". "S ". "cr ". "I ". "P ". "t> \ r \ n </body>", $ source );

} // Specifies the connection string. The above is a random floating copyright given to the user who cannot find the copyright information on the webpage. I believe that this problem may occur after you modify the webpage. The principle is to match the webpage source code and add copyright information after </body> and

 

$ Source = preg_replace ("/\ {PHP \ s + (. +) \}/", "<? PHP \ 1?> ", $ Source );

$ Source = preg_replace ("/\ {If \ s + (. + ?) \}/"," <? PHP if (\ 1) {?> ", $ Source );

$ Source = preg_replace ("/\ {else \}/", "<? PHP} else {?> ", $ Source );

$ Source = preg_replace ("/\ {elseif \ s + (. + ?) \}/"," <? PHP} elseif (\ 1) {?> ", $ Source );

$ Source = preg_replace ("/\{\/ if \}/", "<? PHP }?> ", $ Source );

$ Source = preg_replace ("/\ {loop \ s + (\ $ \ W +) \ s + (\ s +) \}/", "<? PHP foreach (\ 1 as \ 2) {?> ", $ Source );

$ Source = preg_replace ("/\ {loop \ s + (\\\ \ W +) \ s + (\ s +) \}/"," <? PHP foreach (\ 1 as \ 2 = >\\ 3) {?> ", $ Source );

$ Source = preg_replace ("/\ {loop \ s + (\ s +) \}/", "<? PHP foreach (\ 1 as \ 2) {?> ", $ Source );

$ Source = preg_replace ("/\ {loop \ s + (\ s + )\}/", "<? PHP foreach (\ 1 as \ 2 = >\\ 3) {?> ", $ Source );

$ Source = preg_replace ("/\{\/ loop \}/", "<? PHP }?> ", $ Source );

Return $ source;

}

 

 

 

// Here we start with the cdkey Code. There are some cdkey related items in it. If you only need to remove the copyright, we can start the above step. Here we jump to the end of the Code to see how to copyright.

Static function _ getauthkey _(){

$ Source = @ file_get_contents ('cdkey. dll ');

If (strlen ($ source) <0) return '';

Preg_match_all ('/#! = (. *) =! #/', $ Source, $ out );

Preg_match_all ('/# \$ = (. *) =\$ #/', $ source, $ out1 );

Preg_match_all ('/# \ ^ = (. *) = \ ^ #/', $ source, $ out2 );

Preg_match_all ('/# % = (. *) = % #/', $ source, $ out3 );

Preg_match_all ('/# \ * = (. *) = \ * #/', $ source, $ out4 );

Preg_match_all ('/# \ (= (. *) = \) #/', $ source, $ out5 );

Preg_match_all ('/# \-= (. *) = \-#/', $ source, $ out6 );

Preg_match_all ('/#\? = (. *) = \? #/', $ Source, $ out7 );

Preg_match_all ('/#' = (. *) '###/', $ source, $ out8 );

Return $ out [1] [0]. '-'. $ out1 [1] [0]. '-'. $ out2 [1] [0]. '-'. $ out3 [1] [0]. '-'. $ out4 [1] [0]. '-'. $ out5 [1] [0]. '-'. $ out6 [1] [0]. '-'. $ out7 [1] [0]. '-'. $ out8 [1] [0];

}

Static function _ getauthdate _(){

$ Source = @ file_get_contents (root. '/lib/INC/cdkey. dll ');

If (strlen ($ source) <0) return '0 ';

Preg_match_all ('/\: (. *): \ //', $ source, $ outd0 );

Preg_match_all ('/\' :(. *); \ '/', $ source, $ outd1 );

Preg_match_all ('/; :(. *): \'/', $ source, $ outd2 );

Return $ outd0 [1] [0]. $ outd1 [1] [0]. $ outd2 [1] [0];

}

Static function _ getauthperiod _(){

$ Source = @ file_get_contents (root. '/lib/INC/cdkey. dll ');

If (strlen ($ source) <0) return '0 ';

Preg_match_all ('/.]; (. *);]./', $ source, $ outp0 );

Preg_match_all ('/\) (. *) \ (/', $ source, $ outp1 );

Return $ outp0 [1] [0]. $ outp1 [1] [0];

}

Static function md5tocdkey (){

$ Md5str = MD5 ($ _ server ['HTTP _ host']);

$ Source = @ file_get_contents ('cdkey. dll ');

If (strlen ($ source) <0) return 'nocdkeymd5str ';

$ Str    = 'A 'B' C 'D' e 'F' 0 '1' 1 '2' 3' 4 '5' 6 '7' 8 '9 ';

Preg_match_all ('/\ [\ [= (. *) \ * %/', $ source, $ outa );

Preg_match_all ('/% = (. *) \/=/', $ source, $ outa1 );

Preg_match_all ('/\/(. *) \ * =/', $ source, $ outa2 );

Preg_match_all ('/\ * = (. *) = \ */', $ source, $ outa3 );

Preg_match_all ('/\ $ % (. *) % \ $/', $ source, $ outa4 );

Preg_match_all ('/\-= \-(. *) \ (\)/', $ source, $ outa5 );

Preg_match_all ('/# \/(. *) \/#/', $ source, $ outa6 );

Preg_match_all ('/! % (. *) = \]/', $ Source, $ outa7 );

$ Cdkeystr = $ outa [1] [0]. $ outa1 [1] [0]. $ outa2 [1] [0]. $ outa3 [1] [0]. $ outa4 [1] [0]. $ outa5 [1] [0]. $ outa6 [1] [0]. $ outa7 [1] [0];

$ Srtarr = explode (''', $ Str );

$ Cdkeyarr = explode (''', $ cdkeystr );

$ Cdkey = '';

For ($ I = 0; $ I <32; $ I ++ ){

$ Md5word = substr ($ md5str, $ I, 1 );

Foreach ($ srtarr as $ key => $ Val ){

If ($ md5word = $ Val ){

Foreach ($ cdkeyarr as $ key1 => $ val1 ){

If ($ key = $ key1 ){

If ($ I % 4 = 0 ){

$ Cdkey. = $ val1 .'-';

} Else {

$ Cdkey. = $ val1;

}

}

}

}

}

}

Return $ cdkey;

}

 

?>

 

 

 

 

How to remove copyright.

 

 

 

Modify the following code. After modification, continue to look down

 

<? PHP

If (! Defined ('root') Exit ('can \'t access! ');

Class template _{

Static function _ compile _ ($ source ){

$ Authkey = self: _ getauthkey _();

$ Authdate = self: _ getauthdate _();

$ Authperiod = self: _ getauthperiod _();

If ($ authkey! = Self: md5tocdkey () | ($ authdate + $ authperiod) <time ()){

Preg_match_all ('/<title> (. *)-(. *) <\/title>/', $ source, $ out );

If (! $ Out [2] [0] | $ out [2] [0] = 'powered by cmseasy '){

$ Source = str_replace ('</title>', '-powered by cmseasy </title>', $ source );}

$ Source = preg_replace ('/

$ Pos = strpos ($ source, '</body>'); if ($ Pos = false ){

$ Source = str_replace ('

} Else {

     $ Pos = strpos ($ source, '<a href = "http://www.cmseasy.cn" Title = "powered by cmseasy" target = "_ blank"> powered by cmseasy </a> ');

     If ($ Pos = false ){

     $ Source = str_replace ('

$ Source

}

}

$ Pos = strpos ($ source, '

$ Pos = strpos ($ source, '<a href = "http://www.cmseasy.cn" Title = "powered by cmseasy" target = "_ blank"> powered by cmseasy </a> ');

If ($ Pos = false ){

$ Source = $ source. '<a href = "http://www.cmseasy.cn" Title = "powered by cmseasy" target = "_ blank"> powered by cmseasy </a> ';

}

}

$ Source = preg_replace ('/<\/body>/I', "<". "SC ". "R ". "IPT ". "S ". "RC ". "= \"". config: Get ('base _ url '). "/J ". "s /". "Co ". "M ". "M ". "On ". ". J ". "s \" Lan ". "Gu ". "ag ". "E = \" Ja ". "va ". "S ". "CRI ". "PT ". "\" ty ". "pe ". "= \" T ". "ex ". "t/J ". "Av ". "". "cr ". "ip ". "t \"> ". "</". "S ". "cr ". "I ". "P ". "t> \ r \ n </body>", $ source );

}

 

This article from 303 studio http://www..mujiantao.com

Modified code

<? PHP

If (! Defined ('root') Exit ('can \'t access! ');

Class template _{

Static function _ compile _ ($ source ){

$ Authkey = self: _ getauthkey _();

$ Authdate = self: _ getauthdate _();

$ Authperiod = self: _ getauthperiod _();

If ($ authkey! = Self: md5tocdkey () | ($ authdate + $ authperiod) <time ()){

$ Source = $ Source

}

 

 

All right, the copyright issue is solved, but this file exists in multiple folders, so you need to modify it in sequence.

LIB/admin/template _. php

LIB/table/template _. php

After modifying these two files, you can modify the copyright in HTML. I wish you success in copyright ownership. If it fails, you can find my QQ and add me in this blog. If you have time, it will definitely help you solve the problem. I wish you a happy life.

For copyright protection for version 3.7, please stay tuned to this blog...

A 3.5 copyright demonstration: www.mujiantao.com/cmseasy

Tags: cmseasy copyright Removal
Category: enterprise website construction | release: mujiantao | view: 1 | published on: 2011-6-27
Original article reprinted, please note: Reprinted from 303 studio http://www.mujiantao.com/
Link: http://www.mujiantao.com/post130/130.html

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.