Skip to content

donate system error HELP

Featured Replies

Fatal error: Cannot use 'String' as class name as it is reserved in /home/fr2com/domains/freya-l2.com/public_html/donate/vendor/String.php on line 7

This error comes when trying to install donate system?? Please help.

 

 

<?php



namespace Donate\Vendor;



if ( ! defined('STARTED')) exit;



class String {

	public static function truncate($string, $length = 50, $append="..") {

		$string = trim($string);



		if(strlen($string) > $length) {

		    $string = wordwrap($string, $length);

		    $string = explode("\n", $string, 2);

		    $string = $string[0] . $append;

		}



		return $string;

	}

}

 

In php7 class name String cant be used as a class and file...you can take a look in stackoverflow forums there maybe will be your answer..here is l2jsection

class String, you have to rename it. Guess error is clear and even one Google search would give you the answer. 

Create an account or sign in to comment

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.