6
votes
Accepted
Create a link from Backend to SEF Path in Frontend
Since 3.9 there's Joomla\CMS\Router\Route::link() method which takes client (site or administrator) as first argument.
$link = 'index.php?option=com_content&view=article&id=1';
echo '<a ...
3
votes
Accepted
Supporting SEF URLs in custom component
In the old days, the router.php file contained functions: BuildRoute and ParseRoute. Nowadays, if you look at the router.php of the banners extension for example, you will see a class called ...
2
votes
How does Joomla! URL Re-writing works?
The following are sequence of steps occur when you invoke a url:
Joomla will split the url into parts separated by "/", each part (apart form website name itself) is alias of a menu item, an article ...
2
votes
Using SEF URLs breaks all templates
I found the problem:
The templates were not at all responsible.
I am using the JCH Optimize plugin. In the Basic Options tab, there is a Use url rewrite parameter. That was the problem. When I ...
2
votes
Accepted
Joomla 2.5.6 infinite 303 loop (SEF)
The problem is likely your HTTPS redirect. You are likely redirecting to HTTPS at the beginning of your .htaccess file, and later redirecting to HTTP. Another scenario is when your Joomla website is ...
2
votes
Accepted
Menu links working only for logged in users
It's probably best to run a backup before making any changes.
SEF
To narrow down the problem, try disabling URL Rewriting and SEF and renaming .htaccess to .htaccess.old. If this helps, try re-...
2
votes
Article appears even outside given path
This is a problem with the Joomla content router. Specifically, in the following code:
if (!$advanced)
{
$cat_id = (int) $segments[0];
$article_id = (int) $segments[$count - 1];
if ($...
2
votes
Is it safe to use `Use URL Rewriting` option?
When SEF is enabled on a Joomla website, the old non-sef urls still work normally so search engines will still be able to find the pages whether they use the SEF or non-SEF url.
These days, Google ...
2
votes
Accepted
How to disable Joomla routing by Article ID with any alias but use exact alias only
May not be practical for blog articles, but a fixed url can be achieved via menu items: https://docs.joomla.org/Search_Engine_Friendly_URLs#Limitations
Otherwise, if I see it correctly, you have to ...
2
votes
Update SEF URL to change what is output
Joomla works with internal (for example /index.php?option=com_content&view=article&id=42) and external SEF URLs (/some-name). The SEF URLs are created via the menu, and the "alias" ...
2
votes
J4 component URL not SEF
Solution found, all details on https://forum.joomla.org/viewtopic.php?f=831&t=996848
To create a routing in J4 with same behavior that J3, you need to create 4x files :
/com_componentname/src/...
1
vote
Accepted
Find Article SEF URL by ID
It's a bit unclear what's your exact goal and how you are going to use whatever possible answer you are going to get.
Will you have all previous SEF URLs changed? Will you do a search and replace ...
1
vote
Accepted
Is it safe to use `Use URL Rewriting` option?
Yes it is safe - its built into the joomla core to do so. All you need to do is rename the htaccess.txt to .htaccess and then enable it in the joomla global configuration screen.
1
vote
Does JRoute by default finds path to menu link (SEF)
JRoute::_() doesn't find anything. It just turns non-SEF links into SEF. How that is done depends on your component's router. Unless your component implements modern routing (introduced in 3.7, I ...
1
vote
SEF : URL shows user email - Routing
Which eCommerce component you are using ?, It may be the configuration of that component which appending the seller email_id to non-sef url.
Check the configuration of the component and you may find ...
1
vote
Search engines indexing blog items with both SEF urls and non-SEF urls
You have to add canonical link - the prefered URL.
You can use an extesion like RSSeo from RSJoomla or just do it with override.
Robert Went has a post - in english, where you can see how to use the ...
1
vote
Search engines indexing blog items with both SEF urls and non-SEF urls
Three tips that I use:
1) Make sure you have a sitemap that's submitted to Google Webmaster Tools (and Bing's Webmaster Tools as well) and make sure that this sitemap is using all the correct URLs ...
1
vote
Joomla 2.5.6 infinite 303 loop (SEF)
Your problems could be related to a number of reasons:
PHP version (Joomla 2.5 is not built to run on PHP 7)
Try to set your new server to PHP 5.6 This is often done through your cPanel, or ask your ...
1
vote
Accepted
Custom Component URL router
if(empty($result)){
JError::raiseError(404, JText::_('COM_YOURCOMPONENT_ITEM_NOT_FOUND'));
}
1
vote
Get Joomla SEF Url from Database Query
You can use jroute and the contenthelperroute to get the sef urls.
JRoute::_(ContentHelperRoute::getArticleRoute($id, $catid, $language));
If you only have the article ID's you can try this without $...
1
vote
Joomla K2 articles redirect
Add this line to the very beginning of your .htaccess file:
RedirectMatch 301 /blog/item/(\d+)-(.*) /blog/$2
Explanation:
This part (\d+) matches any number immediately after /blog/item/
This part (...
1
vote
Simplify menu item URLs
There are few ways to do it without any plugins:
Create a detached menu (menu without any module) and add there the menu items you want to have a short URL.
Use Redirects component to create a ...
1
vote
Simplify menu item URLs
The simplest option may be to create a new menu which doesn't have an associated module (call it something like 'hidden'). This menu will not appear on the front of the site, but its items can still ...
1
vote
Does it influence SEO if I make short url for all pages in my site?
1) I believe it's not OK, but acceptable and it's up to you to decide. I mean SEF URLs are good for SEO. And SEF mostly if not only stands for human readable URLs.
And short URL's are not. So they are ...
1
vote
Accepted
How to remove index.php from URLs with enabled URL Rewriting on localhost
check if apache rewrite_module ia active in your localhost
1
vote
What is the correct (preffered) entry in SEF plugin for Site Domain
That question has been asked so many times and created very long arguments that were never won by anyone.
My thought: Take a look at google's website, and see if they use www, and do what they're ...
1
vote
Redirect or add missing category alias to URL in Joomla 3.6
You could use the core Joomla! Redirects component.
Documentation: https://docs.joomla.org/Help36:Components_Redirect_Manager
1
vote
Add querystring parameters and generate a SEF URL
Looking at the router implementation of com_jumi here https://github.com/BonavalMultimedia/com_jumi/blob/master/com_jumi_bnvl/router.php for me it seems it doesn't handle extra parameters when sef is ...
1
vote
Accepted
Weird chars in the beginning of SEF url
I found the answer. In my router file I was including model. And it's model file had BOM sygnature included. It was causing this error...
1
vote
Safe SEF URL to a subdomain
I am not sure what you mean with the Multi-sites but 3 installations for 3 sites isn't considered a multi-sites scenario. Probably you have 1 Joomla website installed on the root of your hosting ...
Only top scored, non community-wiki answers of a minimum length are eligible
Related Tags
sef × 122joomla-3.x × 50
url × 39
.htaccess-configuration × 15
seo × 14
jroute × 13
redirect × 10
non-sef-url × 10
router × 9
k2 × 8
joomla-4.x × 8
component × 7
php × 6
custom-component × 6
joomla-3.4 × 5
alias × 5
sh404sef × 5
joomla-2.5 × 4
templates × 4
tags × 4
development × 3
articles × 3
joomla-3.3.x × 3
menu-item × 3
virtuemart × 3