]> git.mxchange.org Git - mailer.git/blobdiff - inc/libs/forced_functions.php
Earning subscriptions introduced (unfinished):
[mailer.git] / inc / libs / forced_functions.php
index 331f17e9cc1c30a3900c95ff1935bf9e8b7fc2c0..84f57641e9623c4429b99289c9e57729f1686710 100644 (file)
@@ -75,89 +75,5 @@ function translateForcedAdType ($status) {
        return $return;
 }
 
-// Handles the XML node 'extra-parameter-forced-ads-reload-lock-list'
-function doXmlExtraParameterForcedAdsReloadLockList ($resource, $attributes) {
-       // There should be no attributes
-       if (count($attributes) > 0) {
-               // Please don't add any attributes to foo-list nodes
-               debug_report_bug(__FUNCTION__, __LINE__, 'Expected 0 attributes because this is a foo-list node, got ' . count($attributes));
-       } elseif (!isset($GLOBALS['__XML_ARGUMENTS']['doXmlCallbackFunction']['extra_list']['forced_ads_reload_lock_list'])) {
-               // This list should be created already
-               debug_report_bug(__FUNCTION__, __LINE__, 'forced_ads_reload_lock_list should be already created.');
-       }
-}
-
-// Handles the XML node 'extra-parameter-forced-ads-reload-lock-list-entry'
-function doXmlExtraParameterForcedAdsReloadLockListEntry ($resource, $attributes) {
-       // There are three attributes, by default
-       if (count($attributes) != 3) {
-               // Not the right count
-               debug_report_bug(__FUNCTION__, __LINE__, 'Expected 3 attributes, got ' . count($attributes));
-       } elseif (!isset($attributes['NAME'])) {
-               // 'NAME' not found
-               debug_report_bug(__FUNCTION__, __LINE__, 'Required attribute NAME not found.');
-       } elseif (!isset($attributes['TYPE'])) {
-               // 'TYPE' not found
-               debug_report_bug(__FUNCTION__, __LINE__, 'Required attribute TYPE not found.');
-       } elseif (!isInvalidXmlType($attributes['TYPE'])) {
-               // No valid type
-               debug_report_bug(__FUNCTION__, __LINE__, 'TYPE is not valid, got: ' . $attributes['TYPE']);
-       } elseif (!isset($attributes['VALUE'])) {
-               // 'VALUE' not found
-               debug_report_bug(__FUNCTION__, __LINE__, 'Required attribute VALUE not found.');
-       } elseif (!isXmlValueValid($attributes['TYPE'], $attributes['VALUE'])) {
-               // Not valid/verifyable
-               debug_report_bug(__FUNCTION__, __LINE__, 'Attribute VALUE does not validate. TYPE=' . $attributes['TYPE'] . ',VALUE=' . $attributes['VALUE']);
-       } elseif (!isset($GLOBALS['__XML_ARGUMENTS']['doXmlCallbackFunction']['extra_list']['forced_ads_reload_lock_list'])) {
-               // doXmlCallbackFunction is missing
-               debug_report_bug(__FUNCTION__, __LINE__, 'Required XML node callback-function/extra-parameter-list/forced-ads-reload-lock-list not included around this node. Please fix your XML.');
-       }
-
-       // Add the entry to the list
-       addXmlValueToCallbackAttributes('extra_list', $attributes, 'forced_ads_reload_lock_list');
-}
-
-// Handles the XML node 'extra-parameter-forced-ads-min-stay-list'
-function doXmlExtraParameterForcedAdsMinStayList ($resource, $attributes) {
-       // There should be no attributes
-       if (count($attributes) > 0) {
-               // Please don't add any attributes to foo-list nodes
-               debug_report_bug(__FUNCTION__, __LINE__, 'Expected 0 attributes because this is a foo-list node, got ' . count($attributes));
-       } elseif (!isset($GLOBALS['__XML_ARGUMENTS']['doXmlCallbackFunction']['extra_list']['forced_ads_min_stay_list'])) {
-               // This list should be created already
-               debug_report_bug(__FUNCTION__, __LINE__, 'forced_ads_min_stay_list should be already created.');
-       }
-}
-
-// Handles the XML node 'extra-parameter-forced-ads-min-stay-list-entry'
-function doXmlExtraParameterForcedAdsMinStayListEntry ($resource, $attributes) {
-       // There are three attributes, by default
-       if (count($attributes) != 3) {
-               // Not the right count
-               debug_report_bug(__FUNCTION__, __LINE__, 'Expected 3 attributes, got ' . count($attributes));
-       } elseif (!isset($attributes['NAME'])) {
-               // 'NAME' not found
-               debug_report_bug(__FUNCTION__, __LINE__, 'Required attribute NAME not found.');
-       } elseif (!isset($attributes['TYPE'])) {
-               // 'TYPE' not found
-               debug_report_bug(__FUNCTION__, __LINE__, 'Required attribute TYPE not found.');
-       } elseif (!isInvalidXmlType($attributes['TYPE'])) {
-               // No valid type
-               debug_report_bug(__FUNCTION__, __LINE__, 'TYPE is not valid, got: ' . $attributes['TYPE']);
-       } elseif (!isset($attributes['VALUE'])) {
-               // 'VALUE' not found
-               debug_report_bug(__FUNCTION__, __LINE__, 'Required attribute VALUE not found.');
-       } elseif (!isXmlValueValid($attributes['TYPE'], $attributes['VALUE'])) {
-               // Not valid/verifyable
-               debug_report_bug(__FUNCTION__, __LINE__, 'Attribute VALUE does not validate. TYPE=' . $attributes['TYPE'] . ',VALUE=' . $attributes['VALUE']);
-       } elseif (!isset($GLOBALS['__XML_ARGUMENTS']['doXmlCallbackFunction']['extra_list']['forced_ads_min_stay_list'])) {
-               // doXmlCallbackFunction is missing
-               debug_report_bug(__FUNCTION__, __LINE__, 'Required XML node callback-function/extra-parameter-list/forced-ads-min-stay-list not included around this node. Please fix your XML.');
-       }
-
-       // Add the entry to the list
-       addXmlValueToCallbackAttributes('extra_list', $attributes, 'forced_ads_min_stay_list');
-}
-
 // [EOF]
 ?>