How to remove PHP ending tag in PhpStorm
Leaving PHP ending tags in your PHP scripts can cause confusement. For example when you have a blank newline below the PHP ending tag it
Home » PHP
Leaving PHP ending tags in your PHP scripts can cause confusement. For example when you have a blank newline below the PHP ending tag it
public function normaliza($string) { $normalizeChars = array( ‘Š’ => ‘S’, ‘š’ => ‘s’, ‘Ð’ => ‘Dj’, ‘Ž’ => ‘Z’, ‘ž’ => ‘z’, ‘À’ => ‘A’,
public function url_exists($url) { $handle = curl_init($url); if (false === $handle) { return false; } curl_setopt($handle, CURLOPT_HEADER, false); curl_setopt($handle, CURLOPT_FAILONERROR, true); // this works curl_setopt($handle,
public function xml2array($contents, $get_attributes = 0) { if (!$contents) { return array(); } if (!function_exists(‘xml_parser_create’)) { //print “‘xml_parser_create()’ function not found!”; return array(); } //Get
function br2nl($html) { if ($html) { return preg_replace(‘/<brs?/?>/i’, “rn”, $html); } }
public function image_type_to_extension($imagetype, $include_dot = false) { if (empty($imagetype)) { return false; } if ($include_dot) { $dot = ‘.’; } else { $dot = ”;
function bootstrapGrids($gridCols, $columns = 3) { if (is_array($gridCols) && count($gridCols) && is_numeric($columns)) { $array = array_chunk($gridCols, ceil(count($gridCols) / $columns)); $content .= ‘<div class=”row”>’; foreach ($array
public function arrayToTable($rows, $idName = ”, $settings = array()) { if (is_array($rows) && count($rows)) { $maxCellCounter = 0; foreach ($rows as $row) { $cellCounter =
/** * Find the position of the Xth occurrence of a substring in a string * @param $haystack * @param $needle * @param $number integer