phpgroupware-developers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

SV: [Phpgroupware-developers] Re: filemanager/vfs related stuff + an XS


From: Sigurd Nes
Subject: SV: [Phpgroupware-developers] Re: filemanager/vfs related stuff + an XSLT question
Date: Fri, 7 Mar 2003 10:03:19 +0100

> 
> Jonathon Sim wrote:
> > Stupid KMail - looks like ctrl-enter is a shortcut to "send mail"
(and
> its all
> > a small translation from  "shift-;")
> >
> > Anyway:
> >
> > ...
> >
> > How do I disable the headers and footers and navbar with XSLT?
pre-XSLT
> the
> > filemanager did this:
> >
> >     $GLOBALS['phpgw_info']['flags']['noheader'] = True;
> >     $GLOBALS['phpgw_info']['flags']['nonavbar'] = True;
> >     $GLOBALS['phpgw_info']['flags']['noappheader'] = True;
> >     $GLOBALS['phpgw_info']['flags']['noappfooter'] = True;
> >
> > Then when it wanted to output html it did this:
> >     unset($GLOBALS['phpgw_info']['flags']['noheader']);
> >     unset($GLOBALS['phpgw_info']['flags']['nonavbar']);
> >     unset($GLOBALS['phpgw_info']['flags']['noappheader']);
> >     unset($GLOBALS['phpgw_info']['flags']['noappfooter']);
> >
> > But it could still spit out raw binary data (just by echoing it)
when
> the user
> > tried to "view".
> >
> > So how can I disable the XSLT templates so that I can do this : ie
> output
> > binary data? The XSLT template system doesn't have much
documentation,
> not
> > that I'm volunteering to write any :)
> 
> Uups, seems we forgot it!
> 
> You can archive the same effect at the moment only by:
> define('PHPGW_FOOTER_RAN',True);
> That will stop all output. If you want to output something (eg. echo
the
> content of the file) you have to first call
> $GLOBALS['phpgw']->common->stop_xslt_capture() or ob_end_clean()
> 
> Ralf
> 

To disable navbar and footer with xslt:

I use this method for lookup-windows to addressbook, tenants, and
locations in my app 'property'.

Place the xsl-template (attachment) in your /templates/default/

Include the template among your other templates:
$GLOBALS['phpgw']->xslttpl->add_file(array('headonly','lookup'....

to see it in action:
Install the app 'property'

go to: property->helpdesk->add->property

in /property/inc/class.uilookup.inc.php

find 'headonly' in function location (line 378) and comment it out - see
what happens with the lookup-window when you reload.

Sigurd

Attachment: headonly.xsl
Description: Text Data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]