jQuery Plugins » Google https://jqueryplugins.info jQuery plugins, tutorials and resources Wed, 19 Oct 2011 19:13:48 +0000 en hourly 1 http://wordpress.org/?v=3.2.1 Google Visualization – get the data from html table https://jqueryplugins.info/2011/10/google-visualization-get-the-data-from-html-table/ https://jqueryplugins.info/2011/10/google-visualization-get-the-data-from-html-table/#comments Tue, 18 Oct 2011 10:13:40 +0000 Admin https://jqueryplugins.info/2011/10/google-visualization-get-the-data-from-html-table/ Post link: Google Visualization – get the data from html table

Is it possible to fetch the data like this (html table): <table border="0"> <thead> <tr> <th scope="row" class="n-1">Month</th> <th class="n-2">N.o.L.</th> <th class="n-3">Val.</th> <th class="n-4">Total</th> <th class="n-5">Num.o.Val.Total</th> </tr> </thead> <tbody> <tr>...

]]>
Post link: Google Visualization – get the data from html table

Is it possible to fetch the data like this (html table):

<table border="0">

    <thead>
    <tr>
            <th scope="row" class="n-1">Month</th>
            <th class="n-2">N.o.L.</th>
            <th class="n-3">Val.</th>
            <th class="n-4">Total</th>
            <th class="n-5">Num.o.Val.Total</th>
        </tr>
</thead>
    <tbody>
    <tr>
            <td class="n-1">1</td>
            <td class="n-2">125</td>
            <td class="n-3">0</td>
            <td scope="col" class="n-4">125</td>
            <td class="n-5">0</td>
        </tr>
    <tr>
            <td class="n-1">2</td>
            <td class="n-2">125</td>
            <td class="n-3">48.75</td>
            <td scope="col" class="n-4">173.75</td>
            <td class="n-5">5</td>
        </tr>
    <tr>
            <td class="n-1">3</td>
            <td class="n-2">125</td>
            <td class="n-3">97.5</td>
            <td scope="col" class="n-4">222.5</td>
            <td class="n-5">10</td>
        </tr>
   </tbody>
</table>

with jQuery and put inside the Google Visualization script in this format?

    data.addRows(13); // number of rows + 1 

    data.setValue(0, 0, '1'); // month = 1 (index, 0, $  month)
    data.setValue(0, 1, 125); // for Month =1, Total = 123 (index, 1, $  total)
    data.setValue(0, 2, 0);   // for Month = 1, Num.o.Val.Total = 5 (index, 2, $  Num.o.Val.Total)
    etc...


The goal is to create this kind of chart: CHART URL from html table.

I looking to set MONTH COLUMN as hAxis and TOTAL COLUMN as vAxis + Num.o.Val.Total (second line).

Any suggestion much appreciated.

newest questions tagged jquery – Stack Overflow

]]>
https://jqueryplugins.info/2011/10/google-visualization-get-the-data-from-html-table/feed/ 0
Google Maps API V3 InfoBox using jQuery fadeIn and fadeOut https://jqueryplugins.info/2011/10/google-maps-api-v3-infobox-using-jquery-fadein-and-fadeout/ https://jqueryplugins.info/2011/10/google-maps-api-v3-infobox-using-jquery-fadein-and-fadeout/#comments Tue, 11 Oct 2011 01:13:08 +0000 Admin https://jqueryplugins.info/2011/10/google-maps-api-v3-infobox-using-jquery-fadein-and-fadeout/ Post link: Google Maps API V3 InfoBox using jQuery fadeIn and fadeOut

I have searched the web high and low and have not been able to find a tutorial or example of using jQuery to fade an Infobox/Infowindow in Google Maps not...

]]>
Post link: Google Maps API V3 InfoBox using jQuery fadeIn and fadeOut

I have searched the web high and low and have not been able to find a tutorial or example of using jQuery to fade an Infobox/Infowindow in Google Maps not the content the actual box/window. Here is my code, I’m not sure what I’m doing wrong, but something also doesn’t seem right.

`google.maps.event.addListener(marker, 'mouseover', function() {
    ib.setContent(html);
    ib.open(map, marker);
    ib.setValues({type: "point", id: 2})

   var idName = marker.get("id"); //I was trying to the id's of the elements here
   var boxName = ib.get("id");    //to use in my jQuery

   jQuery(idName ).mouseover(function() {
      jQuery(boxName ).fadeIn('slow', function() {
    // Animation complete
   });
  });

});`

Thanks for your help in advance.

newest questions tagged jquery – Stack Overflow

]]>
https://jqueryplugins.info/2011/10/google-maps-api-v3-infobox-using-jquery-fadein-and-fadeout/feed/ 0
jquery + google analytics + greasemonkey https://jqueryplugins.info/2011/10/jquery-google-analytics-greasemonkey/ https://jqueryplugins.info/2011/10/jquery-google-analytics-greasemonkey/#comments Thu, 06 Oct 2011 20:15:56 +0000 Admin https://jqueryplugins.info/2011/10/jquery-google-analytics-greasemonkey/ Post link: jquery + google analytics + greasemonkey

Not a total noob when it comes to JS, but started yesterday with JQuery… I want to make GA show 50 lines at a time by default – using GM...

]]>
Post link: jquery + google analytics + greasemonkey

Not a total noob when it comes to JS, but started yesterday with JQuery… :)

I want to make GA show 50 lines at a time by default – using GM + JQuery!
(not in the internal settings).

Plus, i dont want to make any request by myself – GA must do it.
I just want to choose the number “50″ in the Select/ComboBox/DropDown and trigger the default action.
(a POST, if im not mistaken).

what i got so far:

$  (".ACTION-toggleRowShow option[value=50]").attr("selected",true).click();

it works 50%.
all pages start with “50″ selected, but the extra lines are not shown.
maybe its not triggering anything?

with $ ('.ACTION-toggleRowShow').val('50').change();
and $ ('.ACTION-toggleRowShow').val('50').trigger();
and $ ('.ACTION-toggleRowShow').get(0).selectedIndex = 2;

i get the same.

thanks all.

newest questions tagged jquery – Stack Overflow

]]>
https://jqueryplugins.info/2011/10/jquery-google-analytics-greasemonkey/feed/ 0
How to draw lines (like google map) in regular HTML, CSS https://jqueryplugins.info/2011/10/how-to-draw-lines-like-google-map-in-regular-html-css/ https://jqueryplugins.info/2011/10/how-to-draw-lines-like-google-map-in-regular-html-css/#comments Mon, 03 Oct 2011 23:20:50 +0000 Admin https://jqueryplugins.info/2011/10/how-to-draw-lines-like-google-map-in-regular-html-css/ Post link: How to draw lines (like google map) in regular HTML, CSS

How can we draw lines (like google map) in regular HTML,CSS? newest questions tagged jquery – Stack Overflow

]]>
Post link: How to draw lines (like google map) in regular HTML, CSS

How can we draw lines (like google map) in regular HTML,CSS?

newest questions tagged jquery – Stack Overflow

]]>
https://jqueryplugins.info/2011/10/how-to-draw-lines-like-google-map-in-regular-html-css/feed/ 0
Show Google Maps Marker infoname on Mouseover of a Dynamically Generated DIV https://jqueryplugins.info/2011/10/show-google-maps-marker-infoname-on-mouseover-of-a-dynamically-generated-div/ https://jqueryplugins.info/2011/10/show-google-maps-marker-infoname-on-mouseover-of-a-dynamically-generated-div/#comments Sat, 01 Oct 2011 15:13:44 +0000 Admin https://jqueryplugins.info/2011/10/show-google-maps-marker-infoname-on-mouseover-of-a-dynamically-generated-div/ Post link: Show Google Maps Marker infoname on Mouseover of a Dynamically Generated DIV

I want to introduce a functionality which allows a marker’s infoname to appear or disappear upon mouseover or mouseout of a corresponding DIV element generated from jQuery. However, I am...

]]>
Post link: Show Google Maps Marker infoname on Mouseover of a Dynamically Generated DIV

I want to introduce a functionality which allows a marker’s infoname to appear or disappear upon mouseover or mouseout of a corresponding DIV element generated from jQuery. However, I am getting a “a is undefined” error on line 19 of main.js. After extensive testing on my script, I realise that this has something to do with the marker in the newly added lines as commented below:

function addMarker(A) {
 var point = new google.maps.LatLng(A.lat, A.lng);
 var image = new google.maps.MarkerImage('images/r.png',
  new google.maps.Size(30, 30),
  new google.maps.Point(0, 0),
  new google.maps.Point(0, 30));
 marker = new google.maps.Marker({
  map: map,
  position: point,
  icon: image,
 });
}

function addInfoName(A) {
 var infoname = new infoName; // custom object
 google.maps.event.addListener(marker, 'mouseover', function(event) {infoname.show();});
 google.maps.event.addListener(marker, 'mouseout', function(event) {infoname.hide();});
 infoname.open(map, marker);
}

function showResult(A) {
 $  ('#results').append('<DIV id=' + A.pid + '>{Blah Blah Blah}</DIV>');
 return document.getElementById(A.pid);
}

function process(json) {
 $  ('#results').empty();
 total = json.details.length;
 for(i=0; i<total; i++) {
  var detail = json.details[i];
  var marker;
  addMarker(detail);
  addInfoName(detail);

// these new lines are added
  var listDisplay = showResult(detail);
  listDisplay.onmouseover = function(){google.maps.event.trigger(marker, 'mouseover');};
  listDisplay.onmouseout = function(){google.maps.event.trigger(marker, 'mouseout');};
 }
}

google.maps.event.addListener(map, 'idle', function () {$  .getJSON(query, process);});

The error disappears if I merge the function addInfoName into process. However, all the DIVs will point to the last marker if I do so. My question is, how do I modify my script to achieve the functionality mentioned above?

newest questions tagged jquery – Stack Overflow

]]>
https://jqueryplugins.info/2011/10/show-google-maps-marker-infoname-on-mouseover-of-a-dynamically-generated-div/feed/ 0
jQuery Google Charting – changing series data https://jqueryplugins.info/2011/09/jquery-google-charting-changing-series-data/ https://jqueryplugins.info/2011/09/jquery-google-charting-changing-series-data/#comments Fri, 30 Sep 2011 07:16:17 +0000 Admin https://jqueryplugins.info/2011/09/jquery-google-charting-changing-series-data/ Post link: jQuery Google Charting – changing series data

I am sure there is a simple solution to this but I can’t seem to get it working. I need to change the series data for my chart: This works...

]]>
Post link: jQuery Google Charting – changing series data

I am sure there is a simple solution to this but I can’t seem to get it working.

I need to change the series data for my chart:

This works (in my function):

var data = [$ .gchart.series('title1', [50], ‘#F5B800′),
$ .gchart.series(‘title2′, [40], ‘red’)];

$ (‘#chart’).gchart(‘change’, {series: data});

but I would like to set the series values dynamically from a passed value:

(ex)

value1 = ‘[70]‘;

var data = [$ .gchart.series('title1', value1, '#F5B800'),
$ .gchart.series('title2', [40], ‘red’)];

$ (‘#chart’).gchart(‘change’, {series: data});

This causes a js error and the chart does not render.

I’ve tried a number of combinations without any success.

Any ideas?

newest questions tagged jquery – Stack Overflow

]]>
https://jqueryplugins.info/2011/09/jquery-google-charting-changing-series-data/feed/ 0
Open Google Maps in Fancybox, and search within the Fancybox https://jqueryplugins.info/2011/09/open-google-maps-in-fancybox-and-search-within-the-fancybox/ https://jqueryplugins.info/2011/09/open-google-maps-in-fancybox-and-search-within-the-fancybox/#comments Thu, 29 Sep 2011 20:15:10 +0000 Admin https://jqueryplugins.info/2011/09/open-google-maps-in-fancybox-and-search-within-the-fancybox/ Post link: Open Google Maps in Fancybox, and search within the Fancybox

Ok my problem is a little complicated, and I cannot provide a link so I will try my best to explain and show you my code… What I’m trying to...

]]>
Post link: Open Google Maps in Fancybox, and search within the Fancybox

Ok my problem is a little complicated, and I cannot provide a link so I will try my best to explain and show you my code…

What I’m trying to achieve:

I am building a site using WordPress, but the issue does not involve any WordPress specifics, which is why I have posted on SO.

I’m trying to open Fancybox when a user submits a postcode search using Google maps on my page. The Fancybox should open up displaying all results based on the postcode submitted.

The problem

I’ve been able to get the submit button to trigger Fancybox to load my inline Google Maps code (using the jquery.form.js plugin), but for some reason it is not actually displaying any results, which makes me think that it hasn’t sent the request, or it has sent the request but it is not displaying the results.

I think what I need to do is somehow tell Google Maps to load the results without leaving the page, then display the results in the Map displayed within the Fancybox.

It is worth noting that I am using the Pronamic Google Maps plugin.

I have also tested my .js files and they are all working correctly.

HTML:

<form id="event-search-form" class="googleSearch" method="get">
        <input id="lat-field" name="lat" type="hidden" />
        <input id="lng-field" name="lng" type="hidden" />

        <p>
            <label for="address-field"><?php _e('Location', 'text_domain'); ?></label>

            <input id="address-field" name="locatie" value="<?php echo $  address; ?>" type="text" />
        </p>

        <p>
            <input name="actie" type="submit" class="inlineSubmit" value="<?php _e('Search', 'text_domain'); ?>" />
        </p>
    </form>
    <div style="display:none;">
    <div id="googleMapsPop">
            <?php 

            $  fitBounds = false;

            $  address = filter_input(INPUT_GET, 'locatie', FILTER_SANITIZE_STRING);
            $  lat = filter_input(INPUT_GET, 'lat', FILTER_VALIDATE_FLOAT);
            $  lng = filter_input(INPUT_GET, 'lng', FILTER_VALIDATE_FLOAT);

            ?>
            <?php if(!empty($  address)): ?>

            <h3><?php printf(__('Events near: %s', 'text_domain'), $  address);?></h3>

            <?php endif;

            if(function_exists('pronamic_google_maps_mashup')) {
                if(!empty($  lat) && !empty($  lng)) {
                    $  latLo = $  lat - 0.25;
                    $  latHi = $  lat + 0.25;
                    $  lngLo = $  lng - 0.25;
                    $  lngHi = $  lng + 0.25;

                    $  query = new WP_Query(array(
                            'post_type' => 'events' ,
                            'posts_per_page' => -1 ,
                            'meta_query' => array(
                                array(
                                    'key' => '_pronamic_google_maps_active',
                                    'compare' => 'IN' ,
                                    'value' => array('true', true, '1')
                                ) ,
                                array(
                                    'key' => '_pronamic_google_maps_latitude',
                                    'compare' => 'BETWEEN' ,
                                    'value' => array($  latLo, $  latHi)
                                ) ,
                                array(
                                    'key' => '_pronamic_google_maps_longitude',
                                    'compare' => 'BETWEEN' ,
                                    'value' => array($  lngLo, $  lngHi)
                                )
                            )
                        )
                    );

                    if($  query->have_posts()) {
                        $  fitBounds = true;
                    } else {
                        ?>
                        <p>
                            <?php printf(__('We could not find any events near: %s', 'text_domain'), $  address); ?>
                        </p>
                        <?php
                    }
                } else {
                    $  query = array(
                        'post_type' => false
                    );
                }

                pronamic_google_maps_mashup(
                    $  query ,
                    array(
                        'width' => 700 ,
                        'height' => 500 ,
                        'fit_bounds' => $  fitBounds,
                        'marker_options' => array(
                            'icon' => 'http://google-maps-icons.googlecode.com/files/photo.png'
                            ),
                    )
                );
            }
            ?>
        </div>

Jquery:

jQuery(document).ready(function(jQuery) {
jQuery(".pgmm").bind("pronamic-google-maps-ready", function() {
    var form = jQuery("#event-search-form");

    var findLocation = function() {
        var geocoder = new google.maps.Geocoder();
        var address = jQuery("#address-field").val();

        geocoder.geocode({"address": address} , function(results, status) {
            if(status == google.maps.GeocoderStatus.OK) {
                if(results[0]) {
                    var location = results[0].geometry.location;
                    var viewport = results[0].geometry.viewport;

                    jQuery("#lat-field").val(viewport.getCenter().lat());
                    jQuery("#lng-field").val(viewport.getCenter().lng());

                    form.unbind("submit", findLocation);
                    form.submit();
                }
            }
        });

        return false;
    };

    form.submit(findLocation);
});

});

Fancybox Jquery:

jQuery(document).ready(function() {
$  ("#event-search-form, #event-search-form-inside").ajaxForm({
    success: function(responseText){
        $  .fancybox({
            'titlePosition': 'inside',
            'transitionIn' : 'elastic',
            'transitionOut' : 'elastic',
            'href'          : '#googleMapsPop'
        });
    }
});

});

newest questions tagged jquery – Stack Overflow

]]>
https://jqueryplugins.info/2011/09/open-google-maps-in-fancybox-and-search-within-the-fancybox/feed/ 0
Make a select like Google Translate https://jqueryplugins.info/2011/09/make-a-select-like-google-translate/ https://jqueryplugins.info/2011/09/make-a-select-like-google-translate/#comments Mon, 26 Sep 2011 16:14:04 +0000 Admin https://jqueryplugins.info/2011/09/make-a-select-like-google-translate/ Post link: Make a select like Google Translate

I’m trying to make a select like the snapshoot but I can’t make it, and then receve a value with php, I need the select only appears a image, but...

]]>
Post link: Make a select like Google Translate

I’m trying to make a select like the snapshoot but I can’t make it, and then receve a value with php, I need the select only appears a image, but on click appears image and little description on image’s right side, and when click an option close menu and change image to selected, but allow to change it again (Google not allow to change, see an expample that I need on picture added or here: Google Translate (snapshoot make on Chrome).

I need it to receive data by php script.
I’m try it but I can’t do it, please help me, thank in advanced (sorry for my bad english).

I can’t upload images this is the link: http://img40.imageshack.us/img40/7429/ratek.png

newest questions tagged jquery – Stack Overflow

]]>
https://jqueryplugins.info/2011/09/make-a-select-like-google-translate/feed/ 0
Display hyperlink in based on condition in google sitebricks https://jqueryplugins.info/2011/09/display-hyperlink-in-based-on-condition-in-google-sitebricks/ https://jqueryplugins.info/2011/09/display-hyperlink-in-based-on-condition-in-google-sitebricks/#comments Fri, 16 Sep 2011 03:13:09 +0000 Admin https://jqueryplugins.info/2011/09/display-hyperlink-in-based-on-condition-in-google-sitebricks/ Post link: Display hyperlink in based on condition in google sitebricks

I am using Google Sitebricks for developing a user interface. I have a table which i am displaying using @repeat annotation @Repeat(items=regusers, var=”reguser”) <tr> <td><a href="/something/$ {reguser.userId}">$ {reguser.userId}</a></td> <td>$ {reguser.userRegAt}</td>...

]]>
Post link: Display hyperlink in based on condition in google sitebricks

I am using Google Sitebricks for developing a user interface.

I have a table which i am displaying using @repeat annotation

@Repeat(items=regusers, var=”reguser”)

<tr>
<td><a href="/something/$  {reguser.userId}">$  {reguser.userId}</a></td>
<td>$  {reguser.userRegAt}</td>
</tr>

I have a ‘status’ variable .based on this value i wanna toggle display of anchor tag in first column

can you please point me to a solution .

Thanks . .

newest questions tagged jquery – Stack Overflow

]]>
https://jqueryplugins.info/2011/09/display-hyperlink-in-based-on-condition-in-google-sitebricks/feed/ 0
Google adsense reload the whole page on anchor clicks https://jqueryplugins.info/2011/09/google-adsense-reload-the-whole-page-on-anchor-clicks/ https://jqueryplugins.info/2011/09/google-adsense-reload-the-whole-page-on-anchor-clicks/#comments Thu, 15 Sep 2011 00:27:29 +0000 Admin https://jqueryplugins.info/2011/09/google-adsense-reload-the-whole-page-on-anchor-clicks/ Post link: Google adsense reload the whole page on anchor clicks

I have a website, where I have a tab based system. The website has a page http://example.com/pageA.html There are adsense units before and after the tabs. Different tabs can be...

]]>
Post link: Google adsense reload the whole page on anchor clicks

I have a website, where I have a tab based system.
The website has a page http://example.com/pageA.html

There are adsense units before and after the tabs.
Different tabs can be opened by clicking on them. They are jquery based tabs and are linked to content through anchor tags.

What I want to do is reload the whole page when an anchor tag is clicked in the tabs. Does google adsense allow this?

The whole page is only refreshed when the user clicks on another tab. All the content is preloaded on the page.

I also see this being done on ALEXA.COM, but does google adsense allow this?

newest questions tagged jquery – Stack Overflow

]]>
https://jqueryplugins.info/2011/09/google-adsense-reload-the-whole-page-on-anchor-clicks/feed/ 0