Changeset 1240
- Timestamp:
- 02/10/2015 12:43:47 AM (10 years ago)
- Location:
- sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-themes
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-themes/content-single.php
r1239 r1240 106 106 function drawThemeDownloadsChart() { 107 107 jQuery(document).ready(function($){ 108 jQuery.getJSON('https://api.wordpress.org/stats/themes/1.0/downloads.php?slug=<?php echo $theme->slug; ?>&limit= 267&callback=?', function (downloads) {108 jQuery.getJSON('https://api.wordpress.org/stats/themes/1.0/downloads.php?slug=<?php echo $theme->slug; ?>&limit=730&callback=?', function (downloads) { 109 109 var data = new google.visualization.DataTable(), 110 count = 0, 111 sml; 110 count = 0; 112 111 113 112 data.addColumn('string', _wpThemeSettings.l10n.date); … … 121 120 }); 122 121 123 sml = data.getNumberOfRows() < 225;124 125 122 new google.visualization.ColumnChart(document.getElementById('theme-download-stats-<?php echo esc_attr( $theme->slug ); ?>')).draw(data, { 126 123 colors: ['#253578'], … … 132 129 chartArea: { 133 130 height: 280, 134 left: sml ? 30 : 0,135 width: sml ? '80%' : '100%'131 left: 35, 132 width: '98%' 136 133 }, 137 134 hAxis: { … … 140 137 vAxis: { 141 138 format: '###,###', 142 textPosition: sml ? 'out' : 'in',139 textPosition: 'out', 143 140 viewWindowMode: 'explicit', 144 141 viewWindow: {min: 0} -
sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-themes/js/theme.js
r1209 r1240 244 244 var self = this; 245 245 246 $.getJSON( 'https://api.wordpress.org/stats/themes/1.0/downloads.php?slug=' + self.model.get( 'id' ) + '&limit= 230&callback=?', function( downloads ) {246 $.getJSON( 'https://api.wordpress.org/stats/themes/1.0/downloads.php?slug=' + self.model.get( 'id' ) + '&limit=730&callback=?', function( downloads ) { 247 247 var data = new google.visualization.DataTable(), 248 count = 0, 249 sml; 248 count = 0; 250 249 251 250 data.addColumn('string', _wpThemeSettings.l10n.date); … … 258 257 count++; 259 258 }); 260 261 sml = data.getNumberOfRows() < 225;262 259 263 260 new google.visualization.ColumnChart(document.getElementById('theme-download-stats-' + self.model.get( 'id' ) )).draw(data, { … … 270 267 chartArea: { 271 268 height: 280, 272 left: sml ? 30 : 0,273 width: sml ? '80%' : '100%'269 left: 35, 270 width: '98%' 274 271 }, 275 272 hAxis: { … … 278 275 vAxis: { 279 276 format: '###,###', 280 textPosition: sml ? 'out' : 'in',277 textPosition: 'out', 281 278 viewWindowMode: 'explicit', 282 279 viewWindow: {min: 0}
Note: See TracChangeset
for help on using the changeset viewer.