Viewing 21 posts - 1 through 21 (of 21 total)
  • Author
    Posts
  • #1337105

    Hi
    We have the following code in our functions.php to enable the Advanced Layout Editor for The Events Calendar events:

    add_filter('avf_builder_boxes', 'add_builder_to_posttype');
    function add_builder_to_posttype($metabox)
    {
      foreach($metabox as &$meta)
      {
        if($meta['id'] == 'avia_builder' || $meta['id'] == 'layout')
        {
          $meta['page'][] = 'tribe_events'; /*instead add the name of the custom post type here*/
        }
      }
      return $metabox;
    }

    Now we have the button “Advanced Layout-Editor” (Erweiterter Layout-Editor”), but then we cannot use the editor, it is not shown. What we have to do in addition for that we can use the Advanced Layout Editor for The Events Calendar events?

    Thanks very much.

    Best regards
    Mike

    #1337108

    Hey Mike,

    Thanks for contacting us!

    I just tested this on my local installation however it is working fine on my end. I attached a screenshot in private content field below :)

    Regards,
    Yigit

    #1337116

    Hi Yigit
    At the moment, we use Enfold shortcodes without the Advanced Layout Editor, but the new events we like to use directly the Advanced Layout Editor ;-)
    It is very special. I just created a user for you and there it works. But with my user it does not work… what can be the problem?
    See the login below where it works. Perhaps you see, why with my user it does not work ;-)
    Thanks very much.
    Best regards
    Mike

    #1337120

    Hi,

    I was able to create a private test event and it worked with my profile as you mentioned but I am not sure why it is not working on user. I see that you are using User Role Editor plugin. I am not sure if it is related but could you please try de-activating the plugin temporarily to check if that helps?

    Regards,
    Yigit

    #1337164

    Hi Yigit
    I deactivated the User Role Editor plugin but it still did not work.
    The special thing is, that we have 3 Administrator accounts, at 2 of them it works, at 1 it does not work ;-(
    seeschwalbe –> here it works
    yourchoice –> here it does not work
    kriesi –> here it works as you said

    Any other idea what the problem could be? ;-)
    Best regards
    Mike

    #1337203

    Hi Mike,

    Thanks for the update.

    Can we get access to the site using the other account? Please provide the info in the private field. We may have to deactivate the plugins temporarily while testing the site. Is that alright?

    Best regards,
    Ismael

    #1337228

    Hi Ismael
    Sure. You can find the login data in the private content section.
    It’s ok, when you temporarily deactivate plugins.
    Best regards
    Mike

    #1337266

    Hi,

    It is hidden by inline CSS on your account. I think there is a plugin conflict but I did not try de-activating all active plugins. I attached a screenshot in private content field.

    Please try de-activating all active plugins and activate them one by one to find the culprit. You can add following code to bottom of Functions.php file as a temporary solution

    add_action('admin_head', 'ava_custom_admin_css_admin');
    function ava_custom_admin_css_admin() {
      echo '<style>
        #avia_builder.hide-if-js {
          display: block !important;
        }
      </style>';
    }

    Best regards,
    Yigit

    #1337275

    Hi Yigit
    Very special because this is only hidden for one user …
    But I will try with deactivating plugins… will inform you, which plugin makes this problems.
    Best regards
    Mike

    #1337280

    Hi,

    It seems to be related to “hide-if-js” class but I have no idea where it comes from. I hope you can find out by de-activating plugins.

    We will keep the thread open and wait to hear from you :)

    Best regards,
    Yigit

    #1337549

    Hi Yigit
    I didn’t try this out yet.
    But perhaps, it could also be an Enfold Update problem? Because we find more and more problems, see also here:

    This only a possible hint…
    Best regards
    Mike

    #1337565

    Hi Yigit
    I went back to Enfold 4.8.8.1 but this probleme here is still there. So I will check out the plugins.
    Best regards
    Mike

    #1337635

    Hi Yigit
    So, i tested it with deactivating plugins.
    First I deactivated one by one or groups (i.e. all Contact Form 7 Plugins), then I deactivated ALL plugins except the The Events Calendar plugin (because this is needed for the events).
    Unfortunately the Advanced Layout Builder still did not work for this one user.
    Have you any other idea?
    Or should I send you the content of functions.php of the Enfold Child theme?
    Best regards
    Mike

    #1337648

    i noted a different snippet on including a CPT to Advanced Layout Builder –
    i can not test it here – i haven’t installed “The Events Calendar

    try :

    add_filter('avf_builder_boxes','enable_boxes_on_tribeevents');
    function enable_boxes_on_tribeevents($boxes) {
    $boxes[] = array( 'title' =>__('Avia Layout Builder','avia_framework' ), 'id'=>'avia_builder', 'page'=>array('tribe_events'), 'context'=>'normal', 'expandable'=>true );
    $boxes[] = array( 'title' =>__('Layout','avia_framework' ), 'id'=>'layout', 'page'=>array('tribe_events'), 'context'=>'side', 'priority'=>'low');
        return $boxes;
    }

    ________
    Edit: it seem to be an older (deprecated) snippet – see docu on that:
    https://kriesi.at/documentation/enfold/intro-to-layout-builder/#alb-for-any-post-type
    i guess “YOUR CUSTOM POST NAME” is a bit confusing and i suppose that it is for tribe events: tribe_events

    #1337655

    Hi Guenni007
    Thanks for your response. With your snippet it is the same as with my snippet.
    With one administrator user it works, with the other administrator user it does not work ;-(
    But thanks anyway.
    Best regards
    Mike

    #1337689

    did you check the docu link?

    #1337698

    Hi Guenni007
    Yes I did it. Also with the new code snippet we have the same problem, one administrator sees the ALB stuff, the other one not… very strange this…
    Cheers
    Mike

    #1338007

    Hi,

    As @Yigit observed, the display property of the avia-builder container is set to “none” when the other user is active. Adding the snippet that he provided above should override the inline css.

    add_action('admin_head', 'ava_custom_admin_css_admin');
    function ava_custom_admin_css_admin() {
      echo '<style>
        #avia_builder {
          display: block !important;
        }
      </style>';
    }
    

    Best regards,
    Ismael

    #1338090

    Hi Ismael
    Yeah, with your code, also the other administrator user can use the ALB for creating or editing events with The Events Calendar.
    But my question is, WHY this happens… what you mean with “when the other use is active”? I only use one or the other user and no one else uses this two users…
    Thanks vey much.
    Best regards
    Mike

    #1338139

    Hi,

    WHY this happens…

    We are not really sure why this is happening. It works fine on our end, so it might be due to a plugin or because of a custom modification. Adding the snippet above or overriding the inline styling should fix the issue.

    Best regards,
    Ismael

    #1338160

    Hi Ismael
    As we wrote further up, we deactivated all plugins and there was still the same problem.
    But yes, with this snippet it is fixed, so you can close the issue.
    Thanks very much.
    Best regards
    Mike

Viewing 21 posts - 1 through 21 (of 21 total)
  • The topic ‘Advanded Layout Editor for The Events Calendar’ is closed to new replies.