House of Fusion
Search over 2,500 ColdFusion resources here
  
Home of the ColdFusion Community

Mailing Lists
Home /  Groups /  ColdFusion Talk (CF-Talk)

cfmodule

  << Previous Post |  RSS |  Sort Oldest First |  Sort Latest First |  Subscribe to this Group Next >> 
Top  |   Reply  |   Original Post  |   RSS Feed  |   Subscribe to this Group
Author:
dave
06/17/2005 11:03 PM

anyone know of any good tuts on using this? I can use it but just wanna know more :) ~Dave the disruptor~ "A criminal is a person with predatory instincts who has not sufficient capital to form a corporation."

Top  |   Parent  |   Reply  |   Original Post  |   RSS Feed  |   Subscribe to this Group
Author:
James Holmes
06/18/2005 10:34 AM

I'm not sure there's much more to it than what's in the docs: http://livedocs.macromedia.com/coldfusion/6.1/htmldocs/reuseco5.htm http://livedocs.macromedia.com/coldfusion/6.1/htmldocs/tags-pb4.htm > anyone know of any good tuts on using this? >  I can use it but just wanna know more :) > -- Geeque - accept the geek within and get your friends off your back - http://www.cafepress.com/geeque/

Top  |   Parent  |   Reply  |   Original Post  |   RSS Feed  |   Subscribe to this Group
Author:
Raymond Camden
06/18/2005 06:45 PM

Some gotchas you should be aware of: If you want "name" to be an attribute for your custom tag, you can't call it via cfmodule. What I typically do is use 2 attributes, name and well, something else, like thename or something. I then use "thename" when calling the custom tag w/ cfmodule. Inside the tag I simply copy the attribute value to name. If you use "wrapper" tags, ie, <cf_foo></cf_foo>, don't forget that when using cfmodule, you must properly close all tags. So consider this: <cfmodule template="layout.cfm">    <cfmodule template="foo.cfm"> </cfmodule> You may think the 3rd line closes the layout tag. Actually it closes the foo tag. To make it work right, you simply change the foo call to: <cfmodule template="foo.cfm" /> This will cause your tag to run twice. If you don't want that to happen, you can add this at the end of your custom tag: <cfexit method="exitTag"> In fact, I recommend you always do this so you don't forget. Enjoy. As a general, FYI, I typically always use cfmodule or cf_ so I don't have to worry about name collisions. ----- Excess quoted text cut - see Original Post for more -----

Top  |   Reply  |   Original Post  |   RSS Feed  |   Subscribe to this Group
Author:
dave
06/19/2005 02:03 AM

thanks Raymond, it was actually one of your apps I was looking at that was confusing me :) ~Dave the disruptor~ "A criminal is a person with predatory instincts who has not sufficient capital to form a corporation." Some gotchas you should be aware of: If you want "name" to be an attribute for your custom tag, you can't call it via cfmodule. What I typically do is use 2 attributes, name and well, something else, like thename or something. I then use "thename" when calling the custom tag w/ cfmodule. Inside the tag I simply copy the attribute value to name. If you use "wrapper" tags, ie, , don't forget that when using cfmodule, you must properly close all tags. So consider this: You may think the 3rd line closes the layout tag. Actually it closes the foo tag. To make it work right, you simply change the foo call to: This will cause your tag to run twice. If you don't want that to happen, you can add this at the end of your custom tag: In fact, I recommend you always do this so you don't forget. Enjoy. As a general, FYI, I typically always use cfmodule or cf_ so I don't have to worry about name collisions. ----- Excess quoted text cut - see Original Post for more -----

Top  |   Parent  |   Reply  |   Original Post  |   RSS Feed  |   Subscribe to this Group
Author:
Raymond Camden
06/19/2005 08:23 AM

Heh, well if you have any more questions, let ke know. Remember, none of my applications have bugs, and they work better than anyone elses. Now execue me while I dodge this lightning bolt... ----- Excess quoted text cut - see Original Post for more -----

Top  |   Parent  |   Reply  |   Original Post  |   RSS Feed  |   Subscribe to this Group
Author:
Tarantor
06/19/2005 08:50 AM

Ah Ray Ah! :) Heh, well if you have any more questions, let ke know. Remember, none of my applications have bugs, and they work better than anyone elses. Now execue me while I dodge this lightning bolt...


<< Previous Thread Today's Threads Next Thread >>

Search cf-talk

September 30, 2014

<<   <   Today   >   >>
Su Mo Tu We Th Fr Sa
   1 2 3 4 5 6
7 8 9 10 11 12 13
14 15 16 17 18 19 20
21 22 23 24 25 26 27
28 29 30         

Designer, Developer and mobile workflow conference