X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=inc%2Fmodules%2Fadmin%2Fwhat-list_network_types.php;h=436063c93ab1987fde44f525e2a6a73c429fce36;hb=eac4f64432546cd54c1eb504914650cb2ec93497;hp=1542f10b2293dce30214e37f6861728722113169;hpb=57227d33e870ec5cd271209c4a978a52b45c2dd6;p=mailer.git diff --git a/inc/modules/admin/what-list_network_types.php b/inc/modules/admin/what-list_network_types.php index 1542f10b22..436063c93a 100644 --- a/inc/modules/admin/what-list_network_types.php +++ b/inc/modules/admin/what-list_network_types.php @@ -14,10 +14,9 @@ * $Date:: $ * * $Tag:: 0.2.1-FINAL $ * * $Author:: $ * - * Needs to be in all Files and every File needs "svn propset * - * svn:keywords Date Revision" (autoprobset!) at least!!!!!! * * -------------------------------------------------------------------- * * Copyright (c) 2003 - 2009 by Roland Haeder * + * Copyright (c) 2009 - 2011 by Mailer Developer Team * * For more information visit: http://www.mxchange.org * * * * This program is free software; you can redistribute it and/or modify * @@ -42,7 +41,7 @@ if ((!defined('__SECURITY')) || (!isAdmin())) { } // END - if // Add description as navigation point -addMenuDescription('admin', __FILE__); +addYouAreHereLink('admin', __FILE__); // These are expert settings! if (doVerifyExpertSettings() != 'agreed') { @@ -67,6 +66,9 @@ if (isGetRequestParameterSet('network')) { // Get its data for template $networkData = getNetworkDataById(getRequestParameter('network')); + // Init disabled list + $GLOBALS['network_types_disabled'] = array(); + // Load all advert types for given network $result = SQL_QUERY_ESC("SELECT `network_type_id`, `network_type_handle`, `network_type_api_url`, `network_type_click_url`, `network_type_banner_url` @@ -79,32 +81,25 @@ ORDER BY array(getRequestParameter('network')), __FILE__, __LINE__); // Do we have entries? - if (SQL_NUMROWS($result) > 0) { + if (!SQL_HASZERONUMS($result)) { // List all entries - $OUT = ''; $SW = 2; + $OUT = ''; while ($row = SQL_FETCHARRAY($result)) { // Add/translate some data - $row['sw'] = $SW; - if (trim($row['network_type_banner_url']) == '') $row['network_type_banner_url'] = '---'; + $row['network_type_banner_url'] = fixNullEmptyToDashes($row['network_type_banner_url'], 3); + + // Set disabled entry + $GLOBALS['network_types_disabled'][$row['network_type_handle']] = true; // Add row template and switch color $OUT .= loadTemplate('admin_list_network_types_row', true, $row); - $SW = 3 - $SW; } // END - while - // Prepare data for template - $content = array( - 'rows' => $OUT, - 'network_id' => getRequestParameter('network'), - 'network_title' => $networkData['network_title'], - 'network_reflink' => $networkData['network_reflink'], - ); - // Load main template - loadTemplate('admin_list_network_types', false, $content); + loadTemplate('admin_list_network_types', false, $OUT); } else { // No entries found - loadTemplate('admin_settings_saved', false, getMaskedMessage('ADMIN_NETWORK_TYPES_404', $networkData['network_title'])); + displayMessage('{%message,ADMIN_NETWORK_TYPES_404=' . $networkData['network_title'] . '%}'); } // Free result