Viewing 15 posts - 1 through 15 (of 15 total)
  • Author
    Posts
  • #1337364

    Hi,
    On the mobile view the scroll position is to high (top). I loose the titel after I click on a link in the menu. How can I change this postion?

    #1337440

    Hey niclasg,

    Thank you for the inquiry.

    Using this filter in the functions.php file should adjust the scroll position on mobile view.

    function avf_header_setting_filter_mod($header) {
            if(!wp_is_mobile()) {
    	    $header['header_scroll_offset'] = $header['header_scroll_offset'] - 100;
            }
    	return $header;
    }
    add_filter('avf_header_setting_filter', 'avf_header_setting_filter_mod', 9999, 1);

    Please make sure to purge the cache after adding the code.

    Best regards,
    Ismael

    #1337546

    Not working. Following error:

    syntax error, unexpected ‘&’, expecting ‘]’

    #1337582

    Not working at all

    #1337628

    Hi,

    Thank you for the update.

    Looks like some of the characters in the code were converted to their entity name. Did you copy the code from your email? Please make sure to copy it directly from this forum to avoid the character conversion. Let us know if that helps.

    Best regards,
    Ismael

    #1337637

    Hi Ismael,

    Unfortunately I can’t share pictures here. I am not sure what you mean. I add the code again in the functions.php (folder themes/endfold), at the bottom of the php. Please check and let me know how I can adjust it. Or please adjust it. Please help. The title is still under the menu.

    #1337691

    Hi,

    Thank you for following up.

    We tried to access the site using the login account above, but it seems like the username doesn’t exist according to the login error. Please check the login info carefully or provide another admin account so that we can test the modification.

    Best regards,
    Ismael

    #1338088

    Please check

    #1338158

    Hi,

    Thank you for the info.

    The code is already added in the functions.php file when we checked and it adjusted the scroll position offset as expected. The header lands above the title now instead of covering it.

    Best regards,
    Ismael

    #1338161

    No it doesn’t work on an iPhone for example.
    I deleted all the cache, restarted the phone, but the Title like „Rollstuhlcar“ is still under the sticky header. Can I share pictures or a video?

    It just working if I using my desktop display on responsive view, but not at a real phone.

    • This reply was modified 2 years, 10 months ago by niclasg.
    #1338429

    Hi,

    Thank you for the update.

    Looks like the offset is reset to 0 on mobile view. Please edit the js > avia.js file, look for this code around line 758 and remove it. You may need to temporarily disable the Enfold > Performance > File Compression
    settings after editing the file.

    if( isMobile )
    {
         fixedMainPadding = 0;
    }
    

    Best regards,
    Ismael

    #1338912

    Hi Ismael,

    I deleted the code. Now the title h1/h2/h3 etc. like “Krankenwagen” is in the middle of the screen. Can you please check and let me know how I can fix it.

    I like that the title/box will be directly visible under the main menu. The title must be readable and not so much space to the menu.

    KR

    #1339263

    Hi,

    You have to remove the avf_header_setting_filter filter above or adjust the header_scroll_offset value a bit.

    function avf_header_setting_filter_mod($header) {
            if(!wp_is_mobile()) {
    	    $header['header_scroll_offset'] = $header['header_scroll_offset'] - 100;
            }
    	return $header;
    }
    add_filter('avf_header_setting_filter', 'avf_header_setting_filter_mod', 9999, 1);
    

    This line has to be adjusted.

    $header['header_scroll_offset'] = $header['header_scroll_offset'] - 100;
    

    Best regards,
    Ismael

    #1339411

    Hi Ismael,

    Looks ok for now. Thanks.
    Can you re.open the topic:
    https://kriesi.at/support/topic/fixed-sticky-header-on-mobile-iphone/

    Due to this code, Yigit shared with me, the scroll function is on mobile has a defect. After I clicked on a menu point and I wish up and down, it automatically changes the position.

    #1339420

    Hey,

    I re-opened the thread :)

    Regards,
    Yigit

Viewing 15 posts - 1 through 15 (of 15 total)
  • You must be logged in to reply to this topic.