Hi Jeffry,

 

The structure is a follow:

E:/

            _website_development/

                        baseComponent.cfc

                        /OtherComponents/

                                    component1.cfc

                                    component2.cfc

            _website_demo/

                        baseComponent.cfc

                        /OtherComponents/

                                    component1.cfc

                                    component2.cfc

 

            Websites/

                        Website1/

                                    Some cfc’s extending baseComponents above

                        Website2/        

                                    Some cfc’s extending baseComponents above

                        Website2_demo/           

                                    Some cfc’s extending baseComponents above

 

When I finished a component in E:/_website_development/OtherComponents/ I copy it to E:/_website_demo/OtherComponents/ for testing (for clients).

 

So I need to redirect the websites under E:/Websites/ to the right components (and maps). But it seems that Cold Fusion doesn’t allow you to use variables in the extends attribute. (and it’s like cfinclude, and there it will work…).

 

My (stupid) solution is to enforce other webdevelopers to change manually the extends attribute. But I hope that is not the best solution that’s out there…

 

-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Jeffry Houser
Sent: vrijdag 21 mei 2004 16:10
To: [EMAIL PROTECTED]
Subject: Re: [CFCDev] Constant values in attribute extends

 


 I think you mean <cfcomponent extends=""> not cfmodule. 

 If your components are in the same directory, they can be referred to as a package.  The "package" directory is the first place the extends component is looked for (someone correct me if this is wrong).  In this case, do you need to specify a full directory or are your components located in the same directory?  Would this: <cfcomponent extends="BaseComponent">  work? 

At 10:00 AM 5/21/2004, you wrote:

Hello,
 
I’m developing on a website and I wanted to split up the development code and stable and tested code (for demo).
 
So I made two mappings: website_development and website_demo in ColdFusion administrator.
 
In application.cfm, I created an application.map variable with one of the two above mentioned mappingnames.
 
I adapted the code of my cfc’s from <CFMODULE extends = “website_development.baseComponent”> to <CFMODULE extends = “#application.map#.baseComponent”>
 
But, when I run the program, I get this error “This _expression_ must have a constant value.” And that is a major setback for me…
L
 
Does someone know a work around for this?
 
Met vriendelijke groeten,
Jurgen Stillaert
 
------------------------------------------------------------------------------------
Jurgen Stillaert
Webdeveloper
 
RAMIT vzw
c/o Dept. Medical Informatics & Statistics
University Hospital Ghent (5K3)
De Pintelaan 185
9000 Ghent
Belgium
 
Phone: +32 9 240 52 93
Fax: +32 9 240 34 39
E-mail: [EMAIL PROTECTED]
 
 

--
Jeffry Houser, Web Developer, Writer, Songwriter, Recording Engineer
<mailto:[EMAIL PROTECTED]>
--
AIM: Reboog711  | Phone: 1-203-379-0773
--
My Books: <http://www.instantcoldfusion.com>
Recording Music: <http://www.fcfstudios.com>
Original Energetic Acoustic Rock: <http://www.farcryfly.com>

Reply via email to