com web/php: Curly braces for string offset access are deprecated: include/layout.inc
| From: | Peter Cowburn | Date: | Wed, 05 Feb 2020 20:40:49 +0000 |
| Subject: | com web/php: Curly braces for string offset access are deprecated: include/layout.inc | ||
| Groups: | php.webmaster | ||
| Request: | Send a blank email to php-webmaster+get-28522@lists.php.net to get a copy of this message | ||
Commit: 5223f48cbe3b11ba98e62650557fddb06fb8f2d5
Author: Peter Cowburn <salathe@php.net> Wed, 5 Feb 2020 20:40:49 +0000
Parents: b789e70559b0978c19d52fdc98832607d8b11d16
Branches: master
Link: http://git.php.net/?p=web/php.git;a=commitdiff;h=5223f48cbe3b11ba98e62650557fddb06fb8f2d5
Log:
Curly braces for string offset access are deprecated
Changed paths:
M include/layout.inc
Diff:
diff --git a/include/layout.inc b/include/layout.inc
index 397a60845..207d6323c 100644
--- a/include/layout.inc
+++ b/include/layout.inc
@@ -73,7 +73,7 @@ function make_image($file, $alt = FALSE, $align = FALSE, $extras = FALSE,
$dir = '/images', $border = 0, $addsize = TRUE)
{
// If no / was provided at the start of $dir, add it
- $webdir = $_SERVER['MYSITE'] . ($dir{0} == '/' ? '' :
'/') . $dir;
+ $webdir = $_SERVER['MYSITE'] . ($dir[0] == '/' ? '' :
'/') . $dir;
// Get width and height values if possible
if ($addsize && ($size = @getimagesize($_SERVER['DOCUMENT_ROOT'] ..
"$dir/$file"))) {