Keyword

Problem with K2 plugin I guess :)

  • George Skordilis
  • George Skordilis's Avatar Topic Author
  • Offline
  • New Member
  • Web Enthusiast
More
7 years 11 months ago #154359 by George Skordilis
Problem with K2 plugin I guess :) was created by George Skordilis
Dear all, hello!

So, I recently purchased a K2 plugin (DM K2 Maps) and installed it, followed documentation, everything almost went perfectly, when I tried to contact developer and never got a response. I guess he quited.

So, now all hell has broken loose and have no idea where to seek for some help :)

I will try to explain in details:

1) This plugin all-in-all, what it offers is ability to add a Google Map to each K2 item (using K2 Extra Fields, like Latitude & Longtitude, for example). So the extension parses the Extra Fields that are pointed to, using their IDs.

2) Then, it also offers a component where you can show a Google Map where all K2 items, are listed there.

I have added all maps, I have also added them on the "main" map, everything's OK until here ;)

I was working on a client's production website, on a "hidden" menu item. I had made a test menu, where I had pointed to this component, so I could see if the map works correctly and such.

So, all K2 items that were inside the map, onclick they showed a bubble, where you could also click on the title and go to the K2 item itself. THERE, the map plugin, actually worked.

When visiting the same K2 item from anywhere "outside" the map, the map plugin didn't work.

Only difference I saw, was that from "inside" the map, the link was like (I've used K2's SEO settings) www.domain.tld/k2-item-title. From the "outside", it was like www.domain.tld/component/k2/k2-item-title. When component/k2 was "present", no map. When not, map worked! I know component/k2 is caused by K2 items that are not in a menu item, but due to the fact client uses this website as a business catalogue, it isn't so user-friendly creating a menu item for, say 400 businesses/K2 items. So, I added some code on .htaccess to strip out the "component/k2" from url and it worked!!

I thought I was done with this task and very happy about it!

BUT, when I moved the "test" menu to being the website's new default "home" menu, then that's where the magic began.

K2 items with component/k2 stripped out from the url, stopped working and instead I get a 500 - view not found (dmk2maps, html, dmk2mapsView) error.

So, I removed the code, so that all K2 items "go back" to having the component/k2 on their url and so the map plugin won't work.

I have tried stuff like playing around with the menu that I moved, its alias. No luck, tried using code and altering some JRequest::getCmd() into JFactory::getApplication()->input->get(), no luck. Tried adding a "main" menu item where I would assign K2 all categories and so all K2 items could have a link like www.domain.tld/k2-menu-item-alias/k2-item-alias, no luck there either.

So, if you haven't yet slept on your keyboard due to my detailed description, maybe someone could help, please?

Thank you very much in advance!

I'd be glad to be of help to anyone, regarding services related to:
Web Design - Development - Support / Mobile Apps / Linux-based cPanel Servers

---
www.gsproject.gr

Please Log in or Create an account to join the conversation.

  • Krikor Boghossian
  • Krikor Boghossian's Avatar
  • Offline
  • Platinum Member
More
7 years 11 months ago #154366 by Krikor Boghossian
Replied by Krikor Boghossian on topic Problem with K2 plugin I guess :)
These are really strange issue.
The pluign is not being triggered throughout the categories.
Are K2 plugins enabled in ALL your categories?

JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)

Please Log in or Create an account to join the conversation.

  • George Skordilis
  • George Skordilis's Avatar Topic Author
  • Offline
  • New Member
  • Web Enthusiast
More
7 years 11 months ago #154433 by George Skordilis
Replied by George Skordilis on topic Problem with K2 plugin I guess :)
Actually, the plugin is being triggered, but maybe "partially".

Now, I have managed to keep the map working on the homepage, using extensions' component assigned on a menu item.

What I haven't manage to find out, is why on the K2 items (which same extension's plugin is being loaded), the maps show this gray area, instead of the map.

It seems like the map is being loaded (controls, marker point, etc.), but NOT the map itself. It looks "blank".

Yeap, K2 plugins are enabled, everywhere from inside categories' settings... :/

I'd be glad to be of help to anyone, regarding services related to:
Web Design - Development - Support / Mobile Apps / Linux-based cPanel Servers

---
www.gsproject.gr

Please Log in or Create an account to join the conversation.

  • Mohamed Abdelaziz
  • Mohamed Abdelaziz's Avatar
  • Offline
  • Platinum Member
  • Joomla Developer
More
7 years 11 months ago #154438 by Mohamed Abdelaziz
Replied by Mohamed Abdelaziz on topic Problem with K2 plugin I guess :)
Hello George,

According to your latest reply, do you find any javascript error when the map shows only a gray area?

Multiple Extra Fields Groups for K2
AutoMeta for K2
Chained Fields for K2
More K2 Extensions In My Extensions Store

Please Log in or Create an account to join the conversation.

  • Krikor Boghossian
  • Krikor Boghossian's Avatar
  • Offline
  • Platinum Member
More
7 years 11 months ago #154461 by Krikor Boghossian
Replied by Krikor Boghossian on topic Problem with K2 plugin I guess :)
Hello there,

I agree with Mohamed this is most likely a JS error.

JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)

Please Log in or Create an account to join the conversation.

  • George Skordilis
  • George Skordilis's Avatar Topic Author
  • Offline
  • New Member
  • Web Enthusiast
More
7 years 11 months ago #154727 by George Skordilis
Replied by George Skordilis on topic Problem with K2 plugin I guess :)
Dear all, hello! Excuyse my delay, but I've been busy ;)

So, the problem was solved actually only by using CSS! (?).

So, I'll write it here, in case it helps someone, of course.

So, the issue was that the Google Map on each K2 item, was showing a grey area instead of the map. I had no .js errors, nothing at all! Error console showed nothing, not even warnings.

So I googled around a 'bit, and found out this kind of magic:

I simply added this (for my purpose, at least) on my CSS: #map_canvas img { max-width: none !important; }

Bam! Worked like a charm!!

THank you very much for your time reading my problem and answering to me people ;)

I'd be glad to be of help to anyone, regarding services related to:
Web Design - Development - Support / Mobile Apps / Linux-based cPanel Servers

---
www.gsproject.gr

Please Log in or Create an account to join the conversation.

  • Krikor Boghossian
  • Krikor Boghossian's Avatar
  • Offline
  • Platinum Member
More
7 years 11 months ago #154730 by Krikor Boghossian
Replied by Krikor Boghossian on topic Problem with K2 plugin I guess :)
Ooook strange issue indeed George.
Thank you for sharing this, It will help other users as well.

JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)

Please Log in or Create an account to join the conversation.


Powered by Kunena Forum