Skip to Content Skip to Menu

[SOLVED] Redirect on login, again

  • kdave321
  • kdave321
  • OFFLINE
  • Posts: 189
  • Thanks: 24
  • Karma: 1
3 years 11 months ago - 3 years 11 months ago #321413 by kdave321
[SOLVED] Redirect on login, again was created by kdave321
Trying to re=organize my login process for my invite-only website. I have cb-login on every page, but now public logs in from the base URL index.php.

I set redirect on login in CB login module to index.php/media

If they login from index.php - no problem and they end up on index.php/media

However the site logo I changed to index.php/media and if not logged on throws the not logged in error and goes to index.php/cb-login
Similarly the link to CB Profile is visible and throws a different not-auth error and goes to index.php/personal

In both those cases they can still log in but are redirected to index.php/media/cb-login and index.php/media/personal which are 404.
It seems to be trying to return to the logout URL on top of the login redirect.

I see $logoutReturnUrl set in bootstrap-horizontal_logout.php reflects these URL's so somehow I have to disable that.
Last edit: 3 years 11 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: 48435
  • Thanks: 8275
  • Karma: 1443
3 years 11 months ago #321422 by krileon
Replied by krileon on topic Redirect on login, again
Don't use SEF or relative URLs for redirects. Use non-SEF beginning with index.php. Example as follows.

index.php?option=com_comprofiler&view=userprofile

This would redirect to the users profile. If it's a menu item then edit the menu item and copy the Link parameter value. Next add &Itemid=MENU_ID to the URL. Example as follows.

index.php?option=com_content&view=article&id=42&Itemid=294

The above goes to a specific article for example. This ensures users will always go where you're intending for them to go. When you use SEF URLs if you change the menu alias for example you'll break the redirect. If you use relative URLs then depending on where the user is at it could break the URL. Non-SEF URLs prevent all of these issues. They will be SEF during the redirect so they'll see the appropriate URL in their browser address bar.


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.

  • kdave321
  • kdave321
  • OFFLINE
  • Posts: 189
  • Thanks: 24
  • Karma: 1
3 years 11 months ago #321426 by kdave321
Replied by kdave321 on topic Redirect on login, again
Ah ha - I thought it would be something simple like that. So that stops the bad URL's , but I am simply trying to display the menu item that uses Featured Articles menu type.
I copied the link in the menu -
index.php?option=com_content&view=featured
and tacked on the Menu_ID -
index.php?option=com_content&view=featured&itemid=435

The layout is all wrong ( articles in wrong order ) and the menus published to that menu item are missing. I see "itemid" is the correct parameter here -
docs.joomla.org/URLs_in_Joomla
, but it seems to be ignoring it. Output doesn't change regardless of what itemid I use.

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

  • krileon
  • krileon
  • ONLINE
  • Posts: 48435
  • Thanks: 8275
  • Karma: 1443
3 years 11 months ago #321428 by krileon
Replied by krileon on topic Redirect on login, again
You need to be sure to use Itemid it is case sensitive in Joomla for whatever reason.


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.

  • kdave321
  • kdave321
  • OFFLINE
  • Posts: 189
  • Thanks: 24
  • Karma: 1
3 years 11 months ago #321430 by kdave321
Replied by kdave321 on topic Redirect on login, again
lol. I didn't notice the uppercase "I". Hard to tell the difference. Thanks, that fixed it!
The following user(s) said Thank You: krileon

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

Moderators: beatnantkrileon
Powered by Kunena Forum