I tried Googling and using forums.joomla.org, because I wanted to make sure I wasn't wasting people's time on here, but unfortunately I have had no luck. Here's my issue:
For my website, I have both a landing page which only has the link to register for free to become a member, and a proper index page which users access after they become registered. I set up the landing page as kanadax.ca/ because I want people to land there when they first come to the page. My real index page is located at kanadax.ca/index.php. However, now when users are already logged in and they click on the website logo to go to the root domain, they get a page not found error.
So what I want to do is: - If it's a non-registered guest user, have the logo redirect to the landing page located at kanadax.ca/. - Once a user becomes registered, anytime they go to kanadax.ca/index.php it should redirect to example.com/index.php.
Basically I'm looking for conditional redirecting based on user groups. Any ideas?
Now obviously I would actually prefer example.com/ url as main index page rather than the less attractive example.com/index.php but that's a second step after I fix the redirection. I believe it can be done with .htaccess but with the more complicated landing page - index page structure that I have for guest and registered users I think it may be a bit difficult. However, please do give feedback if you have any in this area as well.
I should mention I'm not super comfortable with php but I'm happy to try any suggestions if you'd like to give me a step by step. After all, my first goal in making this website is to learn!
Thanks a heap!
PS if necessary, I'm happy to provide a test account so you can play around with the website yourselves.
**Edit:
Hey @Adam, I really appreciate the input and the step by step, it's exactly what I needed. Now, I have put the first section at the beginning of index.php, however for the latter part, I'm not quite sure where to put it. When I search for anything logo related within index.php, two separate sections come up:
// Logo file or site title param
if ($this->params->get('logoFile'))
{
$logo = '<img src="'. JURI::root() . $this->params->get('logoFile') .'" alt="'. $sitename .'" />';
}
elseif ($this->params->get('sitetitle'))
{
$logo = '<span class="site-title" title="'. $sitename .'">'. htmlspecialchars($this->params->get('sitetitle')) .'</span>';
}
else
{
$logo = '<span class="site-title" title="'. $sitename .'">'. $sitename .'</span>';
}
and
<div class="header">
<div class="header-inner clearfix">
<a class="brand pull-left" href="http://www.kanadax.ca/index.php/anasayfa">
<?php echo $logo;?> <?php if ($this->params->get('sitedescription')) { echo '<div class="site-description">'. htmlspecialchars($this->params->get('sitedescription')) .'</div>'; } ?>
</a>
<div class="header-search pull-right">
<jdoc:include type="modules" name="position-0" style="none" />
</div>
</div>
</div>
second part being under header. Do you think either of these is the right section? If so, should I delete what is in there and replace with your suggestion, or keep it?