Side Bar Menu

Hi,

I need to rename some items on the side bar menu, for example, Houses are Tinkhundla and Roll Groups are Chiefdom’s. I have tried String Replacement but nothing changes anywhere.

When you right click on the page and view source, you get a nice standard web page which obviously doesn’t exist in reality but is within /modules/School Admin/schoolYear_manage.php but rendered from many other places. So, where do we locate this section for example in the code base so as to be able to change the labels

  • Groupings
                    <ul class="list-none m-0 mb-6">
                                            <li class="p-0 text-sm leading-normal lg:leading-normal">
                            <a href="http://69.63.68.20/gibbon/index.php?q=/modules/School Admin/department_manage.php" class="block -mx-2 px-3 py-1 -my-1 text-gray-700 hover:underline ">
                                Manage Departments
                            </a>
                        </li>
                                            <li class="p-0 text-sm leading-normal lg:leading-normal">
                            <a href="http://69.63.68.20/gibbon/index.php?q=/modules/School Admin/house_manage.php" class="block -mx-2 px-3 py-1 -my-1 text-gray-700 hover:underline ">
                                Manage Houses
                            </a>
                        </li>
                                            <li class="p-0 text-sm leading-normal lg:leading-normal">
                            <a href="http://69.63.68.20/gibbon/index.php?q=/modules/School Admin/rollGroup_manage.php" class="block -mx-2 px-3 py-1 -my-1 text-gray-700 hover:underline ">
                                Manage Roll Groups
                            </a>
                        </li>
                                            <li class="p-0 text-sm leading-normal lg:leading-normal">
                            <a href="http://69.63.68.20/gibbon/index.php?q=/modules/School Admin/yearGroup_manage.php" class="block -mx-2 px-3 py-1 -my-1 text-gray-700 hover:underline ">
                                Manage Year Groups
                            </a>
                        </li>
                                        </ul>
                </li>
    

    Many thanks.

    G.

  • Hi George,

    Rather than editing the code here, I’d highly recommend you use Gibbon’s inbuilt string replacement. Head to Admin > System Admin > String Replacements and hopefully you’ll find it fairly intuitive. In short, you specify a target interface string, and a replacement: when the target is found, the replacement is inserted in its place.

    This all happens on the server side, whilst the page is being built, before the use sees it. Let us know if this helps!

    Cheers,

    Ross

    Hi Ross,

    Thanks for the reply. I did use the string replacement but it doesnt alter the side bar menu.

    Thanks

    G.

    Sorry George, I somehow missed your “I have tried String Replacement but nothing changes anywhere.” comment! By “anywhere” do you mean “anywhere in Gibbon” or “anywhere in the sidebar”?

    I’ve just tested sidebar string replacement in v22, and it is working as expected.

    Is there anything showing in your PHP logs?

    Ross

    Morning Ross,

    The only place it appears not to change is the sidebar menu. Eveywhere else is fine.

    G.

    Morning Ross,

    The only place it appears not to change is the sidebar menu. Eveywhere else is fine. Version is listed as 21.0.1 up to date.

    Nothing in gibbon logs, cant check any others from mobile…

    G.

    Nothing appears in PHP log files. All appears to be OK but still not changing the labels Manage Houses in side bar menu and Assign Houses in main area…

    Very odd! What PHP version are you using? And what server OS? Thanks!

    Php 7.3, server 2012r2, it was the latest softaculous install.

    Hi George,

    A couple more things to check:

    • Are you using Whole or Partial for the string replacement? Be sure to use Partial, since the word you're replacing is part of a larger string.
    • If you visit your System Admin > System Check page, are there any items flagged in red?

    Hi Sandra,

    Your a star, 34 brownie points girl…

    Deleted and re-entered using Partial, Jobs a good’un.

    G.