Jump to content
  • 0

donate system error HELP


Question

Posted
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;

	}

}

 

2 answers to this question

Recommended Posts

  • 0
Posted

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

  • 0
Posted

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

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now


×
×
  • Create New...

AdBlock Extension Detected!

Our website is made possible by displaying online advertisements to our members.

Please disable AdBlock browser extension first, to be able to use our community.

I've Disabled AdBlock