updating the transparency reporting widget urls
authorAnthony Talarico <talarico@gaslightmedia.com>
Mon, 17 Sep 2018 16:27:48 +0000 (12:27 -0400)
committerAnthony Talarico <talarico@gaslightmedia.com>
Mon, 17 Sep 2018 16:27:48 +0000 (12:27 -0400)
budgetbadge/js/budgetBadge.js
parts/header-meta.php
sidebar.php

index ba237d4..bb4651a 100644 (file)
@@ -101,9 +101,9 @@ function showBudgetButton()
 
 // Execute code
 function FB_addBudgetBadge() {
-    var lTransparencyUrl = window.site_url +'/about-us/reports';
+    var lTransparencyUrl = window.base_url +'/the-latest/public-information-and-reports/transparency-reporting';
     var lTransparencyTarget = '';
-    var lSchoolDataUrl = 'https://www.mischooldata.org/DistrictSchoolProfiles/ReportCard/Dashboard/Dashboard.aspx';
+    var lSchoolDataUrl = 'https://www.mischooldata.org/DistrictSchoolProfiles2/ReportCard/EducationDashboard4.aspx?Common_Locations=1-D,1704,71,0&Common_SchoolYear=&Common_LocationIncludeComparison=False';
     var lSchoolDataTarget = '_blank';
     if (typeof budgetBadgeTransparencyUrl !== "undefined"
         && budgetBadgeTransparencyUrl != null
index d8b12da..1544de0 100644 (file)
         $is_front = is_front_page();
     ?>
     <script>
-        window.site_url = "<?php echo get_template_directory_uri(); ?>"
-        window.page_title     = "<?php echo $page_title ?>"
-        window.page     = "<?php echo $page ?>"
-        window.is_front = "<?php echo $is_front; ?>";
+        window.site_url     = "<?php echo get_template_directory_uri(); ?>"
+        window.page_title   = "<?php echo $page_title ?>"
+        window.page         = "<?php echo $page ?>"
+        window.is_front     = "<?php echo $is_front; ?>";
+        window.base_url     = "<?php echo bloginfo('url'); ?>"
     </script>
   </head>
\ No newline at end of file
index 62c7a0a..416fbbb 100644 (file)
                 $col.siblings('.sidebar-container').height(height + 50);
             }
         }
+        $('a[href*=#]:not([href=#])').click(function() {
+            if (location.pathname.replace(/^\//,'') == this.pathname.replace(/^\//,'') 
+                || location.hostname == this.hostname) {
+            
+                var target = $(this.hash),
+                headerHeight = $("header.main").height(); // Get fixed header height
+                        
+                target = target.length ? target : $('[name=' + this.hash.slice(1) +']');
+                        
+                if (target.length) 
+                {
+                    $('html,body').animate({
+                    scrollTop: target.offset().top - headerHeight
+                    }, 500);
+                    return false;
+                }
+            }
+        });
     })
 </script>
\ No newline at end of file