Jump to content

Editing top nav


ROQ

Recommended Posts

Hey there,

Are you using the twenty-one theme? If so, you can remove the following code from the header.tpl file located in the /templates/twenty-one/ directory.

<button type="button" class="btn" data-toggle="popover" id="accountNotifications" data-placement="bottom">
  <i class="far fa-flag"></i>
  {if count($clientAlerts) > 0}
  {count($clientAlerts)}
  <span class="d-none d-sm-inline">{lang key='notifications'}</span>
  {else}
  <span class="d-sm-none">0</span>
  <span class="d-none d-sm-inline">{lang key='nonotifications'}</span>
  {/if}
</button>
<div id="accountNotificationsContent" class="w-hidden">
  <ul class="client-alerts">
    {foreach $clientAlerts as $alert}
    <li>
      <a href="{$alert->getLink()}">
        <i class="fas fa-fw fa-{if $alert->getSeverity() == 'danger'}exclamation-circle{elseif $alert->getSeverity() == 'warning'}exclamation-triangle{elseif $alert->getSeverity() == 'info'}info-circle{else}check-circle{/if}"></i>
        <div class="message">{$alert->getMessage()}</div>
      </a>
    </li>
    {foreachelse}
    <li class="none">
      {lang key='notificationsnone'}
    </li>
    {/foreach}
  </ul>
</div>

 

Link to comment
Share on other sites

Hi there,

In six its a little different, however the code is still in the header.tpl file.

Change

{if $loggedin}
	<li>
      <a href="#" data-toggle="popover" id="accountNotifications" data-placement="bottom">
          {$LANG.notifications}
          {if count($clientAlerts) > 0}
              <span class="label label-info">{lang key='notificationsnew'}</span>
          {/if}
          <b class="caret"></b>
      </a>
      <div id="accountNotificationsContent" class="hidden">
          <ul class="client-alerts">
              {foreach $clientAlerts as $alert}
                  <li>
                      <a href="{$alert->getLink()}">
                          <i class="fas fa-fw fa-{if $alert->getSeverity() == 'danger'}exclamation-circle{elseif $alert->getSeverity() == 'warning'}exclamation-triangle{elseif $alert->getSeverity() == 'info'}info-circle{else}check-circle{/if}"></i>
                          <div class="message">{$alert->getMessage()}</div>
                      </a>
                  </li>
              {foreachelse}
                  <li class="none">
                      {$LANG.notificationsnone}
                  </li>
              {/foreach}
			</ul>
		</div>
	</li>
	<li class="primary-action">
  		<a href="{$WEB_ROOT}/logout.php" class="btn">
    		{$LANG.clientareanavlogout}
  		</a>
	</li>
{else}
	<li>
  		<a href="{$WEB_ROOT}/clientarea.php">{$LANG.login}</a>
	</li>
	{if $condlinks.allowClientRegistration}
		<li>
  			<a href="{$WEB_ROOT}/register.php">{$LANG.register}</a>
		</li>
	{/if}
	<li class="primary-action">
  		<a href="{$WEB_ROOT}/cart.php?a=view" class="btn">
    		{$LANG.viewcart}
  		</a>
	</li>
{/if}

To

{if $loggedin}
	<li class="primary-action">
  		<a href="{$WEB_ROOT}/logout.php" class="btn">
    		{$LANG.clientareanavlogout}
  		</a>
	</li>
{else}
	<li>
  		<a href="{$WEB_ROOT}/clientarea.php">{$LANG.login}</a>
	</li>
	{if $condlinks.allowClientRegistration}
		<li>
  			<a href="{$WEB_ROOT}/register.php">{$LANG.register}</a>
		</li>
	{/if}
	<li class="primary-action">
    	<a href="{$WEB_ROOT}/cart.php?a=view" class="btn">
        	{$LANG.viewcart}
        </a>
    </li>
{/if}

Excuse the formatting, its messed up in the code blocks and I cant seem to fix it!

Edited by leemahoney3
Link to comment
Share on other sites

On 8/11/2022 at 11:12 AM, leemahoney3 said:

Hi there,

In six its a little different, however the code is still in the header.tpl file.

Change


{if $loggedin}
	<li>
      <a href="#" data-toggle="popover" id="accountNotifications" data-placement="bottom">
          {$LANG.notifications}
          {if count($clientAlerts) > 0}
              <span class="label label-info">{lang key='notificationsnew'}</span>
          {/if}
          <b class="caret"></b>
      </a>
      <div id="accountNotificationsContent" class="hidden">
          <ul class="client-alerts">
              {foreach $clientAlerts as $alert}
                  <li>
                      <a href="{$alert->getLink()}">
                          <i class="fas fa-fw fa-{if $alert->getSeverity() == 'danger'}exclamation-circle{elseif $alert->getSeverity() == 'warning'}exclamation-triangle{elseif $alert->getSeverity() == 'info'}info-circle{else}check-circle{/if}"></i>
                          <div class="message">{$alert->getMessage()}</div>
                      </a>
                  </li>
              {foreachelse}
                  <li class="none">
                      {$LANG.notificationsnone}
                  </li>
              {/foreach}
			</ul>
		</div>
	</li>
	<li class="primary-action">
  		<a href="{$WEB_ROOT}/logout.php" class="btn">
    		{$LANG.clientareanavlogout}
  		</a>
	</li>
{else}
	<li>
  		<a href="{$WEB_ROOT}/clientarea.php">{$LANG.login}</a>
	</li>
	{if $condlinks.allowClientRegistration}
		<li>
  			<a href="{$WEB_ROOT}/register.php">{$LANG.register}</a>
		</li>
	{/if}
	<li class="primary-action">
  		<a href="{$WEB_ROOT}/cart.php?a=view" class="btn">
    		{$LANG.viewcart}
  		</a>
	</li>
{/if}

To


{if $loggedin}
	<li class="primary-action">
  		<a href="{$WEB_ROOT}/logout.php" class="btn">
    		{$LANG.clientareanavlogout}
  		</a>
	</li>
{else}
	<li>
  		<a href="{$WEB_ROOT}/clientarea.php">{$LANG.login}</a>
	</li>
	{if $condlinks.allowClientRegistration}
		<li>
  			<a href="{$WEB_ROOT}/register.php">{$LANG.register}</a>
		</li>
	{/if}
	<li class="primary-action">
    	<a href="{$WEB_ROOT}/cart.php?a=view" class="btn">
        	{$LANG.viewcart}
        </a>
    </li>
{/if}

Excuse the formatting, its messed up in the code blocks and I cant seem to fix it!

Brian Jr solving lots of threads 🙏

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated