Hi Julian,

If you are on FarCry 4 FormTools [1] will make this a breeze!

You could use a list FormTool [2] and supply the ftListData argument.
Assuming dmHTML is the type you want to extend, ftListData will be the
name of a function in your project's dmHTML.cfc
(<project>/packages/types/dmHTML.cfc - you will need to create this
file). Your project's (new) dmHTML.cfc might look like this:

<cfcomponent extends="farcry.core.packages.types.dmHTML">

        <cfproperty ftSeq="50" ftFieldSet="Page Zone" name="pageZone"
type="string" hint="????" ftLabel="This page's zone " ftType="list"
ftRenderType="dropdown" ftListData="getPageZones" />

        <!--- see [2] but the list formtool expects a formatted list or
a query with two items: value and name  --->
        <cffunction name="getPageZones" displayname="gets a list of page
zones">
                
                <cfset var qPageZones = QueryNew("value,name") />
                
                <!--- Here you would add your own SQL to get the list of
zones from your other application --->
                <cfquery datasource="????" name="qPageZones ">
                        SELECT pageZoneId as [value]
                                , pageZoneName as [name]
                        FROM tblPageZones
                        ORDER BY pageZoneName 
                </cfquery>
                
                <cfreturn qPageZones />
                
        </cffunction>

</cfcomponent>

[1] http://docs.farcrycms.org/display/FCDEV40/Formtools+Technology
[2] http://docs.farcrycms.org/display/FCDEV40/list

Cheers

David

-----Original Message-----
From: [email protected] [mailto:[EMAIL PROTECTED]
On Behalf Of Julian Warren
Sent: Tuesday, 8 April 2008 11:53 PM
To: [email protected]
Subject: [farcry-dev] Add a property to html pages


Sirs,

I need to add an extra property (populated from a select box derived
from a query on my trusted CF Banner system which I also want to
integrate.) This property is simply the page "Zone"

How do I do this and how do I pull it out again when a page is being
displayed?

Cheers

Julian





--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"farcry-dev" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/farcry-dev?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to