[mod_python] PSP include with absolute path causing blank page

Graham Dumpleton graham.dumpleton at gmail.com
Mon Jun 18 02:59:14 EDT 2007


Is there any chance you can upgrade to 3.3.1? There were some bugs fixed for
PSP in 3.3.

One was not dealing with last line of file not having a newline. Think it
only hit UNIX and not Windows. Can't remember what the output from that
problem was though and whether it showed as blank page.

Graham

PS, please use reply-all.

On 18/06/07, Erik Thompson <mrlobster99 at gmail.com> wrote:
>
> Presuming you are using straight PSP and not PSP from within
> > publisher, follow example on:
> >
> >   http://www.modpython.org/live/current/doc-html/hand-psp.html
> >
> > to enable .psp_ access for debug. This will show in browser the source
> > code when page accessed with .psp_ extension instead of .psp. Post to
> > the mailing list the snippet of source code being generated for the
> > section of PSP code giving the problem or look at it yourself and see
> > why it might not be working.
> >
> > Graham
>
>
>
> Thanks for the suggestion.  When I use the .psp_ extension to try and view
> the generated source on the problem page it also produces a blank page.  I
> guess it isn't a big deal as I have a work around.
> For the one that works using the work around the .psp_ extension produces:
> SP-produced Python Code: /var/www/html/test3.psp: 1. req.write("""""",0);
> <% 2. PSP(req, "/var/www/html/borders/test.psp").run(form) PSP(req, "/var/www/html/borders/test.psp").run(form)
> 3. req.write(""" %> 4.
>   5. """,0)
> The include file has:
> PSP-produced Python Code: /var/www/html/borders/test.psp: 1. req.write
> ("""<html> <html> 2. <head> <head> 3. <title>include test</title>
> <title>include test</title> 4. </head> </head> 5. <body> <body> 6.
> include text include text 7. """,0); <% 8. x = 0 x = 0 9. x += 1 x += 1
> 10. req.write("<br>hi there.<br>") req.write("<br>hi there.<br>") 11.
> req.write(""" %> 12. """,0); req.write(str( x ),0); req.write(""" <%= x %>
> 13. </body> </body> 14. </html>""",0) </html>
> The resulting expected html is:
>
> <html>
> <head>
> <title>include test</title>
> </
> head>
> <body>
> include text
> <br>hi there.<br>
> 1
> </body>
>
> </html>
>
>
>
>
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mm_cfg_has_not_been_edited_to_set_host_domains/pipermail/mod_python/attachments/20070618/babb1161/attachment-0001.html


More information about the Mod_python mailing list