Авторизация
 Регистрация   Войти   Забыли пароль? 

Associative Arrays

:: English Support Forums :: PHP-Fusion Coding Coding Style :: Associative Arrays
Admin  Распечатать сообщение

Warning: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead in E:\OpenServer\domains\php-fusion.vveb.ws\includes\bbcodes\mail_bbcode_include.php on line 20

Warning: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead in E:\OpenServer\domains\php-fusion.vveb.ws\includes\bbcodes\mail_bbcode_include.php on line 21

Warning: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead in E:\OpenServer\domains\php-fusion.vveb.ws\includes\bbcodes\search_bbcode_include.php on line 39

Associative Arrays
PHP-Fusion Coding Style PHP-Fusion version 7.02.00



When declaring associaEve arrays with the Array construct, the iniEal array item must begin on
the following line. It should be padded at one indentaEon level greater than the line containing the
array declaraEon, and all successive lines should have the same indentaEon; the closing parent
should be on a line by itself at the same indentaEon level as the line containing the array
declaraEon. For readability, the various "=>" assignment operators should be padded such that
they align.
Загрузить источник  PHP
  1. <?php
  2.  $sampleArray = array(
  3.   firstKey => "firstValue",
  4.   secondKey => "secondValue",
  5.  );
  6. ?>


We require using a trailing comma for the last item in the array; this minimises the impact of
adding new items on successive lines, and helps to ensure no parse errors occur due to a missing
comma.
Изменил(а) Admin , 04.06.2013 21:00:31
  Опубликовано 04.06.2013 21:00:03 
 Перейти на форум:   
HTML-code and BB-code for blogs and forums

<a href="https://php-fusion.vveb.ws/forum/viewthread.php?thread_id=154">Associative Arrays : Associative Arrays</a>


[url=https://php-fusion.vveb.ws/forum/viewthread.php?thread_id=154]Associative Arrays : Associative Arrays[/url]

Голосования
Как Вы предпочитаете покупать ссылки ?
Всего голосов : 3
Перейти в ветку