Read More Script in PHP Script

Read More Script in PHP Script

This is a simple script that allows you to create a teaser/excerpt in your home page.

The function contains two arguments. To use it, you need to pass a parameter into the function.

Parameters:

content = required
word_limit = optional

Function:

           function excerpts($content, $word_limit = 30)         {             $words = explode(" ",$content);                   return implode(" ",array_splice($words,0,$word_limit));         }

 

 

 

Learn How to install Read More Script in PHP Script?


Leave a Reply

Your email address will not be published. Required fields are marked *