Custom URLs for categories and products
Forum rules
Always add your Laravel, Aimeos and PHP version as well as your environment (Linux/Mac/Win)
Spam and unrelated posts will be removed immediately!
Always add your Laravel, Aimeos and PHP version as well as your environment (Linux/Mac/Win)
Spam and unrelated posts will be removed immediately!
Custom URLs for categories and products
Hi there,
I hope that you can help.
I've just installed Aimeos on a test domain to try it out, and so far it looks good.
Apologies if this is a bit of a noob question, but I am wondering how to make use of the URL target field when creating a new category so that the URL for that category becomes http://www.example.com/list/<category-name>
Currently it stands as http://www.example.com/list?f_name=Dresses&f_catid=2.
Any help you can provide with this would be most appreciated.
With kind regards,
Mark
I hope that you can help.
I've just installed Aimeos on a test domain to try it out, and so far it looks good.
Apologies if this is a bit of a noob question, but I am wondering how to make use of the URL target field when creating a new category so that the URL for that category becomes http://www.example.com/list/<category-name>
Currently it stands as http://www.example.com/list?f_name=Dresses&f_catid=2.
Any help you can provide with this would be most appreciated.
With kind regards,
Mark
Aimeos version: ~2018.10. PHP version: 7.2 Laravel version: 5.7
Re: Custom URLs for categories and products
That's due to buggy routing in Laravel, in all other frameworks it's "list/1/Home".
You can add a new named route to ./routes/web.php file and add that name (here: aimeos_shop_catalog) in the category target field, e.g.
You can add a new named route to ./routes/web.php file and add that name (here: aimeos_shop_catalog) in the category target field, e.g.
Code: Select all
Route::match( array( 'GET', 'POST' ), 'list/{f_name}/{f_catid}', array(
'as' => 'aimeos_shop_catalog',
'uses' => '\Aimeos\Shop\Controller\CatalogController@listAction'
));
Professional support and custom implementation are available at Aimeos.com
If you like Aimeos, give us a star
If you like Aimeos, give us a star