Removed some column aliases as they make it harder to check which column was ment
authorRoland Häder <roland@mxchange.org>
Thu, 10 Jan 2013 06:04:48 +0000 (06:04 +0000)
committerRoland Häder <roland@mxchange.org>
Thu, 10 Jan 2013 06:04:48 +0000 (06:04 +0000)
19 files changed:
doubler.php
inc/libs/mailid_functions.php
inc/modules/admin/what-list_holiday.php
inc/modules/admin/what-list_payouts.php
inc/modules/guest/what-mediadata.php
inc/modules/member/what-payout.php
templates/de/emails/admin/admin_payout_request_banner.tpl
templates/de/emails/member/member_payout_request_banner.tpl
templates/de/html/admin/admin_list_payouts_banner.tpl
templates/de/html/doubler/doubler_index.tpl
templates/de/html/mailid/mailid_confirm_buttom.tpl
templates/de/html/mailid/mailid_enter_code.tpl
templates/de/html/mailid/mailid_points_done.tpl
templates/de/html/mailid/mailid_points_done2.tpl
templates/de/html/mailid/mailid_points_failed.tpl
templates/de/html/mailid/mailid_points_failed2.tpl
templates/de/html/mailid/mailid_points_locked.tpl
templates/de/html/mailid/mailid_points_locked2.tpl
templates/de/html/mailid/mailid_timer.tpl

index e3e4d07..04fb0d6 100644 (file)
@@ -179,13 +179,6 @@ if (getDoublerSendMode() == 'DIRECT') {
 // Output header
 loadIncludeOnce('inc/header.php');
 
-// Banner in text
-$content['banner'] = loadTemplate('doubler_banner', TRUE);
-
-// Load header/footer templates
-$content['header'] = loadTemplate('doubler_header', TRUE);
-$content['footer'] = loadTemplate('doubler_footer', TRUE);
-
 if (isUserDataValid()) {
        // Transfer userid/nickname to constant
        $content['refid'] = getUserData('userid');
index da8cd73..4ec9092 100644 (file)
@@ -70,9 +70,6 @@ function handleMailIdErrorCode ($errorCode) {
 
 // Does the "mailid" call-back
 function doMailIdCallback ($data) {
-       // Load banner generically
-       $data['banner'] = loadTemplate('mailid_banner', TRUE);
-
        // Generate call-back function name
        $callbackName = 'doMailId' . trim(capitalizeUnderscoreString($data['do']));
 
index b557952..980b374 100644 (file)
@@ -45,11 +45,11 @@ addYouAreHereLink('admin', __FILE__);
 
 // Start listing holiday requests
 $result = SQL_QUERY("SELECT
-       h.`id`,
-       h.`userid`,
-       h.`holiday_start`,
-       h.`holiday_end`,
-       h.`comments`,
+       `h`.`id`,
+       `h`.`userid`,
+       `h`.`holiday_start`,
+       `h`.`holiday_end`,
+       `h`.`comments`,
        `d`.`status`,
        `d`.`last_online`
 FROM
@@ -57,9 +57,9 @@ FROM
 LEFT JOIN
        `{?_MYSQL_PREFIX?}_user_data` AS `d`
 ON
-       h.`userid`=`d`.`userid`
+       `h`.`userid`=`d`.`userid`
 ORDER BY
-       h.`userid` ASC", __FILE__, __LINE__);
+       `h`.`userid` ASC", __FILE__, __LINE__);
 
 if (!SQL_HASZERONUMS($result)) {
        // List all holiday requests
index be043ac..2d8588f 100644 (file)
@@ -232,10 +232,10 @@ LIMIT 1",
        `t`.`type`,
        `p`.`payout_timestamp`,
        `p`.`status`,
-       `t`.`allow_url` AS `allow`,
-       `p`.`target_url` AS `url`,
-       `p`.`link_text` AS `alt`,
-       `p`.`banner_url` AS `banner`
+       `t`.`allow_url`
+       `p`.`target_url`,
+       `p`.`link_text`
+       `p`.`banner_url`
 FROM
        `{?_MYSQL_PREFIX?}_user_payouts` AS `p`
 LEFT JOIN
@@ -258,9 +258,9 @@ ORDER BY
                        }
 
                        // Nothing entered must be secured in member/what-payputs.php !
-                       if ($content['allow'] == 'Y') {
+                       if ($content['allow_url'] == 'Y') {
                                // Banner/Textlink views/clicks request
-                               if (!empty($content['banner'])) {
+                               if (!empty($content['banner_url'])) {
                                        // Load template for the banner
                                        $content['target_account'] = loadTemplate('admin_list_payouts_banner', TRUE, $content);
                                } else {
@@ -269,7 +269,7 @@ ORDER BY
                                }
 
                                // Admins can addionally test the URL for framekillers
-                               $content['target_bank'] = '<a href="' . generateFrametesterUrl($content['url']) . '" target="_blank">{--CLICK_HERE--}</a>';
+                               $content['target_bank'] = '<a href="' . generateFrametesterUrl($content['target_url']) . '" target="_blank">{--CLICK_HERE--}</a>';
                        } // END - if
 
                        // Add/Translate some data
index a79c6eb..eb2f946 100644 (file)
@@ -227,13 +227,13 @@ if (isExtensionActive('doubler')) {
 if (isExtensionActive('holiday')) {
        // Total holiday requests
        $result = SQL_QUERY("SELECT
-       COUNT(h.`userid`) AS `count_holidays`
+       COUNT(`h`.`userid`) AS `count_holidays`
 FROM
        `{?_MYSQL_PREFIX?}_user_holidays` AS `h`
 LEFT JOIN
        `{?_MYSQL_PREFIX?}_user_data` AS `d`
 ON
-       h.`userid`=`d`.`userid`
+       `h`.`userid`=`d`.`userid`
 WHERE
        `d`.`holiday_active`='Y'
 " . runFilterChain('user_exclusion_sql', ' '),
index 731a00f..90fbf01 100644 (file)
@@ -75,7 +75,7 @@ ORDER BY
                SQL_FREERESULT($result);
 
                // Check for his payouts
-               $result_payouts = SQL_QUERY_ESC("SELECT
+               $result_payouts = SQL_QUERY_ESC('SELECT
        `p`.`id`,
        `p`.`payout_total`,
        `p`.`target_account`,
@@ -83,10 +83,10 @@ ORDER BY
        `t`.`type`,
        `p`.`payout_timestamp`,
        `p`.`status`,
-       `t`.`allow_url` AS `allow`,
-       `p`.`target_url` AS `url`,
+       `t`.`allow_url`,
+       `p`.`target_url`,
        `p`.`link_text`,
-       `p`.`banner_url` AS `banner`
+       `p`.`banner_url`
 FROM
        `{?_MYSQL_PREFIX?}_user_payouts` AS `p`
 LEFT JOIN
@@ -96,14 +96,14 @@ ON
 WHERE
        `p`.`userid`=%s
 ORDER BY
-       `p`.`payout_timestamp` DESC",
+       `p`.`payout_timestamp` DESC',
                        array(getMemberId()), __FILE__, __LINE__);
                if (!SQL_HASZERONUMS($result_payouts)) {
                        // List all his requests
                        $OUT = '';
                        while ($content = SQL_FETCHARRAY($result_payouts)) {
                                // Nothing entered must be secured in member/what-payputs.php !
-                               if ($content['allow'] == 'Y') {
+                               if ($content['allow_url'] == 'Y') {
                                        // Banner/Textlink views/clicks request
                                        if (!empty($content['banner'])) {
                                                // Banner
@@ -112,7 +112,7 @@ ORDER BY
                                                // Textlink
                                                $content['target_account'] = $content['link_text'];
                                        }
-                                       $content['target_bank'] = '<a href="{%pipe,generateDereferrerUrl=' . $content['url'] . '%}" target="_blank">{--CLICK_HERE--}</a>';
+                                       $content['target_bank'] = '<a href="{%pipe,generateDereferrerUrl=' . $content['target_url'] . '%}" target="_blank">{--CLICK_HERE--}</a>';
                                } // END - if
 
                                // Prepare data for the template
@@ -137,7 +137,7 @@ ORDER BY
        }
 } else {
        // Chedk if he can get paid by selected type
-       $result = SQL_QUERY_ESC("SELECT `type`, `rate`, `min_points`, `allow_url` AS `allow` FROM `{?_MYSQL_PREFIX?}_payout_types` WHERE `id`=%s LIMIT 1",
+       $result = SQL_QUERY_ESC("SELECT `type`, `rate`, `min_points`, `allow_url` FROM `{?_MYSQL_PREFIX?}_payout_types` WHERE `id`=%s LIMIT 1",
                array(bigintval(getRequestElement('payout'))), __FILE__, __LINE__);
 
        if (SQL_NUMROWS($result) == 1) {
@@ -167,7 +167,7 @@ ORDER BY
                                subtractPoints('payout', getMemberId(), $points);
 
                                // Add entry to his tranfer history
-                               if ($content['allow'] == 'Y') {
+                               if ($content['allow_url'] == 'Y') {
                                        // Banner/textlink ordered
                                        SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_user_payouts` (`userid`, `payout_total`, `payout_id`, `payout_timestamp`, `status`, `target_url`, `link_text`, `banner_url`)
 VALUES (%s,%s,%s, UNIX_TIMESTAMP(), 'NEW','%s','%s','%s')",
@@ -222,7 +222,7 @@ VALUES (%s,%s,%s,'%s',%s, UNIX_TIMESTAMP(), 'NEW','%s')",
 
                                // Load template and output it
                                displayMessage('{--MEMBER_PAYOUT_REQUEST_SENT--}');
-                       } elseif ($content['allow'] == 'Y') {
+                       } elseif ($content['allow_url'] == 'Y') {
                                // Prepare content
                                $content = array(
                                        'max'    => $max,
index 1bc745b..dfd8745 100644 (file)
@@ -24,7 +24,7 @@ Auszahlungshoehe: $content[payout]
 ------------------------------
 Ziel-URL: $content[turl]
 Linktext: $content[link_text]
-Banner-URL: $content[banner]
+Banner-URL: $content[banner_url]
 ------------------------------
 
 Bitte &uuml;berpr&uuml;fen Sie diese Daten und &uuml;berweisen Sie dann den geforderten Betrag.
index 887eacb..eda0ba0 100644 (file)
@@ -16,7 +16,7 @@ Auszahlungshoehe: $content[payout]
 ------------------------------
 Ziel-URL: $content[turl]
 Linktext: $content[link_text]
-Banner-URL: $content[banner]
+Banner-URL: $content[banner_url]
 ------------------------------
 
 Die dazu n&ouml;tigen $content[payout_points] haben wir Ihnen bereits abgezogen.
index ce6afd3..1093e60 100644 (file)
@@ -1,6 +1,6 @@
 <div class="para">
        {--PAYOUT_OPTIONAL_BANNER--}:
-       <strong><a href="$content[banner]" title="$content[link_text]" target="_blank">$content[banner]</a></strong>
+       <strong><a href="$content[banner_url]" title="$content[link_text]" target="_blank">$content[banner_url]</a></strong>
 </div>
 
 <div class="para">
@@ -9,5 +9,5 @@
 </div>
 <div class="para">
        {--PAYOUT_TARGET_URL--}:
-       <strong>$content[url]</strong>
+       <strong>$content[target_url]</strong>
 </div>
index 3faca82..2076cf3 100644 (file)
@@ -1,7 +1,9 @@
 <div align="center">
 <table border="0" cellspacing="0" cellpadding="0" class="table" width="100%">
        <tr>
-               <td height="80" align="center">$content[header]</td>
+               <td height="80" align="center">
+                       {%template,LoadTemplate=doubler_header%}
+               </td>
        </tr>
        <tr>
                <td align="center">
                {--DOUBLER_YOUR_ADVERTISING_HERE--} <a
                        href="{%url=modules.php?module=index&amp;what=impressum&amp;refid=$content[refid]%}">{--DOUBLER_CONTACT_US--}</a><br />
                <br />
-               $content[banner]<br />
+               {%template,LoadTemplate=doubler_banner%}<br />
                <br />
                $content[payout_history]</td>
        </tr>
        <tr>
-               <td height="80" align="center">$content[footer]</td>
+               <td height="80" align="center">
+                       {%template,LoadTemplate=doubler_footer%}
+               </td>
        </tr>
 </table>
 </div>
index c3166e7..7bd0497 100644 (file)
@@ -10,7 +10,7 @@
                </td>
                <td align="center">
                        <div class="banner dashed">
-                               $content[banner]
+                               {%template,LoadTemplate=mailid_banner%}
                        </div>
                </td>
        </tr>
index 060cadc..8be4b9d 100644 (file)
@@ -11,7 +11,7 @@
                </td>
                <td align="center">
                        <div class="banner dashed">
-                               $content[banner]
+                               {%template,LoadTemplate=mailid_banner%}
                        </div>
                </td>
        </tr>
index eaf014b..fa0c003 100644 (file)
@@ -7,7 +7,7 @@
                </td>
                <td align="center">
                        <div class="banner dashed">
-                               $content[banner]
+                               {%template,LoadTemplate=mailid_banner%}
                        </div>
                </td>
 </tr>
index c248690..ed62615 100644 (file)
@@ -11,7 +11,7 @@
                </td>
                <td align="center">
                        <div class="banner dashed">
-                               $content[banner]
+                               {%template,LoadTemplate=mailid_banner%}
                        </div>
                </td>
        </tr>
index 87b1151..c0c8c4f 100644 (file)
@@ -6,7 +6,7 @@
                </td>
                <td align="center">
                        <div class="banner dashed">
-                               $content[banner]
+                               {%template,LoadTemplate=mailid_banner%}
                        </div>
                </td>
        </tr>
index 5520995..d7556c9 100644 (file)
@@ -6,7 +6,7 @@
                </td>
                <td align="center">
                        <div class="banner dashed">
-                               $content[banner]
+                               {%template,LoadTemplate=mailid_banner%}
                        </div>
                </td>
        </tr>
index a4b53e6..48b9fdc 100644 (file)
@@ -6,7 +6,7 @@
                </td>
                <td align="center">
                        <div class="banner dashed">
-                               $content[banner]
+                               {%template,LoadTemplate=mailid_banner%}
                        </div>
                </td>
        </tr>
index 417a58e..648b340 100644 (file)
@@ -10,7 +10,7 @@
                </td>
                <td align="center">
                        <div class="banner dashed">
-                               $content[banner]
+                               {%template,LoadTemplate=mailid_banner%}
                        </div>
                </td>
        </tr>
index 07bdbc8..a98439a 100644 (file)
@@ -37,7 +37,7 @@ function startCounter() {
                </td>
                <td align="center">
                        <div class="banner dashed">
-                               $content[banner]
+                               {%template,LoadTemplate=mailid_banner%}
                        </div>
                </td>
        </tr>