Rise Company
05-11-2020, 16:40
سكريبت Whmcs كيفية اظهار او اخفاء زر home button
سكريبت Whmcs كيفية اظهار / اخفاء / تغيير رابط الصفحة الرئيسية home button
Change URL for Home and Logo on WHMCS
https://www.rise.company/forum/images/imported/2020/11/17.png
اذهب الى هذا المسار
public_html/whmcs/includes/hooks
هتجد بداخله ملف باسم مختلف بداخله كود يقوم باخفاء و تعديل رابط الهوم
فى حالة ان كان موجود لديك مسبقا اما اذا اردت عمله
create a .php file in /includes/hooks, paste the code into it, save and your home link should change.
the logo link is in header.tpl...
{if $assetLogoPath}
<a href="{$WEB_ROOT}/index.php" class="logo"><img src="{$assetLogoPath}" alt="{$companyname}"></a>
{else}
<a href="{$WEB_ROOT}/index.php" class="logo logo-text">{$companyname}</a>
{/if}
and for the menu, add a .php file to /includes/hooks and add...
<?php
use WHMCS\View\Menu\Item as MenuItem;
add_hook('ClientAreaPrimaryNavbar', 1, function (MenuItem $primaryNavbar)
{
if (!is_null($primaryNavbar->getChild('Home'))) {
$primaryNavbar->getChild('Home')
->setURI('http://www.google.com');
}
});
المرجع:
https://developers.whmcs.com/hooks/getting-started/
https://whmcs.community/topic/271901-change-url-for-home-and-logo-on-whmcs-721/
https://whmcs.community/topic/292390-home-button-on-navbar/
https://forum.whmcs.com/showthread.php?126234-How-do-you-change-the-breadcrumbs-or-sidebar-code&p=505822#post505822
سكريبت Whmcs كيفية اظهار / اخفاء / تغيير رابط الصفحة الرئيسية home button
Change URL for Home and Logo on WHMCS
https://www.rise.company/forum/images/imported/2020/11/17.png
اذهب الى هذا المسار
public_html/whmcs/includes/hooks
هتجد بداخله ملف باسم مختلف بداخله كود يقوم باخفاء و تعديل رابط الهوم
فى حالة ان كان موجود لديك مسبقا اما اذا اردت عمله
create a .php file in /includes/hooks, paste the code into it, save and your home link should change.
the logo link is in header.tpl...
{if $assetLogoPath}
<a href="{$WEB_ROOT}/index.php" class="logo"><img src="{$assetLogoPath}" alt="{$companyname}"></a>
{else}
<a href="{$WEB_ROOT}/index.php" class="logo logo-text">{$companyname}</a>
{/if}
and for the menu, add a .php file to /includes/hooks and add...
<?php
use WHMCS\View\Menu\Item as MenuItem;
add_hook('ClientAreaPrimaryNavbar', 1, function (MenuItem $primaryNavbar)
{
if (!is_null($primaryNavbar->getChild('Home'))) {
$primaryNavbar->getChild('Home')
->setURI('http://www.google.com');
}
});
المرجع:
https://developers.whmcs.com/hooks/getting-started/
https://whmcs.community/topic/271901-change-url-for-home-and-logo-on-whmcs-721/
https://whmcs.community/topic/292390-home-button-on-navbar/
https://forum.whmcs.com/showthread.php?126234-How-do-you-change-the-breadcrumbs-or-sidebar-code&p=505822#post505822