$sql_kashback = $db->query( "SELECT xfields FROM " . PREFIX . "_category WHERE parentid=1" );
while ( $rows = $db->get_row( $sql_kashback ) ) {
$arr[] = $rows;
}
$stack = array();
foreach($xfields as $value){
if($value[xfields]){
$row = xfieldsdataload($value[xfields]);
if($row[$xfname]){
$rowdata = explode( "~", $row[$xfname]);
foreach($rowdata as $value){
if($value){
$value = trim($value);
array_unshift($stack, $value);
}
}
}
}
}
$stack = array_unique($stack);
sort ($stack);
foreach( $stack as $value ){
$xflist .= "
<option value=" . $value . ">" . $value . "</option>
";
}
Но не хочет