Adding welcome user message in top bar

Post Reply
Posts: 2
Joined: 23 Jan 2013, 10:21

31 Jan 2016, 08:25

I am trying to add Welcome user message to logged in user in the top bar . In desktop it is working fine.

But in mobile version , in the top bar when i click on top menu button is not working. Welcome user message is overlapping with topmenu-button icon

My topbar template code is as below

Code: Select all

  <ui:composition xmlns=""

	<!-- TOPBAR -->
	<div id="layout-topbar">

		<!-- LOGO -->

		<a id="logo"> <h:outputText value="SIS"
				styleClass="Fs25 Gold FontBold" />

		<!-- MENUBUTTON -->
		<a id="menu-button"> <i class="icon-chevron-down"></i>
			value="Welcome user message"
			styleClass="Fs20 Fright Red PosAbsolute" />[/b][/color]

		<!-- TOPBAR LINKS -->
		<a id="topmenu-button"> <i class="icon-list2"></i>

			<ul id="topbar-menu">
				<li><h:commandLink value="#{msgs.changePassword}"
						action="#{userBean.changePassword}" /></li>
				<li><p:commandLink onclick="PF('aboutdialog').show();"
						id="sisversion" title="SIS #{sisConfigurationBean.versionInfo}"
						value="#{msgs.about}" rendered="false">

		<!-- MENU COVER -->
		<div id="layout-menu-cover">
			<ui:include src="layoutmenu.xhtml" />


		<!-- TOPMENU -->
		<ul id="top-menu">
			<li><p:commandLink value="#{msgs.about}"
					action="#{leftMenuBean.about}" ajax="false" /></li>
			<li><p:commandLink value="#{msgs.tutorials}"
					action="#{leftMenuBean.tutorials}" ajax="false" /></li>
			<li><p:commandLink value="#{}"
					action="#{}" ajax="false" /></li>


Could you suggest what changes should be done so that it works on mobile as well ?

User avatar
Posts: 2776
Joined: 29 Jun 2013, 12:38

01 Feb 2016, 14:59

I couldn't replicate the issue. But, for "Welcome" test, you can try padding-left: 20px / 5% or margin-left: 20px / 5%.

Also, I think you can use jsf:action with JSF2.2 instead of p:* and h:* components(p:commandButton, h:commandLink, ..) in your xhtml;

Code: Select all

   <a jsf:action="#{...}"><i class="fa fa-sign-out"></i> Logout</a>
</li> ... 27136.html ... eat-sheet/

Post Reply
  • Information
  • Who is online

    Users browsing this forum: No registered users and 1 guest