_tpldata['switch_xs_enabled.']) ) ? sizeof($this->_tpldata['switch_xs_enabled.']) : 0; for ($switch_xs_enabled_i = 0; $switch_xs_enabled_i < $switch_xs_enabled_count; $switch_xs_enabled_i++) { $switch_xs_enabled_item = &$this->_tpldata['switch_xs_enabled.'][$switch_xs_enabled_i]; $switch_xs_enabled_item['S_ROW_COUNT'] = $switch_xs_enabled_i; $switch_xs_enabled_item['S_NUM_ROWS'] = $switch_xs_enabled_count; ?> tags. // $str = $this->vars['S_JUMPBOX_SELECT']; $options = array(); // getting header $pos = strpos($str, ' 0) { $start = substr($str, 0, $pos); $str = substr($str, $pos, strlen($str)); } else { $start = 0; } // getting footer $str = strrev($str); $pos = strpos($str, strrev('')); if($pos > 0) { $end = strrev(substr($str, 0, $pos)); $str = substr($str, $pos, strlen($str)); } else { $end = ''; } $str = trim(strrev($str)); // getting all options while(strlen($str) > 0) { $pos = strpos($str, ''); if($pos > 0) { $pos += 9; $item = trim(substr($str, 0, $pos)); $str = trim(substr($str, $pos, strlen($str))); } else { $item = $str; $str = ''; } $value = ''; $text = ''; $selected = false; $pos = strpos($item, '>') + 1; // getting text $text = substr($item, $pos, strlen($item)); $item = substr($item, 0, $pos); $pos = strpos($text, '<'); if($pos) { $text = substr($text, 0, $pos); } // checking if item is selected if(strpos($str1, ' selected')) { $selected = true; } // getting value $pos = strpos($item, 'value="'); if($pos) { $pos += 7; $str1 = substr($item, $pos, strlen($item)); $pos = strpos($str1, '"'); $value = substr($str1, 0, $pos); } $options[] = array( 'text' => $text, 'value' => $value, 'selected' => $selected ); } $text = $start; $group = 0; for($i=0; $i= 2) { $item = $options[$i+1]; $i+=2; $group = true; $text .= ''; } } else { $text .= ''; } } if($group) { $text .= ''; } $text .= $end; $this->vars['S_JUMPBOX_SELECT'] = $text; ?> vars['S_JUMPBOX_SELECT']) ? $this->vars['S_JUMPBOX_SELECT'] : $this->lang('S_JUMPBOX_SELECT'); ?>