Solved

How to get around restrictions on cfinclude not passing parameters?

Posted on 2006-11-06
3
722 Views
Last Modified: 2013-12-24
I am trying to automate the printing of several pages. Part of what I want to do is this:

<body>
<cfinclude template="/recipes/recipe_show.cfm?recID=5">
<p class="break"><br></p>
...
</body>

My problem is that the cfinclude, apparently, does not take parameters ... so how do I get the recipe ID to the recipe_show page?
0
Comment
Question by:alicia1234
  • 2
3 Comments
 
LVL 7

Accepted Solution

by:
aseusainc earned 250 total points
ID: 17886464
This should work:

<body>
<cfset recID=5>
<cfinclude template="/recipes/recipe_show.cfm">
<p class="break"><br></p>
...
</body>
0
 
LVL 7

Expert Comment

by:aseusainc
ID: 17886470
Just a pointer...Think of an include as if you cut and pasted the templates code directly into your main page instead of including it, not as some sort of external app.
0
 

Author Comment

by:alicia1234
ID: 17889832
Just a note ... I had to do this:

<cfset URL.recID = 5>
0

Featured Post

Migrating Your Company's PCs

To keep pace with competitors, businesses must keep employees productive, and that means providing them with the latest technology. This document provides the tips and tricks you need to help you migrate an outdated PC fleet to new desktops, laptops, and tablets.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

One of the typical problems I have experienced is when you have to move a web server from one hosting site to another. You normally prepare all on the new host, transfer the site, change DNS and cross your fingers hoping all will be ok on new server…
Introduction This article explores the design of a cache system that can improve the performance of a web site or web application.  The assumption is that the web site has many more “read” operations than “write” operations (this is commonly the ca…
Two types of users will appreciate AOMEI Backupper Pro: 1 - Those with PCIe drives (and haven't found cloning software that works on them). 2 - Those who want a fast clone of their boot drive (no re-boots needed) and it can clone your drive wh…
Established in 1997, Technology Architects has become one of the most reputable technology solutions companies in the country. TA have been providing businesses with cost effective state-of-the-art solutions and unparalleled service that is designed…

809 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question