• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Application.cfc tags exclusions of certain pages

Explorer ,
Mar 05, 2013 Mar 05, 2013

Copy link to clipboard

Copied

I have the application.cfc page. The only take that are in the file is the code that make cf show the header and footer on all pages. There are a few pages that I would not like the header and footer displayed I.e. a coming soon page. ID there a way to insert a rule into the application.cfc to not allow the "comingsoon.cfm" page to display header and footer?

Here the code I used inside the application.cfc page.

<cfcomponent output="false">

<cfset this.datasource="store1975"><!---

<cffunction name="OnRequestStart" returntype="boolean" output="true">

          <!---Any variable set here can be used by all out pages--->

        <cfset request.company = "Sisterhood">

        <!---Display Header on every Page--->

        <cfinclude template="header.cfm">

        <cfreturn true>

     </cffunction>

   

         <cffunction name="OnRequestEnd" returntype="boolean" output="true">

        <!---Display Footer on every Page--->

        <cfinclude template="footer.cfm">

        <cfreturn true>

     </cffunction>--->

</cfcomponent>

Views

478

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Contributor ,
Mar 06, 2013 Mar 06, 2013

Copy link to clipboard

Copied

LATEST

I do this in mine:

<cfset request.pagename = CGI.SCRIPT_NAME>

<cfif request.pagename neq "/pagepath/comingsoon.cfm"><cfinclude template="header.cfm"></cfif>

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources
Documentation