Viewing 15 replies - 1 through 15 (of 16 total)
  • I’ll gladly help to get this issue resolved.:)

    Do you have a link where I can check this issue?

    Thread Starter Supersonic Sites

    (@rgstream)

    https://platform4(dot)steamtrainstation.com/accommodations/ (I have 4 pages total with the issue)

    Wow! That was fast! Les meilleurs developpeurs sont a Montreal!
    What is your paypal account so that we can send you some money for that?

    Let me try to fix it first and then I’d be very happy to receive any donations. The link is in the “Plugin info” box on the plugin’s settings page. ??

    As a matter of fact, I am in the process of finalizing a brand new version of this plugin, and I’ll check if this issue is one of the bugs that this new version solves. Once I’m done with that (today!) I will ask you to download a pre-release version of the plugin to see if it works.

    Give me a couple of hours and I should have it ready! Stand by….

    Quick question: how do you embed this Google map on your page? Is it standard embedding or do you use a plugin for it?

    Thread Starter Supersonic Sites

    (@rgstream)

    Anything you need us to help you, let us know. I am going ahead and leaving you a 5 star review right now! ??

    Thread Starter Supersonic Sites

    (@rgstream)

    In the sidebar we have put:

    <div id="map" class="et_pb_map" style="height:500px !important;width:350px !important";></div>

    and in the header:

    <script src="https://maps.googleapis.com/maps/api/js"></script>
    <script type="text/javascript">
        var red_icon = new google.maps.MarkerImage("https://maps.gstatic.com/mapfiles/ms2/micons/red.png");
        red_icon.size = new google.maps.Size(35, 35);
        red_icon.anchor = new google.maps.Point(0, 35);
        var yellow_icon = new google.maps.MarkerImage("https://maps.gstatic.com/mapfiles/ms2/micons/yellow.png");
        yellow_icon.size = new google.maps.Size(35, 35);
        yellow_icon.anchor = new google.maps.Point(0, 35);
        var markers = [];
        var infowindow = new google.maps.InfoWindow();
        var bounds = new google.maps.LatLngBounds();
        function initialize() {
    var locations = [
                {
                    name: 'The Sabbatical',
                    position: {
                        lat: 48.9297,
                        lng: -125.53667
                    }
                },
                {
                    name: 'Happy Cabin',
                    position: {
                        lat: 48.92794,
                        lng: -125.5379
                    }
                },
                {
                    name: 'Surf Loft',
                    position: {
                        lat: 48.93033,
                        lng: -125.53568
                    }
                },
            ];
    var map = new google.maps.Map(document.getElementById('map'), {
                zoom: 4,
                center: locations[0].position,
                mapTypeId: google.maps.MapTypeId.SATELLITE
            });
            for(i in locations) {
                console.log(locations[i]);
    
                markers[i] = new google.maps.Marker({
                    position: locations[i].position,
                    map: map,
                    title: locations[i].name,
                    icon: red_icon
                });
                bounds.extend(markers[i].getPosition());
                google.maps.event.addListener(markers[i], "click", function() {
                    infowindow.setContent(this.title);
                    infowindow.setPosition(this.getPosition());
                    infowindow.open(map, this);
                });
            }
    
            map.fitBounds(bounds);
    var tables = [
                'sab2b',
                'sab1b',
                'happycabin',
                'SurfLoft'
            ];
    for(j in tables) {
                var element = document.getElementById("tablepress-"+tables[j]);
                if(j == 1) {
                    element.setAttribute('marker', 0);
                } else {
                    element.setAttribute('marker', j);
                }
                element.onmouseover = function () {
                    var marker = this.getAttribute('marker');
                    markers[marker].setIcon(yellow_icon);
                };
                element.onmouseout = function () {
                    var marker = this.getAttribute('marker');
                    markers[marker].setIcon(red_icon);
                };
            }
    
        }
        google.maps.event.addDomListener(window, 'load', initialize);
    </script>

    Hm, I can’t seem to be able to reproduce this on my own system, something about Google API keys. ??

    I think the faster way of testing this, if if you would upgrade the plugin to the pre-release version of 2.0 (which should fix this bug), install it on your site and see if it’s working.

    You can download it from here: https://bitbucket.org/senff/sticky-menu-or-anything-wp/get/feature/placeholder-instead-of-clone.zip

    Installation instructions:
    1. unzip the file to your hard drive
    2. copy all of its contents to /wp-content/plugins/sticky-menu-or-anything (overriding all existing files in that directory)
    3. go into your plugin settings
    4. go to the Advanced tab
    5. make sure “Legacy Mode” is NOT checked
    6. make sure “Debug Mode” is checked

    Once you’ve done that, please let me know!

    Note: this version is pretty much the same as the upcoming 2.0. The only difference is that I haven’t updated the readme files yet and that I need to put in some form of notification, but functionality-wise, it is all done.

    Ah! I did manage to reproduce the issue on my local system after all.

    So I put the new version of the plugin to the test and I’m happy to report that it seem to fix the issue you’re having. Yay!

    You could either use the pre-release version of the plugin as I described above, or you could wait for the actual 2.0 release, which should be later today or tomorrow (I just need to work on the readme files and fix a few typos here and there), and WordPress should give you a notification of that.

    Thread Starter Supersonic Sites

    (@rgstream)

    ??
    I followed the instructions above, I have turned off the Legacy Mode and turned on the Debug mode.

    See my test page: https://platform4(dot)steamtrainstation.com/accommodations/spring-cove/

    Now the header menu doesn’t collapse and the sidebar isn’t sticking anymore… :-/

    What may I be doing wrong?

    Hm, dang.

    I do see that your sticky element is now “#stickyside“, whereas it used to be “.stickyside“. Did you change that or did my plugin do that?

    Not sure about the header though, what is it supposed to do? (It looks fine from what I can see). When you disable the plugin, does the header work differently? Just making sure it’s acting differently because of the plugin.

    Sorry for breaking your site ??

    Thread Starter Supersonic Sites

    (@rgstream)

    Yes, I was testing if it would change something. I’ve put it back like it was before. What if I gave you a user and pass so you can check it out in the back-end? (We have to deliver this website soon and at this point you solving this issue is worth $$) ??

    Thank you for all the trouble.

    PS: The Legacy mode works to make it sticky but without it, it does what you see on the page.

    OK, there may be some other bugs involved now. I’m looking into it, stay tuned.

    Thread Starter Supersonic Sites

    (@rgstream)

    I’ve switched back to legacy mode. This way the header doesn’t freeze. The Google Map doesn’t work thou.

    Thanks for your work.

    OK, I think I figured out what was wrong. For some reason the jQuery library bonked on some code. Not sure if that’s because of my plugin or if it’s a combination of other factors, but I’ve tried to come up with a fix (unfortunately, the issue does not appear on my own local system, so I had to fix it blindly, so to speak).

    Here are some new versions. Can you please download these two files and put them in /wp-content/plugins/sticky-menu-or-anything/assets, overwriting the ones that are in there already?

    jq-sticky-anything.min.js:
    https://bitbucket.org/senff/sticky-menu-or-anything-wp/raw/5571dd7b20633e30f36c9e5eb599a6960697935d/assets/js/jq-sticky-anything.min.js

    jq-sticky-anything.js:
    https://bitbucket.org/senff/sticky-menu-or-anything-wp/raw/5571dd7b20633e30f36c9e5eb599a6960697935d/assets/js/jq-sticky-anything.js

    Thread Starter Supersonic Sites

    (@rgstream)

    I’m sending a big fat thank you via paypal! You are awesome!

Viewing 15 replies - 1 through 15 (of 16 total)
  • The topic ‘Google Map Issue’ is closed to new replies.