If you want to create a FarCry page that calls your include, then you simply go to the Admin tool, locate the point in your navigation tree where you want that page to appear, create the page as a dmInclude, select your include file, approve the page.  That should be it.
 
BUT - you MUST make sure your output code in your include has <cfoutput> around it as the templates all set CFOUTPUTONLY to TRUE.
 
 
The important thing to remember with FarCry includes is that they are NOT the same as how you would use <cfinclude> (but that is how they are wrapped in the template).
 
The concept of a FarCry include is about giving you a way to include your own code (which may or may not use any of the FarCry APIs) into the page body to generate the content (instead of something like a dmHTML object - which generates it's content from what is stored in the associated FarCry record).
 
The next most important thing to remember with FarCry is that includes are not about re-use (as you would be used to doing in CF).
 
Re-use in FarCry is done in any (or any combination) of the following ways:
  • Extending one of the existing FarCry types
  • Extending the core base type (the one that the FarCry provided types are built from)
  • Building rules that go into FarCry containers
  • Creating your own custom objects (which again may or may not use the FarCry APIs) and creating them on any number of FarCry include pages or in FarCry rules
If what you are trying to do is have a small piece of your legacy (or non-FarCry-based) code display in a portion of your page, you want to create a container first, then you can use the hand-picked rule to locate your actual include page (it has to be in the navigation tree somewhere - even if hidden in the Utility section), and then have a display method for your include which does NOT decoarate the include with any of your template information ( i.e. like dmHeader, dmFooter - you just want it raw - we call ours, displayRaw).
 
The other option (which is more FarCry-like) - instead of just using the "include" with a "raw" display method would be to create your own "rule" that you can place into any container on any page.  But you would still have to somehow get your own code into that rule (so it's extra work).  If I were to go down this path I would still create some custom objects to talk to my old code - or refactor my code to be object based.
 
If all this is sounding like too much jargon, you still have some working through of some of the FarCry tutorials to do.
 
However, I believe that the resource site for these tutorials had some sort of disaster and were lost?  But I believe someone on this list had salvaged most of them.
 
Regards,
Gary
 
 
 
On 8/6/05, Adam Parker <[EMAIL PROTECTED]> wrote:
Hello,
I am new to farcry, and am trying to figure out how to use the includes to
help reduce redundancy as well as use custom cold fusion apps that I've
created, yet still integrate them with farcry.

I have already edited the dmHeader and dmFooter, so that is working fine.
How do I include a Cold Fusion page that I create and put in the
"includeObj" folder? How do I place that .cfm file into a page so that I can
take advantage of the Header/Footer? This is the homepage, so I can't link
to it either, it has to come up by default.

Thanks,
Adam Parker
FSU College of Information


---
You are currently subscribed to farcry-dev as: [EMAIL PROTECTED]
To unsubscribe send a blank email to [EMAIL PROTECTED]
Aussie Macromedia Developers: http://lists.daemon.com.au/

--- You are currently subscribed to farcry-dev as: [email protected] To unsubscribe send a blank email to [EMAIL PROTECTED] Aussie Macromedia Developers: http://lists.daemon.com.au/

Reply via email to