Close

Account

Documentation

Forum

Menu

How to manage two languages

  • Post count: 3458
    Ferdy
    November 23, 2018 at 10:55 am #39661

    Hi wissal-kh,

    2. Currently, I want to check your website but it not showing anything. please check it on your side.
    3. If you want to remove the sidebar completely from the editor, please go to wp-content/themes/jnews/assets/css/admin replace editor.css and editor-rtl.css with this file https://www.dropbox.com/sh/dfzjmmsuml99nn0/AACwPO8NDVj5wwoSZRLDTzOxa?dl=0

    Thank you

    Post count: 17
    wissal-kh
    November 23, 2018 at 6:37 pm #39685
    This reply has been marked as private.
    Post count: 3458
    Ferdy
    November 26, 2018 at 9:44 am #39727

    Hi wissal-kh,

    2. Can you provide me your login access? I will help you to configure the slider. don’t forget to check Set as the private reply option.
    3. have you tried to clear your cache? if yes and you still see the sidebar, please go to wp-content/themes/jnews/assets/css/admin replace editor.css and editor-rtl.css with this file https://www.dropbox.com/sh/a6081fwk3phs70j/AAB8Xgo7wJ0kn70GxAFOxZzLa?dl=0

    Thank you

    Post count: 17
    wissal-kh
    November 27, 2018 at 11:14 pm #39845

    Hi ferdy,

    3. I cleared my cache and replaced with the new files but I still have that sidebar :/

    4.I want to change the menu size depending on the languge so I added this javascript code

    the problem is that the menu load ith the default side and then the javascript is loaded so we can see the size changing!
    Where can I change the menu size directly in code so I dont have thi issue

    5.On mobile version (both languages) the ebsite moves horizontally, if we slide using the fnger the whole pages moves to right and left, it seems there is extra margins I dont know where they come from!

    Thank you for your help

    Post count: 3458
    Ferdy
    November 28, 2018 at 1:37 pm #39892

    Hi wissal-kh,

    3. Can you provide me your login access? because replace the file is remove the sidebar on the editor. please try to clear your browser cache and do a hard refresh.

    4. Can you provide me where did you add the code?

    5. I assume the issue come from the slider. please check on my screenshot. in this case, please check your page configuration.

    Thank you

    Post count: 17
    wissal-kh
    November 28, 2018 at 11:34 pm #39964
    This reply has been marked as private.
    Post count: 3458
    Ferdy
    November 29, 2018 at 10:09 am #39986

    Hi wissal-kh,

    4. in this case, can you provide me the full script?

    5. please set the margin row of Jnews slider to 0 (please check on my screenshot), please set the margin of textwidget on sidebar section to 0 (please check on my screenshot).

    Thank you

    Post count: 17
    wissal-kh
    November 29, 2018 at 6:17 pm #40062
    This reply has been marked as private.
    Post count: 3458
    Ferdy
    November 30, 2018 at 11:40 am #40091

    Hi wissal-kh,

    4. in this case, script cannot be loaded at the first time before all html code loaded. So, you will see the change and it’s normal.

    5. please set the margin of textwidget on sidebar section to 0 (please check on my screenshot).

    Thank you

    Post count: 17
    wissal-kh
    November 30, 2018 at 4:57 pm #40114

    Hi,

    4. I know that’s what I told you in my question , what I want to know is where I can change the code directly in the menu php page, there should be a function to detect language in php then I can add my class to the menu but I dont know where to find the menu page..
    Or maybe add my code to the main js file

    • This reply was modified 8 months, 3 weeks ago by  wissal-kh.
    Post count: 11697
    Adek
    December 3, 2018 at 11:41 am #40201

    Hi wissal-kh,

    For a hint, please try to check this file wp-content/themes/jnews/class/Menu/MenuWalker.php then find this function start_el. You can check this article about check the current language https://developer.wordpress.org/reference/functions/get_locale/. Let us know if you have further question.

    Thank you

You must be logged in to reply to this topic.