Thanks Paul, sounds hacky, but will do what I need it to I suspect. Cheers, -Dan
On 20 June 2011 11:22, Paul Bennett <[email protected]> wrote: > Hi Dan, > Hmm - one way - include the custom HTML field content on specific pages. > <% if URLSegment = 'page-one' %> > $siteConfig.MyHTMLField > <% end_if %> > <% if URLSegment = 'page-two' %> > $siteConfig.MyHTMLField > <% end_if %> > > The templating conditionals in SS aren't as helpful as they could be but > this appears to be a design decision in order to push business logic into > the controller > The other way is to create a method in your controller which outputs data > based on your conditions and then simply call the output method in your > template. > eg > // controller > function myMethod() { > if (... conditions ...) { > return SiteConfig.MyHTMLField; > } > } > // template > $myMethod > > Regards, > Paul Bennett > MoveForward - Web Development for Design Companies > http://www.moveforward.co.nz > 06 308 9722 > 027 255 8495 > > -- > NZ PHP Users Group: http://groups.google.com/group/nzphpug > To post, send email to [email protected] > To unsubscribe, send email to > [email protected] -- NZ PHP Users Group: http://groups.google.com/group/nzphpug To post, send email to [email protected] To unsubscribe, send email to [email protected]
