Skip to Content Skip to Menu

[SOLVED] How to hide login on mobile

  • a.muntean
  • a.muntean
  • OFFLINE
  • Posts: 43
  • Thanks: 2
  • Karma: 0
4 years 2 months ago - 4 years 2 months ago #320468 by a.muntean
[SOLVED] How to hide login on mobile was created by a.muntean
Hello!
I have placed a horizontal login on the top corner of my site. It works fine on desktop, but when I open the site on mobile, it brings my whole layout out of whack.
I want to place a login button on the sidebar menu and jut hide this one on mobile. How can I do that?

Thank you in advance,

Andrei
Last edit: 4 years 2 months ago by krileon. Reason: Added [SOLVED] tag to subject

Please Log in or Create an account to join the conversation.

  • krileon
  • krileon
  • ONLINE
  • Posts: 48548
  • Thanks: 8290
  • Karma: 1445
4 years 2 months ago #320475 by krileon
Replied by krileon on topic How to hide login on mobile

I want to place a login button on the sidebar menu and jut hide this one on mobile. How can I do that?

If your Joomla template has the functionality to hide module positions based off device then yes. Otherwise you'll have to try and use "Module Class Suffix" under Advanced Options to add a custom CSS class then write the CSS to hide its contents on certain display sizes using @media usage in your CSS.

I want to place a login button on the sidebar menu and jut hide this one on mobile. How can I do that?

Create a Joomla menu item to CBs login page on your side menu. If you haven't already setup the Guest view access level in Joomla as shown below and set the access of your menu item to Guest so it's only visible to users not logged in.

docs.joomla.org/J3.x:Access_Control_List_Tutorial#Allowing_Guest-Only_Access_to_Menu_Items_and_Modules


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in or Create an account to join the conversation.

  • a.muntean
  • a.muntean
  • OFFLINE
  • Posts: 43
  • Thanks: 2
  • Karma: 0
4 years 2 months ago #320479 by a.muntean
Replied by a.muntean on topic How to hide login on mobile
OK. So this one is sloved: i am using gantry5 and there is a css class to hide it. Worked perfectly.

I used the same class to add the login button and only show it on the mobile menu. Again worked perfectly.

However, now there is another issue: i put the login redirection page to "index.php/home-registered". That is where the desktop login points too.

But: on the mobile menu it leads me to a faulty page. When I look into the link, it seems that the login module ads "/login" after the redirection page. So it redirects the user to "index.php/home-registered/login" which doesn't exist.

What am I doing wrong?

Please Log in or Create an account to join the conversation.

  • krileon
  • krileon
  • ONLINE
  • Posts: 48548
  • Thanks: 8290
  • Karma: 1445
4 years 2 months ago #320495 by krileon
Replied by krileon on topic How to hide login on mobile
Always use a non-SEF URL when configuring URL parameters. You can find the non-SEF URL for "home-registered" by editing its Joomla menu item and reviewing the value in "Link". For example if your menu item is to a Joomla article you might have the below.

index.php?option=com_content&view=article&id=ARTICLE_ID&Itemid=MENU_ID


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in or Create an account to join the conversation.

  • a.muntean
  • a.muntean
  • OFFLINE
  • Posts: 43
  • Thanks: 2
  • Karma: 0
4 years 2 months ago #320506 by a.muntean
Replied by a.muntean on topic How to hide login on mobile
I did that: it seems that the page name that is generated by the menu: index.php?option=com_gantry5&view=custom

brings the link to.../index.php/component/gantry5 - still the wrong link. what am I doing wrong here?

Please Log in or Create an account to join the conversation.

  • a.muntean
  • a.muntean
  • OFFLINE
  • Posts: 43
  • Thanks: 2
  • Karma: 0
4 years 2 months ago #320520 by a.muntean
Replied by a.muntean on topic How to hide login on mobile
I have been working on this and tried several variants - re-did the pages and tried using non-sef urls... it doesn't work. i think there is something wrong with the module.

My situation:
i have 2 modules for login:
1- is the horizontal version - for desktop login
1 - is default version to be shown in the mobile menu

for both. if i use non-sef urls for the redirection page they land me on an error page
for desktop - if i use regular url index.php/main-wall it brings me correctly where i have to be
for mobile - if i use a regular url as above it adds a /login at the end of the link and brings me into an error page.

How can I solve this?

Please Log in or Create an account to join the conversation.

Moderators: beatnantkrileon
Powered by Kunena Forum