if ($cSubs == "d") {
$numSubscriptionsDeleted = Subscription::DeleteSubscriptionsInSection($Pub, $Section);
if ($numSubscriptionsDeleted < 0) {
$errors[] = getGS('Error updating subscriptions.');
}
}
$conflictingSection = array_pop(Section::GetSections($Pub, $Issue, $Language, $cShortName, null, null, true));
if (is_object($conflictingSection) && ($conflictingSection->getSectionNumber() != $Section)) {
$conflictingSectionLink = "/$ADMIN/sections/edit.php?Pub=$Pub&Issue=$Issue&Language=$Language&Section=".$conflictingSection->getSectionNumber();
$msg = getGS('The URL name must be unique for all sections in this issue.<br>The URL name you specified ("$1") conflicts with section "$2$3. $4$5"',
$cShortName,
"<a href='$conflictingSectionLink' class='error_message' style='color:#E30000;'>",
$conflictingSection->getSectionNumber(),
htmlspecialchars($conflictingSection->getName()),
"</a>");
camp_html_add_msg($msg);
// placeholder for localization string - we might need this later.
// getGS("The section could not be changed.");
} else {
$modified &= $sectionObj->setUrlName($cShortName);
camp_html_add_msg(getGS("Section updated"), "ok");
}
$logtext = getGS('Section "$1" ($2) updated. (Publication: $3, Issue: $4)',
$cName, $Section, $publicationObj->getPublicationId(), $issueObj->getIssueNumber());
Log::Message($logtext, $g_user->getUserId(), 21);
}
camp_html_goto_page($editUrl);
?>