What does "curly braces deprecated" in PHP mean?

Linode Staff

I'm getting an error that says "Array and string offset access syntax with curly braces is deprecated" in a specific line of a PHP file. What is it and how do I fix it?

1 Reply

The reason you're getting this error is because the use of curly braces in PHP has been replaced by square brackets. The specific error will be found in the specific line of the file that's mentioned in the error message. You will need to open this file in a text editor and replace the curly brackets in that line with square brackets. You can navigate to the specified line using the vim text editor by following these instructions. Additionally, more information about this error can be found in this Github post, along with this StackOverflow post.

Reply

Please enter an answer
Tips:

You can mention users to notify them: @username

You can use Markdown to format your question. For more examples see the Markdown Cheatsheet.

> I’m a blockquote.

I’m a blockquote.

[I'm a link] (https://www.google.com)

I'm a link

**I am bold** I am bold

*I am italicized* I am italicized

Community Code of Conduct