Ticket #1945: components.class.php.patch

File components.class.php.patch, 1.2 kB (added by thisboyiscrazy, 5 years ago)
  • ../../components.class.php

    old new  
    560560    $output = ''; 
    561561    $onchange = ($onchange != '') ? " onchange=\"$onchange\"" : ''; 
    562562     
    563     $output .= "\n\t\t\t<select name=\"$this->_elemname\" id=\"$this->_elemname\"$onchange>\n"; 
     563    $output .= "\n\t\t\t<select name=\"$this->_elemname\" id=\"$this->_elemname\"$onchange>"; 
    564564    // include blank option if required 
    565565    if ($canbeempty) 
    566       $output .= "<option value=\"\">&nbsp;</option>";       
     566      $output .= "\n\t\t\t\t<option value=\"\">&nbsp;</option>";       
    567567 
    568568    // build the options 
    569569    foreach ($valarray as $item) { 
     
    571571      $itemtext = (isset($item['text']) ? _($item['text']) : ''); 
    572572      $itemselected = ($currentvalue == $itemvalue) ? ' selected' : ''; 
    573573       
    574       $output .= "\t\t\t\t<option value=\"$itemvalue\"$itemselected>$itemtext</option>\n"; 
     574      $output .= "\n\t\t\t\t<option value=\"$itemvalue\"$itemselected>$itemtext</option>"; 
    575575    } 
    576     $output .= "\t\t\t</select>\n\t\t"; 
     576    $output .= "\n\t\t\t</select>\n\t\t"; 
    577577     
    578578    return $output; 
    579579  }