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

Re: [cgiapp] Generating a 'pop-up' from cgi-a


Thanks Cees,

Turns out what I really needed was the -target header to specify '_blank'. Some days HTML just seems to elude me! But I appreciate your remark about CSS, of course I am aware of the multiple media facility in CSS, but I didn't think of it in this connection. Maybe I should either go back to working in a real GUI or spend some time learning HTML and CSS properly.

John

At 05:04 PM 6/7/2004, Cees Hek wrote:
>Quoting John Day <suppressed>:
>
>> At 04:19 PM 6/7/2004, John Day wrote:
>> >I have an application where I want to generate a 'printable invoice' in a
>> separate window. Preferably I would like the browser page to not have
>> toolbars and all that, just a simple link at the bottom that has an 
>> 'onClick' event calling the window.print() method in it. How do I set up the
>> headers to force the output to a new window and how do I turn off all the
>> unnecessary 'stuff' on the browser window?
>> 
>> Did I really say that? My brain is scrambled today. No, I want them to print
>> it by hitting ctrl-P! I can't use the onClick without JS can i!
>
>It did sound rather confusing :)  
>
>However, even with the clarification, your question really has nothing to do
>with CGI::Application, which makes me believe that you mistook this list for a
>general CGI mailing list.
>
>That having been said, the easiest way to do this is to use stylesheets.  You
>can provide a stylesheet with the media attribute set to 'print'.
>
><link rel="stylesheet" href="/style/normal.css" type="text/css" media="all"/>
><link rel="stylesheet" href="/style/print.css" type="text/css" media="print"/>
>
>Then your stylesheet can define what should be visible, or invisible.  WHen the
>user does a print preview, or just a Ctrl-P the result will be rendered using
>the 'print' stylesheet instead of the 'normal' one.
>
>Hope that helps...
>
>Cees
>
>---------------------------------------------------------------------
>Web Archive:  http://www.mail-archive.com/suppressed/
>              http://marc.theaimsgroup.com/?l=cgiapp&r=1&w=2
>To unsubscribe, e-mail: suppressed
>For additional commands, e-mail: suppressed



---------------------------------------------------------------------
Web Archive:  http://www.mail-archive.com/suppressed/
              http://marc.theaimsgroup.com/?l=cgiapp&r=1&w=2
To unsubscribe, e-mail: suppressed
For additional commands, e-mail: suppressed


Mail converted by mhonarc 2.6.15
This archive provided courtesy of JSW4.NET, Internet Hosting Services for Small Business.