Revision: 2253
          http://mrbs.svn.sourceforge.net/mrbs/?rev=2253&view=rev
Author:   cimorrison
Date:     2012-01-26 14:37:24 +0000 (Thu, 26 Jan 2012)
Log Message:
-----------
Switched to using relative rather than absolute pathnames when using an Ajax 
source for DataTables in Search and Report, preventing a bug resulting in a 301 
code as a result of a cross-domain request when a page is being served as https

Modified Paths:
--------------
    mrbs/trunk/web/Themes/default/header.inc

Modified: mrbs/trunk/web/Themes/default/header.inc
===================================================================
--- mrbs/trunk/web/Themes/default/header.inc    2012-01-23 18:28:01 UTC (rev 
2252)
+++ mrbs/trunk/web/Themes/default/header.inc    2012-01-26 14:37:24 UTC (rev 
2253)
@@ -2999,7 +2999,7 @@
     // performance for large tables
     if (function_exists('json_encode'))
     {
-      $ajax_url = "http://"; . $HTTP_HOST . $PHP_SELF . "?" . $QUERY_STRING . 
"&ajax=1&phase=2";
+      $ajax_url = basename($PHP_SELF) . "?" . $QUERY_STRING . 
"&ajax=1&phase=2";
       ?>
       tableOptions.sAjaxSource = "<?php echo $ajax_url ?>";
       <?php
@@ -3197,8 +3197,7 @@
       var tableOptions = new Object();
       <?php
       // Use an Ajax source - gives much better performance for large tables
-
-      $ajax_url = "http://"; . $HTTP_HOST . $PHP_SELF . "?" . $QUERY_STRING . 
"&ajax=1";
+      $ajax_url = basename($PHP_SELF) . "?" . $QUERY_STRING . "&ajax=1";
       ?>
       tableOptions.sAjaxSource = "<?php echo $ajax_url ?>";
       tableOptions.aoColumnDefs = [{"sType": "title-numeric", "aTargets": 
[2]}]; 

This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.


------------------------------------------------------------------------------
Keep Your Developer Skills Current with LearnDevNow!
The most comprehensive online learning library for Microsoft developers
is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
Metro Style Apps, more. Free future releases when you subscribe now!
http://p.sf.net/sfu/learndevnow-d2d
_______________________________________________
Mrbs-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mrbs-commits

Reply via email to