The 5.0 and the latest 4.x release allow webskins to be added to abstract types (like "types") which are then inherited by any type that extends them. This means that a displayHeaderStandard can be created for every type in an application by adding it to the /webskin/types/ directory, and accessed by any type the same way as a normal webskin.
But if a specific type has it's own displayHeaderStandard the webskin framework would use that instead automatically. Generally you would access it with: <skin:view stObject="#stObj#" webskin="displayHeaderStandard" /> FarCry will take care of any inheritance issues. Blair On 6/25/08, Michael Sharman <[EMAIL PROTECTED]> wrote: > > Thanks Blair, sounds like good stuff! > > I notice that the display template is stored in webskin/types/ > displayHeaderStandard.cfm > > Does that mean it's "linked" to the #typename# of my view (e.g. > dmHTML)? And does that also mean that if I had a custom content object > like "Product" I could display a different header for those pages? How > would I do that? > >>If you want to pass parameters into the header remember that the view tag >> has a new feature in FC5 where any attribute not used by the tag gets >> passed to the webskin in the stParams struct. > > Thanks Blair, makes sense and saves another question later on :) > > Michael > > > On Jun 25, 4:12 pm, [EMAIL PROTECTED] wrote: >> A few reasons, but mainly because we wanted the header / footer to be >> inheritable and overridable. Having header and footer as webskins >> means that they can be put in a plugin and can be overriden in the >> project, by subsequent plugins, and for specific types. All without >> changing the displayPage webskins. This isn't possible with cfinclude. >> >> Its a necessary change to support things like multi-subsite setups and >> webskin plugins. >> >> If you want to pass parameters into the header remember that the view >> tag has a new feature in FC5 where any attribute not used by the tag >> gets passed to the webskin in the stParams struct. >> >> Blair >> >> On 6/25/08, Michael Sharman <[EMAIL PROTECTED]> wrote: >> >> >> >> > Hi guys, >> >> > Just looking at the FarCry 5 codebase and have noticed that the header >> > and footer are being loaded with a "view" custom tag as follows: >> >> > <skin:view objectid="#stobj.objectid#" typename="#stobj.typename#" >> > template="displayHeaderStandard" /> >> >> > Previously this would have either been a cfinclude or cfmodule. >> >> > The description in view.cfm is: >> >> > "This tag will run the view on an object with the same objectid until >> > it is saved to the database." >> >> > I'm a little confused by that description! >> >> > Can somebody give me a quick rundown of why you'd use skin:view, and >> > in particular why you'd use it for something like a header and footer? >> >> > Thanks > > > --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
