Fancybox in Button

Forums Easy FancyBox Pro Fancybox in Button

Viewing 4 reply threads
  • Author
    Posts
    • #13524
      Igor Arias
      Participant

      Hello,

      I have this question:
      there’s a button in a theme I bought that its controls are in the theme options, now I can change name and link there but can’t give that button a class fancybox-inline.

      also in order to show that particular page in fancybox i need to give the class name to but can’t find anywhere that option maybe because of the theme defaults don’t know… just saying

      any advise?
      here’s the theme https://x-theme.com/avas-default/ just in case want to checkit (i’m using that same style) and the button it’s that one that says BUY

      Thanks for any assistance

    • #13529
      Pharéo
      Keymaster

      Hi Igor, does the button on your site appear in the menu same as the demo page? If so, you should be able to give that menu item (not the button itself) the class fancybox-inline … if not, we might be able to target the button class bddex-menu-btn with some custom javascript. Does the theme have a field to add custom javascript to the footer maybe?

    • #13536
      Igor Arias
      Participant

      Yes Pharéo,

      First of all thanks for the assistance, yes it does both of the questions…
      here’s a screenshot to the button controls https://snag.gy/zKc3sP.jpg

      and here’s the Js and css customs options https://snag.gy/vBLRfZ.jpg
      what you suggest?

    • #13547
      Pharéo
      Keymaster

      OK, thanks for those images they tell me a lot 🙂 … It does not seem to be a regular WordPress menu so there is no option to add a class to the menu item itself. But the Javascript Body field will allow us to add some script that could help us.

      Please try:

      
      jQuery(function($){$('.bddex-menu-btn').addClass('fancybox-inline');});
      

      I’m not sure if the theme will wrap the code in the correct script tags though. So if it does not work, can you share a link to your dev site so I can take a look at the result? You can use the contact form to keep the link off this public forum.

    • #13548
      Igor Arias
      Participant

      Thanks,
      will use the contact form

Viewing 4 reply threads
  • You must be logged in to reply to this topic.