hasPriv("admin") && !$_SESSION['current']->isMaintainer($_REQUEST['versionId']) && !$_SESSION['current']->isSuperMaintainer($_REQUEST['appId'])) { errorpage("Insufficient Privileges!"); exit; } /* process the changes the user entered into the web form */ if(isset($_REQUEST['submit'])) { process_app_version_changes(true); redirect(apidb_fullurl("appview.php?versionId=".$_REQUEST['versionId'])); } else /* or display the webform for making changes */ { $oVersion = new Version($_REQUEST['versionId']); apidb_header("Edit Application Version"); echo "
\n"; if($_SESSION['current']->hasPriv("admin")) $oVersion->OutputEditor(true, true); /* false = not allowing the user to modify the parent application */ else $oVersion->OutputEditor(false, true); /* false = not allowing the user to modify the parent application */ echo '',"\n"; echo '',"\n"; echo html_table_end(); echo ""; echo "

\n"; // url edit form echo '',"\n"; echo ''; echo ''; echo html_frame_start("Edit URL","90%","",0); echo '
',"\n"; $i = 0; $result = query_appdb("SELECT * FROM appData WHERE versionId = ".$oVersion->iVersionId." AND type = 'url'"); if($result && mysql_num_rows($result) > 0) { echo '',"\n"; while($ob = mysql_fetch_object($result)) { $temp0 = "adelete[".$i."]"; $temp1 = "adescription[".$i."]"; $temp2 = "aURL[".$i."]"; $temp3 = "aId[".$i."]"; $temp4 = "aOldDesc[".$i."]"; $temp5 = "aOldURL[".$i."]"; echo '',"\n"; echo '',"\n"; echo ''; echo ''; echo '',"\n"; $i++; } } else { echo '',"\n"; echo '',"\n"; } echo "\n"; echo ""; echo '',"\n"; echo '',"\n"; echo '',"\n"; echo '
Delete',"\n"; echo 'DescriptionURL
',"\n"; echo '
DescriptionURL
New
',"\n"; echo html_frame_end(); echo ""; /* only admins can move versions */ if($_SESSION['current']->hasPriv("admin")) { // move version form echo '
',"\n"; echo ''; echo ''; echo html_frame_start("Move version to another application","90%","",0); echo '
',"\n"; echo html_frame_end(); } echo html_back_link(1,BASE."appview.php?versionId=".$oVersion->iVersionId); apidb_footer(); } ?>