Home › Forums › Calendar Products › Events Calendar PRO › Google maps permanently zoomed out
- This topic has 18 replies, 8 voices, and was last updated 14 years, 4 months ago by
Rob.
-
AuthorPosts
-
October 15, 2011 at 7:09 am #9722
Robert
ParticipantGuys, I have purchased and am using the plugin. Just one issue with the google maps. Even though in the backend I zoom in to the scale I want, when I save the event it reverts back to a wider view.
October 15, 2011 at 1:28 pm #9729Debbie
MemberI would love an answer to this also, as unfortunately many users do not know enought to click on the + to enlarge. This should be zoomed to the location automatically.
October 15, 2011 at 1:29 pm #9730Shane Pearlman
MemberHey Robert,
The preview on the back end doesn’t set any room level. The zoom level is a default setting and we haven’t messed with it. I’ve filed an issue to see if we can find some simple setting to define the preferred level of zoom. Might be a release or five before that comes out.
October 15, 2011 at 2:49 pm #9736Robert
ParticipantThanks for the reply Shane, I appreciate the quick response. An interesting plugin to see for reference (if you need an idea of what functionality I am after) is “Mappress”. Once the location is set, you can zoom in on the back-end and once you save the map then it shows with the same zoom ratio in the front end. Understand this might not be coming soon but it would be really fantastic functionality. In the case of my site, everything happens in one city and so it seems a weird that the front end incorporates a radius of about 300km :D. Anyway, appreciate the response. Keep up the good work!!
October 15, 2011 at 4:13 pm #9737Birgit
ParticipantRobert, there is a very easy way to set the zoom in the embedded Google maps to a more detailed scale.
You just have to change one parameter in one file. It is called »event-map.php« in the free Events Calender plugin, folder »admin-views«
On line 17 there is a value for zoom, which is set to 8 by default. Replace 8 with 15 or 16 or 17, you have to try what suits your needs best. That should work fine.October 15, 2011 at 9:58 pm #9741Shane Pearlman
MemberDon’t forget to do that using a custom template in your theme folder rather than editing the plugin file itself or you will loose the change when you update.
October 16, 2011 at 12:42 am #9742Robert
ParticipantThanks so much for the advice. I’ll give it go!
October 16, 2011 at 12:49 am #9743Robert
ParticipantBrilliant!!! Worked like charm.
Thanks againOctober 16, 2011 at 6:21 am #9745Debbie
MemberPerfect! Thanks Birgit!
October 16, 2011 at 8:01 pm #9774Brian
ParticipantAs an add-on to Birgit’s comment, I used the custom event fields to have a drop down in the admin event post screen so that I could designate the zoom level uniquely for each event.
I added the following code immediately after zoom: on line 17 in that event-map.php file
And under Events Calendar settings, you need to add a custom events field named something like “zoomlevel” and make it a dropdown, and give it 1 through 20 as the values. This was the second custom events field I had added, so its label is _ecp_custom_2 so you need to change that to _ecp_custom_1 if it’s the first custom event field you’ve created….or the 3rd or whatever….
Now you can have a unique zoom level for each event….hopefully that helps someone, sounds perfect for you Robert. All the best
Brian
October 21, 2011 at 12:34 pm #9992Cindy
MemberI’m sooo close to getting this. Being new to wordpress I know that it’s going to take time…and someone willing to answer silly questions. But I’m getting there! Thanks everyone! 🙂
I understand the part Brian stated, but I’m a little stuck on Shane’s comment about adding a custom template in my theme folder. I know to copy the specific file Brian mentioned then make the necessary additions, but where do I save this new file? I assume I give it the same name, but the location is where I’m stuck. And do I need to add anything else to it to make it work with my theme?
October 21, 2011 at 3:47 pm #9998Rob
MemberHi Cindy! You’ll just want to create a new folder called “events” in your template directory, copy over those files you’d want to modify and tweak them to your heart’s content. You can find more on the process and what files can/can’t be edited at https://theeventscalendar.com/support/faqs/, by scrolling to the first question in the Customization section: “What are template overrides, and how do I do them?”
Hope that helps. Let me know if you’re still having issues from there.
October 21, 2011 at 4:28 pm #10017Cindy
MemberI have figured out that part, yes, about the events folder and the contents thereof.
My question deals specifically with the event-map.php. Brian edited that particular file for allowing custom zoom levels to the google map. It seemed Shane was suggesting a custom template and my question was specifically about that. event-map.php is not one of the template overrides so if I change the event-map.php won’t it be overwritten when there is an update?
October 21, 2011 at 4:36 pm #10018Cindy
MemberHm, I don’t seem to be able to edit my post here so here’s an addon. 🙂
I found the file here: plugins / the-events-calendar / admin-views / event-map.php
I did the edit Brian suggested above and it worked great, except I’m altering the plugin file directly, which would probably be overwritten with an update.
October 24, 2011 at 5:37 pm #10093Rob
MemberHi Cindy. You should be able to edit that file as you would any other, but would have to copy the source over and put the new copied file in that folder (so you had two existing out there in the code). That help?
-
AuthorPosts
- The topic ‘Google maps permanently zoomed out’ is closed to new replies.
