Link To Homepage Links To Current Page, Not Homepage - Question | JoomShaper
Black Friday sale is live with flat 50% OFF. Sale ends soon! Grab your deal now!

Link To Homepage Links To Current Page, Not Homepage

PD

Peter Dowse

Template 3 years ago

Hi Guys,

Not sure if this is template specific but when linking to the homepage in text on this website, the link simply links to whatever page you're on, not the homepage.

You can see two example of this on this page https://womeninseafood.org.au/new/contact - there is a peice of text called 'test' in the content and also the bottom section called 'quick links' with the link to the homepage.

The code in the link is

<p><a href="/component/sppagebuilder/?amp;view=page&amp;id=1">test</a></p>

Not sure why this is behaving the way it is, any ideas?

0
7 Answers
Paul Frankowski
Paul Frankowski
Accepted Answer
Senior Staff 3 years ago #74366

but homepage is homepage so as I said before just use final domain name if you need link to home page. I have no other ideas by now.

0
Paul Frankowski
Paul Frankowski
Accepted Answer
Senior Staff 3 years ago #74346

Hi Peter,

Durining my current checking... "Test" link has this HTML code

<a href="/new/contact">test</a>

so it redirect to contact page, not home page. Anyway, we suggest o use link taken from menu (!) not technical SPPB links.

BTW

Page ID 1 - in most cases is home page, as I noticed during logging to many users websites (not yours this time), so I am not supriced that it redirected to homepage.

So I assume it was just a human mistake.

0
PD
Peter Dowse
Accepted Answer
3 years ago #74348

Hi Paul,

The code for the test link has been taken from the menu item.

See screengrabs below.

Test link code

Menu code

0
Paul Frankowski
Paul Frankowski
Accepted Answer
Senior Staff 3 years ago #74349

Link alias ! just "home"

And what you show me is a home page link

0
Paul Frankowski
Paul Frankowski
Accepted Answer
Senior Staff 3 years ago #74350

BTW

Click on website logo - it redirect to homepage, right. So everything with template is OK. Anyway links are managed by Joomla itself. You work on subfolder not subdomain so using link tto homepage may be tricky. But if after current website will be on root folder just use domain name as a link to home page, and do not worry by now that you have to add /new/ to domain name. Honest advice.

0
PD
Peter Dowse
Accepted Answer
3 years ago #74352

I get that we can use the alias of 'home' in the links, but using these type of links in href's leads to 404's should the alias be changed be the client at any stage down the track.

It's much better to be able to link using the menu link, as then the system will still link to it, no matter what links are used in content, modules etc and if the alias gets changed.

We have another website that's also displaying this behaviour https://usng02.directrouter.com/~mfzdqswc. You can navigate to any page on the website and if you click on the 'home' link in the quick links at the bottom of the page, it will link you through to whatever page you're on, not the homepage.

This is a bug - the site(s) should not behave like this. I'm just trying to determine if it's a SPPB or helix issue (which I think it is) or a Joomla core issue.

There's something strange happening as we have multiple websites all using

<a href="/component/sppagebuilder/?amp;view=page&amp;id=1">

As a link to the homepage in a quick links module with no issues however, something is different about these two websites.

0
PD
Peter Dowse
Accepted Answer
3 years ago #74354

The sub-folder won't make any difference to the URL structure, particularly when the entire URL (including the /new) has been added to public $live_site in the configuration.php

The example listed above of another website displaying this behaviour is in the root folder - not a subdirectory.

0