I want an image or other code to appear only on the main page and title, what code can we use for this?
Can't understand my question?
Where on the page do you want it?
Try this -
if (($context['current_action'] == '')
You can use a portal modification to create a block containing whatever you're trying to display and have it set to appear on the desired pages/sections.
Quote from: Sir Osis of Liver on December 19, 2020, 10:55:47 PM
Try this -
if (($context['current_action'] == '')
I think this will do, thank you.
Quote from: Chen Zhen on December 19, 2020, 11:29:59 PM
You can use a portal modification to create a block containing whatever you're trying to display and have it set to appear on the desired pages/sections.
I don't use a portal anyway, thanks.
just checking in to make sure that that worked for you....
can we mark this topic as solved or do you still need help?
unfortunately not working
Maybe
if ($context['current_action'] == 'whatever the action may be')
{
echo '
<div>your code</div>';
}
The code Liver posted had 3 parenthesis
Quote from: Mick. on January 15, 2021, 08:39:45 PM
Maybe
if ($context['current_action'] == 'whatever the action may be')
{
echo '
<div>your code</div>';
}
The code Liver posted had 3 parenthesis
I saw the parenthesis error and solved that problem.
What value should be for the homepage. Home?
Fields like other search help memberlist are okay, but home page doesn't appear.
Required for me homepage.
Im not sure since a portal is not an action.. Leave it empty. It will show in non action pages like the portal, message index and topic view.
(You can never have ((too many)) parentheses.) :P