wahabmirjan / wp-simple-nonce

A very simple NONCE for WordPress developers.
GNU General Public License v2.0
38 stars 11 forks source link

Note about using PHP 5.3 #1

Closed mikecdt closed 5 years ago

mikecdt commented 9 years ago

If your using PHP 5.3 still, like we are (don't ask), then you'll need to change the new short code used for an array assignment on line 22 of WPSimpleNonce.php.
Change: return ['name'=>$name,'value'=>$nonce]; TO: return array ("name" => $name, "value" => $nonce,);

See http://php.net/manual/en/language.types.array.php "Example #1 A simple array". As of PHP 5.4 you can also use the short array syntax, which replaces array() with [].

wahabmirjan commented 5 years ago

Resolved