Forked from stevewithington/mura-front-end-toolbar-link.cfm
Created
April 27, 2018 19:05
-
-
Save mattlevine/d28d08ae5302d5334ab7e8bcbf11f99c to your computer and use it in GitHub Desktop.
Mura: How to add a link to the front end toolbar
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!--- | |
Add this to a Mura Event Handler | |
You could also use some logic such as | |
<cfif m.currentUser().isInGroup('some group')> then display something </cfif> | |
---> | |
<cffunction name="onFEToolbarExtensionRender"> | |
<cfset str = ""/> | |
<cfsavecontent variable="str"> | |
<cfoutput> | |
<ul id="tools-mycustom-tools"> | |
<li id="tool-custom1" class="dropdown"> | |
<a class="dropdown-toggle" href="##"> | |
<i class="mi mi-support"></i> Support | |
</a> | |
<ul class="dropdown-menu"> | |
<li id="nested-1"> | |
<a href="##"> | |
<i class="mi mi-taxi"></i> Need a ride | |
</a> | |
</li> | |
<li id="nested-2"> | |
<a href="##"> | |
<i class="mi mi-rocket"></i> Need a rocket | |
</a> | |
</li> | |
<li id="nested-3"> | |
<a href="##"> | |
<i class="mi mi-ambulance"></i> Need a doctor | |
</a> | |
</li> | |
</ul> | |
</li> | |
</ul> | |
</cfoutput> | |
</cfsavecontent> | |
<cfreturn str /> | |
</cffunction> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment