'."\n"; mysqli_query($db, $query); if (mysqli_affected_rows($db) == 1) { $query='insert into changelog values(null, null, "'.$Key.'", "style_desc", "D", "", "'.$TypeSeq.':'.$Cat.':'.$SubCat.'", "'.$desc['DESC'].'", "")'; mysqli_query($db, $query); } else { $Failed=TRUE; } } else { $chg=array(); $query='select entry from entry where style_desc="'.$desc['DESC'].'" order by entry'; $chg_res=mysqli_query($db, $query); while ($chg_row=mysqli_fetch_row($chg_res)) { $chg[]=$chg_row[0]; } $to_chg=count($chg); $cnt_chg=0; foreach ($chg as $chg_entry) { $query='update entry set style_desc="'.$desc['NEW_DESC'].'" where entry="'.$chg_entry.'"'; mysqli_query($db, $query); if (mysqli_affected_rows($db) == 1) { $query='insert into changelog values(null, null, "'.$Key.'", "entry", "C", "style_desc", "'.$chg_entry.'", "'.$desc['DESC'].'", "'.$desc['NEW_DESC'].'")'; mysqli_query($db, $query); ++$cnt_chg; } else { $Failed=TRUE; } } if ($cnt_chg != $to_chg) { $Failed=TRUE; } } } ?>

Subcategory '.$SubCat.' - '.$SubDesc."\n"; } ?>

'.safe($desc['DESC']).'
'."\n"; if (!$Remove) { echo 'with
'."\n"; echo ''.safe($desc['NEW_DESC']).'

'."\n"; } if (!$Remove) { echo $cnt_chg.' Entr'.($cnt_chg != 1 ? 'y' : 'ies').' Updated'."\n"; } if (!$GoodDesc) { echo '
'."\n"; echo 'A problem occurred, please try again'."\n"; } if ($Failed) { if ($Remove) { echo 'Delete Failed - Please Try Again'."\n"; } else { echo 'Problem with Update - Please Try Again'."\n"; if ($cnt_chg != $to_chg) { echo '
Not all Entr'.($to_chg == 1 ? 'y' : 'ies').' Changed'."\n"; } } } echo '

'."\n"; echo '
'."\n"; echo ''."\n"; echo '
'."\n"; ?>