How can I scroll past the map?

Phoca Maps - displaying maps in Joomla! CMS
notblackjack
Phoca Newbie
Phoca Newbie
Posts: 1
Joined: 09 Feb 2015, 11:03

How can I scroll past the map?

Post by notblackjack »

Hello,

I recently put a phoca map on my website, which only has one page (yes, this is intended), and I want to know if there is a way to continue scrolling down even if my mouse is hovering over the map. Currently, if I am scrolling down and my mouse comes over the map I stop scrolling down. When this happens I need to position my mouse next to the map in order to continue scrolling. Is there a way to get rid of this problem because this is very annoying.

Thanks,
Tommy
PS. I am so very sorry if this was posted before, I did check if this had been posted already but I couldn't find anything.
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48403
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: How can I scroll past the map?

Post by Jan »

Hi, unfortunately - this behaviour cannot be managed in Phoca Maps and I think, it cannot be managed in Google Maps, this is the behaviour of html/css and the browser settings :idea: So I think, this is more a question on browser developers :idea:
If you find Phoca extensions useful, please support the project
User avatar
jackprince
Phoca Member
Phoca Member
Posts: 21
Joined: 04 Apr 2013, 11:12
Location: Leipzig, Germany

Re: How can I scroll past the map?

Post by jackprince »

Take a look at http://bdadam.com/blog/simple-usability ... -maps.html

I currently try to make it work with PhocaMaps.
So far no success.

First comment is very interesting as well.

Edit:
So far it seems if I try to use 'mapPhocaMapPlgPM1' it sees it as undefined and setOptions won't work. :/
User avatar
jackprince
Phoca Member
Phoca Member
Posts: 21
Joined: 04 Apr 2013, 11:12
Location: Leipzig, Germany

Re: How can I scroll past the map?

Post by jackprince »

Solved it I think:

On line 445 in phocampas.php

Code: Select all

$output .= $map->setListener();
These are set and somehow get triggered even though mouse scrolling is deactivated in the settings for the map.

Code: Select all

google.maps.event.trigger(markerPhocaMarker1PlgPM1, 'click');
 google.maps.event.addDomListener(tstPhocaMapPlgPM1, 'DOMMouseScroll', CancelEventPhocaMapPlgPM1);
 google.maps.event.addDomListener(tstPhocaMapPlgPM1, 'mousewheel', CancelEventPhocaMapPlgPM1);   }
 }
Solution:

Code: Select all

if($mapp->scrollwheelzoom != 0){
  $output .= $map->setListener();
}
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48403
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: How can I scroll past the map?

Post by Jan »

Hi, thank you very much for the guide.

Jan
If you find Phoca extensions useful, please support the project
User avatar
jackprince
Phoca Member
Phoca Member
Posts: 21
Joined: 04 Apr 2013, 11:12
Location: Leipzig, Germany

Re: How can I scroll past the map?

Post by jackprince »

Jan wrote:Hi, thank you very much for the guide.
My pleasure Jan. Knowing your great extensions for years and it is a pleasure for me to be helpful. :|
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48403
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: How can I scroll past the map?

Post by Jan »

Hi, set in version 3.0.3

Thank you, Jan
If you find Phoca extensions useful, please support the project
monkoid
Phoca Newbie
Phoca Newbie
Posts: 3
Joined: 16 Jun 2016, 08:35

Re: How can I scroll past the map?

Post by monkoid »

Jan wrote:Hi, set in version 3.0.3

Thank you, Jan
Hi,

I verified I was indeed using version 3.0.3 on my Joomla project (3.5) - but when I disable "Scroll Wheel Zoom" and then try to scroll past the map, it still blocks and I need to get my mouse cursor outside the map in order to get the page moving again.


I'd like to get the behaviour described here...
jackprince wrote:Take a look at http://bdadam.com/blog/simple-usability ... -maps.html

I currently try to make it work with PhocaMaps.
So far no success.

First comment is very interesting as well.

Edit:
So far it seems if I try to use 'mapPhocaMapPlgPM1' it sees it as undefined and setOptions won't work. :/
...but I don't know much about programming so I was wondering if someone could tell me what exactly I should do. What I'd like to obtain is the same behaviour as the one on the demo.

EDIT : I just noticed I was using com_phocamaps_v3.0.3 but with plg_content_phocamaps_v3.0.2. I reinstalled and reconfigured with both 3.0.3 files and now scrolling when hovering the map isn't blocked anymore. Still looking to get the above mentioned behaviour though, so any advice would still be welcome on how to implement it. Thanks in advance :)
babouz44
Phoca Member
Phoca Member
Posts: 10
Joined: 15 Apr 2013, 12:16

Re: How can I scroll past the map?

Post by babouz44 »

Hi,
Do you also use the 3.0.3 "plugin" version ?
monkoid
Phoca Newbie
Phoca Newbie
Posts: 3
Joined: 16 Jun 2016, 08:35

Re: How can I scroll past the map?

Post by monkoid »

babouz44 wrote:Hi,
Do you also use the 3.0.3 "plugin" version ?
Yes - I edited my post to add that I saw my plugin was still 3.0.2. I've reinstalled and solved that part.
Post Reply