Jump to content

Recommended Posts

Posted
  On 9/7/2020 at 5:04 PM, RocketStang said:

I got the menu icon back but now it is on the top right corner of the mobile view.  Shouldn't it be on the nav bar with the other icons?

Expand  

On my site I did the following:
1. I removed a code for template "mobileNavigationIcon" from a global template.
2. Template "mobileNavBar" I edited by adding a hamburger menu code, before </ul>, or now total code this template is:

<ul id='elMobileNav' class='ipsResponsive_hideDesktop' data-controller='core.front.core.mobileNav'>
	{{if \count( \IPS\Output::i()->breadcrumb )}}
		{{if \count( \IPS\Output::i()->breadcrumb ) == 1}}
			<li id='elMobileBreadcrumb'>
				<a href='{setting="base_url"}'>
					<span>{lang="home"}</span>
				</a>
			</li>
		{{else}}
			{{$i = 0;}}
			{{foreach \IPS\Output::i()->breadcrumb as $k => $b}}
				{{if $i + 2 == \count( \IPS\Output::i()->breadcrumb )}}
					<li id='elMobileBreadcrumb'>
						<a href='{$b[0]}'>
							<span>{$b[1]}</span>
						</a>
					</li>
				{{endif}}
				{{$i++;}}
			{{endforeach}}
		{{endif}}
	{{endif}}
	
	{{$defaultStream = \IPS\core\Stream::defaultStream();}}
	<li {{if !\IPS\Member::loggedIn()->canAccessModule( \IPS\Application\Module::get( 'core', 'discover' ) ) }}class='ipsHide'{{endif}}>
		<a data-action="defaultStream" href='{{if $defaultStream}}{$defaultStream->url()}{{else}}{url="app=core&module=discover&controller=streams" seoTemplate="discover_all"}{{endif}}' title="streams"><i class="fa fa-newspaper-o" aria-hidden="true"></i></a>
	</li>

	{{if !\IPS\Member::loggedIn()->restrict_post and \count( \IPS\Member::loggedIn()->createMenu() )}}
	<li data-ipsDrawer data-ipsDrawer-drawerElem='#elMobileCreateMenuDrawer'>
		<a href='#'><i class='fa fa-plus'></i></a>
	</li>
	{{endif}}

	{{if \IPS\Member::loggedIn()->canAccessModule( \IPS\Application\Module::get( 'core', 'search' ) )}}
		<li class='ipsJS_show'>
			<a href='{url="app=core&module=search&controller=search" seoTemplate="search"}' title="search"><i class='fa fa-search'></i></a>
		</li>
	{{endif}}
  <li data-ipsDrawer data-ipsDrawer-drawerElem='#elMobileDrawer'>
		<a href='#' title="navigation">
			{{$total = \IPS\Member::loggedIn()->notification_cnt;}}
			{{if !\IPS\Member::loggedIn()->members_disable_pm and \IPS\Member::loggedIn()->canAccessModule( \IPS\Application\Module::get( 'core', 'messaging' ) )}}
				{{$total += \IPS\Member::loggedIn()->msg_count_new;}}
			{{endif}}
			{{if \IPS\Member::loggedIn()->canAccessModule( \IPS\Application\Module::get( 'core', 'modcp' ) ) and \IPS\Member::loggedIn()->modPermission('can_view_reports')}}
				{{$total += \IPS\Member::loggedIn()->reportCount();}}
			{{endif}}
			{{if $total}}
				<span class='ipsNotificationCount' data-notificationType='total'>{$total}</span>
			{{endif}}
			<i class='fa fa-navicon'></i>
		</a>
	</li>
</ul>


3. Result

1963826623_Screenshotat2020-09-07223905.png.a3300ff0a4653d22f4f0a2fdbd8318d9.png

Posted

This is unfortunate!  The nav menu icon was perfect on the nav bar in 4.4...wonder why they moved it??  Now it really affects the size of logo you can use!  I like to have a little more up top for branding so I am not a fan of the new 4.5 mobile nav icon!  I also like to run default theme with as little modification as possible to make updates easier!

Posted
  On 9/7/2020 at 7:40 PM, Adlago said:

On my site I did the following:
1. I removed a code for template "mobileNavigationIcon" from a global template.
2. Template "mobileNavBar" I edited by adding a hamburger menu code, before </ul>, or now total code this template is:

<ul id='elMobileNav' class='ipsResponsive_hideDesktop' data-controller='core.front.core.mobileNav'>
	{{if \count( \IPS\Output::i()->breadcrumb )}}
		{{if \count( \IPS\Output::i()->breadcrumb ) == 1}}
			<li id='elMobileBreadcrumb'>
				<a href='{setting="base_url"}'>
					<span>{lang="home"}</span>
				</a>
			</li>
		{{else}}
			{{$i = 0;}}
			{{foreach \IPS\Output::i()->breadcrumb as $k => $b}}
				{{if $i + 2 == \count( \IPS\Output::i()->breadcrumb )}}
					<li id='elMobileBreadcrumb'>
						<a href='{$b[0]}'>
							<span>{$b[1]}</span>
						</a>
					</li>
				{{endif}}
				{{$i++;}}
			{{endforeach}}
		{{endif}}
	{{endif}}
	
	{{$defaultStream = \IPS\core\Stream::defaultStream();}}
	<li {{if !\IPS\Member::loggedIn()->canAccessModule( \IPS\Application\Module::get( 'core', 'discover' ) ) }}class='ipsHide'{{endif}}>
		<a data-action="defaultStream" href='{{if $defaultStream}}{$defaultStream->url()}{{else}}{url="app=core&module=discover&controller=streams" seoTemplate="discover_all"}{{endif}}' title="streams"><i class="fa fa-newspaper-o" aria-hidden="true"></i></a>
	</li>

	{{if !\IPS\Member::loggedIn()->restrict_post and \count( \IPS\Member::loggedIn()->createMenu() )}}
	<li data-ipsDrawer data-ipsDrawer-drawerElem='#elMobileCreateMenuDrawer'>
		<a href='#'><i class='fa fa-plus'></i></a>
	</li>
	{{endif}}

	{{if \IPS\Member::loggedIn()->canAccessModule( \IPS\Application\Module::get( 'core', 'search' ) )}}
		<li class='ipsJS_show'>
			<a href='{url="app=core&module=search&controller=search" seoTemplate="search"}' title="search"><i class='fa fa-search'></i></a>
		</li>
	{{endif}}
  <li data-ipsDrawer data-ipsDrawer-drawerElem='#elMobileDrawer'>
		<a href='#' title="navigation">
			{{$total = \IPS\Member::loggedIn()->notification_cnt;}}
			{{if !\IPS\Member::loggedIn()->members_disable_pm and \IPS\Member::loggedIn()->canAccessModule( \IPS\Application\Module::get( 'core', 'messaging' ) )}}
				{{$total += \IPS\Member::loggedIn()->msg_count_new;}}
			{{endif}}
			{{if \IPS\Member::loggedIn()->canAccessModule( \IPS\Application\Module::get( 'core', 'modcp' ) ) and \IPS\Member::loggedIn()->modPermission('can_view_reports')}}
				{{$total += \IPS\Member::loggedIn()->reportCount();}}
			{{endif}}
			{{if $total}}
				<span class='ipsNotificationCount' data-notificationType='total'>{$total}</span>
			{{endif}}
			<i class='fa fa-navicon'></i>
		</a>
	</li>
</ul>


3. Result

1963826623_Screenshotat2020-09-07223905.png.a3300ff0a4653d22f4f0a2fdbd8318d9.png

Expand  

Thanks!

Dumb question ... how do you change the fonts / background colors in the mobile menu?  When I click through, the notifications and messages icons are white and can't be seen b/c the background is white as well.

Posted
  On 9/7/2020 at 7:40 PM, Adlago said:

On my site I did the following:
1. I removed a code for template "mobileNavigationIcon" from a global template.
2. Template "mobileNavBar" I edited by adding a hamburger menu code, before </ul>, or now total code this template is:

<ul id='elMobileNav' class='ipsResponsive_hideDesktop' data-controller='core.front.core.mobileNav'>
	{{if \count( \IPS\Output::i()->breadcrumb )}}
		{{if \count( \IPS\Output::i()->breadcrumb ) == 1}}
			<li id='elMobileBreadcrumb'>
				<a href='{setting="base_url"}'>
					<span>{lang="home"}</span>
				</a>
			</li>
		{{else}}
			{{$i = 0;}}
			{{foreach \IPS\Output::i()->breadcrumb as $k => $b}}
				{{if $i + 2 == \count( \IPS\Output::i()->breadcrumb )}}
					<li id='elMobileBreadcrumb'>
						<a href='{$b[0]}'>
							<span>{$b[1]}</span>
						</a>
					</li>
				{{endif}}
				{{$i++;}}
			{{endforeach}}
		{{endif}}
	{{endif}}
	
	{{$defaultStream = \IPS\core\Stream::defaultStream();}}
	<li {{if !\IPS\Member::loggedIn()->canAccessModule( \IPS\Application\Module::get( 'core', 'discover' ) ) }}class='ipsHide'{{endif}}>
		<a data-action="defaultStream" href='{{if $defaultStream}}{$defaultStream->url()}{{else}}{url="app=core&module=discover&controller=streams" seoTemplate="discover_all"}{{endif}}' title="streams"><i class="fa fa-newspaper-o" aria-hidden="true"></i></a>
	</li>

	{{if !\IPS\Member::loggedIn()->restrict_post and \count( \IPS\Member::loggedIn()->createMenu() )}}
	<li data-ipsDrawer data-ipsDrawer-drawerElem='#elMobileCreateMenuDrawer'>
		<a href='#'><i class='fa fa-plus'></i></a>
	</li>
	{{endif}}

	{{if \IPS\Member::loggedIn()->canAccessModule( \IPS\Application\Module::get( 'core', 'search' ) )}}
		<li class='ipsJS_show'>
			<a href='{url="app=core&module=search&controller=search" seoTemplate="search"}' title="search"><i class='fa fa-search'></i></a>
		</li>
	{{endif}}
  <li data-ipsDrawer data-ipsDrawer-drawerElem='#elMobileDrawer'>
		<a href='#' title="navigation">
			{{$total = \IPS\Member::loggedIn()->notification_cnt;}}
			{{if !\IPS\Member::loggedIn()->members_disable_pm and \IPS\Member::loggedIn()->canAccessModule( \IPS\Application\Module::get( 'core', 'messaging' ) )}}
				{{$total += \IPS\Member::loggedIn()->msg_count_new;}}
			{{endif}}
			{{if \IPS\Member::loggedIn()->canAccessModule( \IPS\Application\Module::get( 'core', 'modcp' ) ) and \IPS\Member::loggedIn()->modPermission('can_view_reports')}}
				{{$total += \IPS\Member::loggedIn()->reportCount();}}
			{{endif}}
			{{if $total}}
				<span class='ipsNotificationCount' data-notificationType='total'>{$total}</span>
			{{endif}}
			<i class='fa fa-navicon'></i>
		</a>
	</li>
</ul>


3. Result

1963826623_Screenshotat2020-09-07223905.png.a3300ff0a4653d22f4f0a2fdbd8318d9.png

Expand  

Can you ELI5 me this, because I don't understand what I have to do? What do I have to edit and where?

And what is happening @bfarber ? Do we have to manually add menu icons or is this a glitch or something?

Posted
  On 9/10/2020 at 9:37 PM, Nehaj said:

Can you ELI5 me this, because I don't understand what I have to do? What do I have to edit and where?
 

Expand  

1. Open for edit your global template. Find and remove this code

	{template="mobileNavigationIcon" app="core" group="global" params=""}

2. Open for edit template "mobileNavBar"

Copy the code I specified in my previous post, and replace the contents of the template with it.

Posted
  On 9/7/2020 at 7:40 PM, Adlago said:

On my site I did the following:
1. I removed a code for template "mobileNavigationIcon" from a global template.
2. Template "mobileNavBar" I edited by adding a hamburger menu code, before </ul>, or now total code this template is:

<ul id='elMobileNav' class='ipsResponsive_hideDesktop' data-controller='core.front.core.mobileNav'>
	{{if \count( \IPS\Output::i()->breadcrumb )}}
		{{if \count( \IPS\Output::i()->breadcrumb ) == 1}}
			<li id='elMobileBreadcrumb'>
				<a href='{setting="base_url"}'>
					<span>{lang="home"}</span>
				</a>
			</li>
		{{else}}
			{{$i = 0;}}
			{{foreach \IPS\Output::i()->breadcrumb as $k => $b}}
				{{if $i + 2 == \count( \IPS\Output::i()->breadcrumb )}}
					<li id='elMobileBreadcrumb'>
						<a href='{$b[0]}'>
							<span>{$b[1]}</span>
						</a>
					</li>
				{{endif}}
				{{$i++;}}
			{{endforeach}}
		{{endif}}
	{{endif}}
	
	{{$defaultStream = \IPS\core\Stream::defaultStream();}}
	<li {{if !\IPS\Member::loggedIn()->canAccessModule( \IPS\Application\Module::get( 'core', 'discover' ) ) }}class='ipsHide'{{endif}}>
		<a data-action="defaultStream" href='{{if $defaultStream}}{$defaultStream->url()}{{else}}{url="app=core&module=discover&controller=streams" seoTemplate="discover_all"}{{endif}}' title="streams"><i class="fa fa-newspaper-o" aria-hidden="true"></i></a>
	</li>

	{{if !\IPS\Member::loggedIn()->restrict_post and \count( \IPS\Member::loggedIn()->createMenu() )}}
	<li data-ipsDrawer data-ipsDrawer-drawerElem='#elMobileCreateMenuDrawer'>
		<a href='#'><i class='fa fa-plus'></i></a>
	</li>
	{{endif}}

	{{if \IPS\Member::loggedIn()->canAccessModule( \IPS\Application\Module::get( 'core', 'search' ) )}}
		<li class='ipsJS_show'>
			<a href='{url="app=core&module=search&controller=search" seoTemplate="search"}' title="search"><i class='fa fa-search'></i></a>
		</li>
	{{endif}}
  <li data-ipsDrawer data-ipsDrawer-drawerElem='#elMobileDrawer'>
		<a href='#' title="navigation">
			{{$total = \IPS\Member::loggedIn()->notification_cnt;}}
			{{if !\IPS\Member::loggedIn()->members_disable_pm and \IPS\Member::loggedIn()->canAccessModule( \IPS\Application\Module::get( 'core', 'messaging' ) )}}
				{{$total += \IPS\Member::loggedIn()->msg_count_new;}}
			{{endif}}
			{{if \IPS\Member::loggedIn()->canAccessModule( \IPS\Application\Module::get( 'core', 'modcp' ) ) and \IPS\Member::loggedIn()->modPermission('can_view_reports')}}
				{{$total += \IPS\Member::loggedIn()->reportCount();}}
			{{endif}}
			{{if $total}}
				<span class='ipsNotificationCount' data-notificationType='total'>{$total}</span>
			{{endif}}
			<i class='fa fa-navicon'></i>
		</a>
	</li>
</ul>


3. Result

1963826623_Screenshotat2020-09-07223905.png.a3300ff0a4653d22f4f0a2fdbd8318d9.png

Expand  

 

Working!! Thanks!!

Posted
  On 9/10/2020 at 3:48 AM, RunInRed said:

Thanks!

Dumb question ... how do you change the fonts / background colors in the mobile menu?  When I click through, the notifications and messages icons are white and can't be seen b/c the background is white as well.

Expand  

Any help here?

1F88FA8F-AF27-4A99-9AE7-CF69D8B05E9B.jpeg

Posted
  On 9/10/2020 at 9:51 PM, Adlago said:

1. Open for edit your global template. Find and remove this code

	{template="mobileNavigationIcon" app="core" group="global" params=""}

2. Open for edit template "mobileNavBar"

Copy the code I specified in my previous post, and replace the contents of the template with it.

Expand  

I only have

{template="mobileNavigation" if="theme.responsive" app="core" group="global" params=""}

Can @bfarber or someone explain me, why do I have to edit template, to have a functional mobile web?

Posted
  On 9/13/2020 at 9:17 AM, Nehaj said:

I only have

{template="mobileNavigation" if="theme.responsive" app="core" group="global" params=""}

 

Expand  

This is the contents of the "header" in a global template in version 4.5.

1446274648_Screenshotat2020-09-13122519.thumb.png.a8f6064907db8a119dce2b227415baf8.png

Check carefully. Also the default IPS theme.

Posted
  On 9/13/2020 at 9:30 AM, Adlago said:

This is the contents of the "header" in a global template in version 4.5.

1446274648_Screenshotat2020-09-13122519.thumb.png.a8f6064907db8a119dce2b227415baf8.png

Check carefully. Also the default IPS theme.

Expand  

 

Yes, IPS theme, 4.5.2:

<header>
				<div class='ipsLayout_container'>
					{template="logo" app="core" group="global" params=""}
					{{if !\in_array('ipsLayout_minimal', \IPS\Output::i()->bodyClasses )}}{template="userBar" app="core" group="global" params=""}{{endif}}
				</div>
			</header>

 

Posted
  On 9/13/2020 at 9:36 AM, Nehaj said:

 

Yes, IPS theme, 4.5.2:

<header>
				<div class='ipsLayout_container'>
					{template="logo" app="core" group="global" params=""}
					{{if !\in_array('ipsLayout_minimal', \IPS\Output::i()->bodyClasses )}}{template="userBar" app="core" group="global" params=""}{{endif}}
				</div>
			</header>

 

Expand  

Share a link to your community please - for some tests

  • Recently Browsing   0 members

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