Giter Site home page Giter Site logo

Comments (10)

seyfro avatar seyfro commented on July 26, 2024

Hi guys & ladies,
would be great if anyone could have a look at this issue - had another customer reporting that kind of incompatibility.
thx,
Robert

from siteorigin-panels.

gregpriday avatar gregpriday commented on July 26, 2024

Hi Robert

Sorry for the late reply here. Yeah, the reason we added pre processing to Page Builder is to give widgets the chance to enqueue their scripts and styles before the header is finished. This allowed them to place everything in the header instead of the footer.

Another solution I'm planning on implementing is to use some filters to make Page Builder support the is_active_widget function. That way widgets could handle the early enqueueing themselves. This does seem to be the more standard way.

Would Leaflet Maps Marker work properly if I removed this pre-processing?

from siteorigin-panels.

seyfro avatar seyfro commented on July 26, 2024

Hi Greg,

thanks for getting back to me!

Within my plugins you can choose if javascripts should be enqueued in footer (default) or header (fallback for theme incompatibilities for example) - anyway chaning this setting didnt have any effect on the incompatibility with siteorigin.

The issue for both plugins (leaflet-maps-marker and leaflet-maps-marker-pro) is definitely the pro-processing.

It would be great if that pre-processing could be removed; if this cannot be done generally I would suggest the following approach:

  1. check if one of my plugins is active:
    if (is_plugin_active('leaflet-maps-marker-pro/leaflet-maps-marker.php') || is_plugin_active('leaflet-maps-marker/leaflet-maps-marker.php')) {...}
  2. do not pre-process if active and mapsmarker-shortcode is used:
    $leaflet_options = get_option( 'leafletmapsmarker_options' );
    $leaflet_shortcode = $leaflet_options['shortcode'];
  3. skip that shortcode from preprocessing

hope that approach would work for you.

from siteorigin-panels.

gregpriday avatar gregpriday commented on July 26, 2024

Let me play around with removing pre-processing entirely. Apart from the single usecase of allowing widgets to enqueue their scripts, pre-processing feels unncessasry and a little dirty to be honest.

from siteorigin-panels.

seyfro avatar seyfro commented on July 26, 2024

ok, let me know if you need any input from my side...

from siteorigin-panels.

gregpriday avatar gregpriday commented on July 26, 2024

Just letting you know we've started working on this change. We're essentially making Page Builder content appear to be a sidebar, along with providing get_option('widget_*');. You can keep track on the feature branch https://github.com/siteorigin/siteorigin-panels/tree/feature-support-for-is_active_widget.

from siteorigin-panels.

gregpriday avatar gregpriday commented on July 26, 2024

Hi Robert

We've mostly finished off this feature. Would it be possible for you to check if it's working with Leaflet Maps Marker?

https://github.com/siteorigin/siteorigin-panels/tree/feature-support-for-is_active_widget

We're going to try merge this feature in by 2.1.

from siteorigin-panels.

seyfro avatar seyfro commented on July 26, 2024

Hi Greg,
thanks for the update - looks good: https://www.mapsmarker.com/dev/pro/2015/03/05/1105/ (created a map within a visual editor widget and one within a text widget) - both are displaying correctly.
Looking forward to the v2.1 release so that I can remove the compatibility warning within my plugin.
best,
Robert

from siteorigin-panels.

gregpriday avatar gregpriday commented on July 26, 2024

Oh wow, that's awesome. Thanks for checking! I'll keep you posted on when
this fix goes out into the wild.

On Thu, Mar 5, 2015 at 9:10 PM, Robert Harm [email protected]
wrote:

Hi Greg,
thanks for the update - looks good:
https://www.mapsmarker.com/dev/pro/2015/03/05/1105/ (created a map within
a visual editor widget and one within a text widget) - both are displaying
correctly.
Looking forward to the v2.1 release so that I can remove the compatibility
warning within my plugin.
best,
Robert


Reply to this email directly or view it on GitHub
#14 (comment)
.

I make free WordPress themes
http://siteorigin.com

from siteorigin-panels.

seyfro avatar seyfro commented on July 26, 2024

v2.1 fixes this issue - many thanks again!

from siteorigin-panels.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.