BLACKSITE
:
216.73.217.4
:
104.37.75.190 / alpenpass.ca
:
Linux server3.pointsplan.com 5.14.0-503.38.1.el9_5.x86_64 #1 SMP PREEMPT_DYNAMIC Fri Apr 18 08:52:10 EDT 2025 x86_64
:
/
home
/
apca
/
www
/
includes
/
Upload File:
files >> /home/apca/www/includes/functions.php
<?php function truncateText($text, $maxWords = 40) { // Split the text into an array of words $words = explode(' ', $text); // Check if the number of words exceeds the limit if (count($words) > $maxWords) { // Truncate the array to the desired word count $words = array_slice($words, 0, $maxWords); // Rejoin the words and append an ellipsis return implode(' ', $words) . '...'; } // If within the limit, return the original text return $text; }