2) If you want to allow the user to select a navigation item like from a drop down list, you could use code like what is used in the quick site builder to select the starting point:
<cfscript>
<select name="startPoint" id="startPoint">
3) You can also use the object picker in the widgets tag library which opens a popup that lists all of a given type (though it won't show the tree structure and the gui is a little bit buggy):
o = createObject("component", "#application.packagepath#.farcry.tree");
qNodes = o.getDescendants (dsn=application.dsn, objectid=application.navid.root);
</cfscript>qNodes = o.getDescendants (dsn=application.dsn, objectid=application.navid.root);
<select name="startPoint" id="startPoint">
<option value="#application.navid.root#">#application.adminBundle[session.dmProfile.locale].Root#</option>
<cfloop query="qNodes">
</select><cfloop query="qNodes">
<option value="#qNodes.objectId#" <cfif
qNodes.objectId eq application.navid.home>selected</cfif>>#RepeatString(" |", qNodes.nlevel)#- #qNodes.objectName#</option>
</cfloop><cfimport taglib="/farcry/farcry_core/tags/widgets" prefix="widgets">
<widgets:objectPicker typename="dmNavigation" fieldname="link" fieldlabel=" #application.adminBundle[session.dmProfile.locale].linkLabel#" fieldvalue="#output.link#">
<widgets:objectPicker typename="dmNavigation" fieldname="link" fieldlabel=" #application.adminBundle[session.dmProfile.locale].linkLabel#" fieldvalue="#output.link#">
Blair
On 5/3/06, M Wheeler
<[EMAIL PROTECTED]> wrote:
Sorry,custom admin code, and I am trying to link back to a navigation item in my main site from a news item. using the site navigation to populate the text box, drag and drop. :)CheersMark
On 5/3/06, Blair McKenzie <[EMAIL PROTECTED]> wrote:That's not very clear. Are you talking about the website or custom admin code? And what exactly are you trying to link to?
Blair
On 5/3/06, M Wheeler <[EMAIL PROTECTED]> wrote:HiUsing Farcry 3 and have a news item that needs to have a load site tree button for linking back to main site navigation if required. Curently just have a standard form output for manual input of link<label for="">#application.adminBundle[session.dmProfile.locale].linkLabel#</b>
<input type="text" name="link" id="link" value="#output.link#" maxlength="255" /><br />
</label>Link would look likeindex.cfm?objectId=4C8B36A5-40CA-68F8-EC192A9CC08DC977but load site tree would be more convenient for user, is there a widget for this functionality?ThxMark
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---
