`network_short_name` ASC", __FUNCTION__, __LINE__);
// Do we have entries?
- if (SQL_NUMROWS($result) > 0) {
+ if (!SQL_HASZERONUMS($result)) {
// List all entries
$rows = array();
while ($row = SQL_FETCHARRAY($result)) {
), __FUNCTION__, __LINE__);
// Do we have entries?
- if (SQL_NUMROWS($result) > 0) {
+ if (!SQL_HASZERONUMS($result)) {
// List all entries
$rows = array();
while ($row = SQL_FETCHARRAY($result)) {
t.`network_type_handle` ASC", __FUNCTION__, __LINE__);
// Do we have entries?
- if (SQL_NUMROWS($result) > 0) {
+ if (!SQL_HASZERONUMS($result)) {
// List all entries
$rows = array();
while ($row = SQL_FETCHARRAY($result)) {
// Displays selected networks for editing
function doAdminNetworkProcessHandlenetworkForm () {
// Do we have selections?
- if (countPostSelection() > 0) {
+ if (ifPostContainsSelections()) {
// Something has been selected, so start displaying one by one
- $SW = 2; $OUT = '';
+ $OUT = '';
foreach (postRequestParameter('sel') as $id => $sel) {
// Is this selected?
if ($sel == 1) {
// Do we have found the network?
if (count($networkData) > 0) {
- // Add color
- $networkData['sw'] = $SW;
-
if (isFormSent('edit')) {
// Make selection box for network_request_type
$networkData['network_request_type'] = generateOptionList(
'POST'
),
array(
- getMessage('ADMIN_NETWORK_REQUEST_TYPE_GET'),
- getMessage('ADMIN_NETWORK_REQUEST_TYPE_POST')
+ '{--ADMIN_NETWORK_REQUEST_TYPE_GET--}',
+ '{--ADMIN_NETWORK_REQUEST_TYPE_POST--}'
),
$networkData['network_request_type']
);
// Problem!
debug_report_bug(__FUNCTION__, __LINE__, 'Cannot detect edit/del.');
}
-
- // Switch colors
- $SW = 3 - $SW;
} // END - if
} // END - if
} // END - foreach
// Handle network type form
function doAdminNetworkProcessHandlenetworktypeForm () {
// Do we have selections?
- if (countPostSelection() > 0) {
+ if (ifPostContainsSelections()) {
// Load network data
$networkData = getNetworkDataById(getRequestParameter('network'));
// Something has been selected, so start displaying one by one
- $SW = 2; $OUT = '';
+ $OUT = '';
foreach (postRequestParameter('sel') as $id => $sel) {
// Is this selected?
if ($sel == 1) {
// Do we have found the network?
if (count($networkTypeData) > 0) {
- // Add color
- $networkTypeData['sw'] = $SW;
-
if (isFormSent('edit')) {
// Add row template for deleting
$OUT .= loadTemplate('admin_edit_network_types_row', true, $networkTypeData);
// Problem!
debug_report_bug(__FUNCTION__, __LINE__, 'Cannot detect edit/del.');
}
-
- // Switch colors
- $SW = 3 - $SW;
} // END - if
} // END - if
} // END - foreach
// Handle network request parameter form
function doAdminNetworkProcessHandlerequestparamsForm () {
// Do we have selections?
- if (countPostSelection() > 0) {
+ if (ifPostContainsSelections()) {
// Init cache array
$GLOBALS['network_params_disabled'] = array();
$networkData = getNetworkDataById(getRequestParameter('network'));
// Something has been selected, so start displaying one by one
- $SW = 2; $OUT = '';
+ $OUT = '';
foreach (postRequestParameter('sel') as $id => $sel) {
// Is this selected?
if ($sel == 1) {
// Do we have found the network?
if (count($networkRequestData) > 0) {
- // Add color
- $networkRequestData['sw'] = $SW;
-
if (isFormSent('edit')) {
// Add options list for network type
$networkRequestData['type_options'] = generateNetworkTypeOptions($networkRequestData['network_type_id']);
// Problem!
debug_report_bug(__FUNCTION__, __LINE__, 'Cannot detect edit/del.');
}
-
- // Switch colors
- $SW = 3 - $SW;
} // END - if
} // END - if
} // END - foreach
// Changes given networks
function doAdminNetworkProcessChangenetworkForm () {
// Do we have selections?
- if (countPostSelection() > 0) {
+ if (ifPostContainsSelections()) {
// By default nothing is updated
$updated = 0;
// Removes given networks
function doAdminNetworkProcessRemovenetworkForm () {
// Do we have selections?
- if (countPostSelection() > 0) {
+ if (ifPostContainsSelections()) {
// By default nothing is removed
$removed = 0;
// Changes given network type handlers
function doAdminNetworkProcessChangenetworktypeForm () {
// Do we have selections?
- if (countPostSelection() > 0) {
+ if (ifPostContainsSelections()) {
// By default nothing is updated
$updated = 0;
// Changes given network request parameters
function doAdminNetworkProcessChangenetworkparamForm () {
// Do we have selections?
- if (countPostSelection() > 0) {
+ if (ifPostContainsSelections()) {
// By default nothing is updated
$updated = 0;
// Removes given network type handlers
function doAdminNetworkProcessRemovenetworktypeForm () {
// Do we have selections?
- if (countPostSelection() > 0) {
+ if (ifPostContainsSelections()) {
// By default nothing is removed
$removed = 0;
// Removes given network request parameters
function doAdminNetworkProcessRemovenetworkparamForm () {
// Do we have selections?
- if (countPostSelection() > 0) {
+ if (ifPostContainsSelections()) {
// By default nothing is removed
$removed = 0;