This thread is over two years old and may be outdated. Please create a new thread if you need help, or email us if you have an active Premium license.

Problem with a custom widget

2 years ago · Last reply by Andrew Misplon 2 years ago

Hello,
I am new to SiteOrigin and I need to improve a site that contains a custom widget.
This widget displays in a pop-up a 360° image after clicking on the thumbnail.
The widget is created in its folder which is located in the plugins but there is also a page with a piece of Javascript / JQuery code which is located in the site pages.
I would like to remove this page and not have it in the list of pages of the site and that the script is used directly in the widget.
Do you have any idea about this problem?
I attach the script in question
Thanks

$(document).ready(function(){
var viewer = PhotoSphereViewer({
container: 'vue360',
panorama: '',
default_fov: 90,
mousewheel: false,
navbar: false,
size: { width: $(window).width(), height: $(window).height() },
});
})

This is our free support forum. Replies can take several days.

Need fast email support? Get SiteOrigin Premium

Replies

3
  1. Andrew Misplon Staff 2 years, 11 months ago

    Hi Maxime

    Thanks for getting in touch.

    If the widget is built on the SiteOrigin Widgets Bundle Framework, please see https://github.com/siteorigin/docs/blob/develop/widgets-bundle/advanced-concepts/actions/enqueue-frontend-scripts.md.

    If you aren’t using the SiteOrigin Widgets Bundle Framework for your custom widget, you can check https://developer.wordpress.org/reference/functions/wp_enqueue_script/.

  2. Maxime Cottin 2 years, 11 months ago

    Hi Andrew,
    Thanks for your help.
    I will read all this and try to solve this problem

  3. Andrew Misplon Staff 2 years, 11 months ago

    Hi Maxime

    For sure. Let us know how you get on.

    Cheers

    Andrew

Replies on this thread are closed.

Please create a new thread if you have a question, or purchase a SiteOrigin Premium license if you need one-on-one email support.

Have a different question or issue?

Start New Thread