Спорт-вики — википедия научного бодибилдинга
Widget:Trend — различия между версиями
Ars (обсуждение | вклад) (Новая страница: «<script type="text/javascript" src="https://ssl.gstatic.com/trends_nrtr/909_RC04/embed_loader.js"></script> <script type="text/javascript"> trends.embed.renderExp…») |
Ars (обсуждение | вклад) |
||
Строка 1: | Строка 1: | ||
− | <script type="text/javascript" src="https://ssl.gstatic.com/trends_nrtr/909_RC04/embed_loader.js"></script> <script type="text/javascript"> trends.embed.renderExploreWidget("TIMESERIES", {"comparisonItem":[{"keyword":"pureprotein","geo":"RU","time":"today 5-y"}],"category":0,"property":""}, {"exploreQuery":"geo=RU&q=pureprotein"}); </script> | + | function wps_trend($atts){ |
+ | extract( shortcode_atts( array( | ||
+ | 'w' => '500', // width | ||
+ | 'h' => '330', // height | ||
+ | 'q' => '', // query | ||
+ | ), $atts ) ); | ||
+ | //format input | ||
+ | $h=(int)$h; | ||
+ | $w=(int)$w; | ||
+ | $q=esc_attr($q); | ||
+ | $geo=esc_attr($geo); | ||
+ | ob_start(); | ||
+ | ?> | ||
+ | <script type="text/javascript" src="https://ssl.gstatic.com/trends_nrtr/909_RC04/embed_loader.js"></script> | ||
+ | <script type="text/javascript"> trends.embed.renderExploreWidget("TIMESERIES", {"comparisonItem":[{"keyword":"pureprotein","geo":"RU","time":"today 5-y"}],"category":0,"property":""}, {"exploreQuery":"geo=RU&q=pureprotein"}); </script> |
Версия 15:22, 1 февраля 2017
function wps_trend($atts){
extract( shortcode_atts( array( 'w' => '500', // width 'h' => '330', // height 'q' => , // query ), $atts ) ); //format input $h=(int)$h; $w=(int)$w; $q=esc_attr($q); $geo=esc_attr($geo); ob_start();
?> <script type="text/javascript" src="https://ssl.gstatic.com/trends_nrtr/909_RC04/embed_loader.js"></script> <script type="text/javascript"> trends.embed.renderExploreWidget("TIMESERIES", {"comparisonItem":[{"keyword":"pureprotein","geo":"RU","time":"today 5-y"}],"category":0,"property":""}, {"exploreQuery":"geo=RU&q=pureprotein"}); </script>