Switch off sidebar for a specific layout?

3 views
Skip to first unread message

majo

unread,
Jun 25, 2009, 6:27:22 AM6/25/09
to ColdBox Framework
Hello Coldbox Gurus,

is there a way to switch off the sidebar for a layout?
I need it for my Ajax-Html rendering - here is the sidebar code very
disruptive

Best thanks in advance

Sana

unread,
Jun 25, 2009, 6:35:00 AM6/25/09
to ColdBox Framework
Hi Majo,

At the moment, we cannot disable sidebar for a specific event or
layout.

But we do have plan to add this feature in very near future.

Thanks
Sana

Ernst van der Linden

unread,
Jun 25, 2009, 7:10:44 AM6/25/09
to col...@googlegroups.com
you can, isProxyRequest disables sideBar

Ryan

unread,
Jul 30, 2009, 2:48:19 PM7/30/09
to ColdBox Platform
Can we revisit this question? I have certain coldbox events I'm
loading into containers via AJAX and I created a stripped down layout
for those events...associated the events to the layout...and when I
execute my code, I'm getting more than one sidebar appearing on the
side.

Ernst - I don't follow your solution.

Maybe there's a better way to approach this situation...how does
everyone render coldbox events into containers via ajax? Can you opt
for no layout?

Ernst van der Linden

unread,
Jul 30, 2009, 3:14:35 PM7/30/09
to col...@googlegroups.com
I render a 'ajax' view in my handler like this:

<cffunction name="getMyView" access="public" returntype="string"
output="false">
<cfargument name="Event" type="coldbox.system.beans.requestContext">
<cfreturn renderView('myView')>
</cffunction>

Ernst

Ernst van der Linden

unread,
Jul 30, 2009, 3:18:11 PM7/30/09
to col...@googlegroups.com
So from your main page you call the coldboxproxy, which calls the
handler, which returns the view.

Luis Majano

unread,
Jul 30, 2009, 5:55:44 PM7/30/09
to col...@googlegroups.com
Or you can just use the event.renderData() method also.

Again, the problem is removing the sidebar.  We will investigate how to disable it on a per request basis.
--
Luis F. Majano
President
Ortus Solutions, Corp

ColdBox Platform: http://www.coldbox.org
Linked In: http://www.linkedin.com/pub/3/731/483
Blog: http://www.luismajano.com
IECFUG Manager: http://www.iecfug.com

Ryan

unread,
Jul 31, 2009, 2:36:37 PM7/31/09
to ColdBox Platform
See, I'm not just rendering views...I'm loading entire coldbox events
into certain containers.

...or are you saying for THAT event's handler, instead of setView
()...do a renderData()?

On Jul 30, 4:55 pm, Luis Majano <lmaj...@gmail.com> wrote:
> Or you can just use the event.renderData() method also.
>
> Again, the problem is removing the sidebar.  We will investigate how to
> disable it on a per request basis.
>
> On Thu, Jul 30, 2009 at 12:18 PM, Ernst van der Linden
> <evdlin...@gmail.com>wrote:
>
>
>
>
>
> > So from your main page you call the coldboxproxy, which calls the
> > handler, which returns the view.
>
> > On Thu, Jul 30, 2009 at 9:14 PM, Ernst van der
> > Linden<evdlin...@gmail.com> wrote:
> > > I  render a 'ajax' view in my handler like this:
>
> > >        <cffunction name="getMyView" access="public" returntype="string"
> > > output="false">
> > >                <cfargument name="Event"
> > type="coldbox.system.beans.requestContext">
> > >                <cfreturn renderView('myView')>
> > >        </cffunction>
>
> > > Ernst
>

Ryan

unread,
Jul 31, 2009, 2:39:33 PM7/31/09
to ColdBox Platform
I think I just answered my own question.

Shucks...I'm using the renderData() method in another area...why
didn't I put 2 and 2 together.

Oh well, now I know... That worked GREAT!

Doug Boude

unread,
Jul 31, 2009, 2:48:30 PM7/31/09
to col...@googlegroups.com
Ryan, if this helps give food for thought, here's a snippet out of one of my handlers where I'm using renderData to return a rendered view via an ajax call that does what your ajax call does. I'm not sure if that will solve your issue or not, but it's probably something fairly simple to try:

<cfset arguments.event.renderData(type="plain",data=getPlugin('renderer').renderView('authentication/login')) />

Doug B

Ryan

unread,
Jul 31, 2009, 2:57:36 PM7/31/09
to ColdBox Platform
Doug,

Yup! I actually pulled that renderData() method out of one of your
blogs a few weeks ago. Like I said before, I was using this in
another area, and I didn't put 2 and 2 together in this specific
situation...once I did...viola...one sidebar! :)

BTW...I double checked the sidebar interceptor and don't see any way
to position it "easily" without some reskinning/recssing it. Maybe
I'm wrong?

On Jul 31, 1:48 pm, Doug Boude <dougbo...@gmail.com> wrote:
> Ryan, if this helps give food for thought, here's a snippet out of one of my
> handlers where I'm using renderData to return a rendered view via an ajax
> call that does what your ajax call does. I'm not sure if that will solve
> your issue or not, but it's probably something fairly simple to try:
> <cfset
> arguments.event.renderData(type="plain",data=getPlugin('renderer').renderView('authentication/login'))
> />
>
> Doug B
>

Ernst van der Linden

unread,
Jul 31, 2009, 4:47:30 PM7/31/09
to col...@googlegroups.com
Ryan,

You can set the yOffset if that's what you mean.

Check the docs for more settings
http://ortus.svnrepository.com/coldbox/trac.cgi/wiki/cbSideBar


Ernst
Reply all
Reply to author
Forward
0 new messages