flink property is missing on menu item

For Joomla! 5.x Coding related discussions, you could also use: http://groups.google.com/group/joomla-dev-general

Moderators: ooffick, General Support Moderators

Forum rules
Forum Rules
Absolute Beginner's Guide to Joomla! <-- please read before posting, this means YOU.
Forum Post Assistant - If you are serious about wanting help, you will use this tool to help you post.
Windows Defender SmartScreen Issues <-- please read this if using Windows 10.
Post Reply
maximeb
Joomla! Apprentice
Joomla! Apprentice
Posts: 5
Joined: Mon Apr 29, 2024 7:21 am

flink property is missing on menu item

Post by maximeb » Mon Apr 29, 2024 7:31 am

Hello devs ! :)

I try to make a item menu on my front (nothing that crazy, just a basic item menu for acces to my component view); so i made a default.xml form on my tmpl view folder, and when i try to use that new item menu, i got an error that says :

"Deprecated: htmlspecialchars(): Passing null to parameter #1 ($string) of type string is deprecated in C:\laragon\www\Joomla\modules\mod_menu\tmpl\default_component.php on line 72 ".

So i invastigated, line 72 of default_component.php file is :

echo HTMLHelper::_('link', OutputFilter::ampReplace(htmlspecialchars($item->flink, ENT_COMPAT, 'UTF-8', false)), $linktype, $attributes);

this line display the link of the menu item, and the error occurs beacause it seems something is null on it, so i dump($item) (see the attachment).

Yep :'( as you can see on se screenshot, it seems my $item->flink is null, i saw Joomla is supposed to automaticly deduct the flink from the link, and we can see the link is here at place.

Soooo yeah....i'm a bit confused right now, anyone have a clue about this ?

Thanks !
You do not have the required permissions to view the files attached to this post.

Post Reply

Return to “Joomla! 5.x Coding”