Provide zblog template_zblog them_wordpress template download and customization

The zblogphp hook interface inserts the specified content into the article body

Tianxing Studio 2020-07-14 20:24 Zblogphp Tutorial two thousand nine hundred and eighty-seven 0 Comments


If you want to batch insert the specified content before or after the body of each article, you can follow this tutorial.

Ps: You need to have some hands-on ability. In addition, please make sure to website Data is backed up locally to avoid accidents.


First: Open the include.php file in the theme or plug-in you are using, and hang the interface in the "ActivePlugin" function:

 Add_Filter_Plugin ('Filter_Plugin_ViewPost_Template ',' Application ID_Main ');

Second: Write a function of your own, as follows:

 Function Application ID_Main (&$template){     global $zbp;     $article = $template->GetTags('article'); $article ->Content='Here is the content inserted in front of the body of each article'  $article->Content . 'Here is the content inserted after the body of each article'; }

After saving the file, open the background home page to clear the lower cache. Then open an article to see the effect.


Can't find a tutorial that can solve your problem?

You can try to search or ask questions directly online. We also provide charging technical support. If you need it, you can contact us online.

Online questions Online Service

welcome you Comment: Cancel Reply

 Please fill in the verification code
  • Latest articles
  • Hot article ranking
  • Most Comments
Label aggregation
  • Sign in
  • Registered account Forgot your password?
  • register
  • Already have an account? Direct login Forgot your password?
  • Social account login