Parse error: unexpected '@' symbol in constant function in php -


in project, when try install software, got parse error in last step of installation

the parse error

parse error: syntax error, unexpected '@' in /path/to/server/subfolder1/projectfoldername/subfolder/filename.php on line 21

the coding in particular line of file is

if(@constant($matches[1][0]) != @$matches[1][0]){         if(!empty(@constant(@$matches[1][0])) & !empty(@$matches[0][0]) & !empty(@$design_m_r[$key])){            $design_m_r[$key] = @str_replace($matches[0][0], constant($matches[1][0]), $design_m_r[$key]);          }         } 

our site php version php 5.3.28. tried search error. dont solution this. of forums told error "this advanced php version functions. should not support php 5.3.28 version". when searched, there no versions used type of function.

you can't use @ error suppression operator that.

from php docs..

the @-operator works on expressions. simple rule of thumb is: if can take value of something, can prepend @ operator it. instance, can prepend variables, function , include calls, constants, , forth. cannot prepend function or class definitions, or conditional structures such if , foreach, , forth.

also, passing arbitrary expressions on empty allowed php 5.5 .


Comments

Popular posts from this blog

Android layout hidden on keyboard show -

google app engine - 403 Forbidden POST - Flask WTForms -

c - Why would PK11_GenerateRandom() return an error -8023? -