ZBlogPHP domain name authorization plug-in - AllowURL

Free plug-ins twenty-six thousand two hundred and thirty-seven 8 years ago (2016-09-29)

plug-in unit Name: Domain Name Authorization System plug-in

Plug in author: TOYEAN

Plug in language: PHP

Applicable version: Z-Blog 1.5

Issued on: September 29, 2016

Updated on: March 1, 2017

Latest version: V1.1

Publishing address: https://www.toyean.com/post/allowurl.html

Download address:

You need to have a Tuoyuan account, and Sign in Then you can view or download the hidden content

Plug in interface (basic settings):


Plug in interface (authorization management):


The Domain Name Authorization System plug-in is applicable to zblog Application developer, belonging to Tuoyuan Network The first independent plug-in of Z-blog login interface plug-in (LoginUI) is the login plug-in zblogdl for modifying the self coating version.

The Domain Name Authorization System plug-in is an extension of the previous article《 Two Methods of Domain Name Authorization in PHP 》Convenient management of encapsulation can realize theme When enabling and uninstalling, verify the authorization of the domain name through the server. The published version can only manage the authorization of the domain name. The server's verification address cannot be accessed separately, but only serves as verification. The client code is embedded in the enabling and uninstalling methods when using. The specific code can be seen in the basic settings. I hope that every developer who uses this plug-in can brainstorm and develop more practical functions.

Client example code 01:

Place in the main.php file of the application

 function App_Check(){   $servername = trim($_SERVER['SERVER_NAME']); @$verifyurl=file_get_contents ('the server api address? Domain='. $servername);   if(!empty($verifyurl)){ Return "- Authorized Edition";   }else{ Return "- Unauthorized version";   } } $check = App_Check(); $blogtitle='Page title'$ check; <? php echo $blogtitle;?> //Output: page title - authorized version or page title - unauthorized version

Client example code 02:

It is placed after the function InstallPlugin_App() {code in the application include.php file. If the application is not authorized, an unauthorized message will be prompted after enabling the application.

 function InstallPlugin_App(){ $servername = trim($_SERVER['SERVER_NAME']); @$verifyurl=file_get_contents ('the server api address? Domain='. $servername); if(!empty($verifyurl)){ Return "Authorized!"; }else{ Die ("The application is not authorized!"); } }