PSP problem showing images

  • Thread starter Alfons Nonell-Canals
  • Start date
A

Alfons Nonell-Canals

Hello,
I have experience working with Python an dnow I would like to use it for
web development. I worked with php from several years ago and I'm trying
to move to PSP. I have no problem runing some tests, implement an small
project with psp is pretty easy. But I have only one problem, me scrips
don't show any image.

I developed a script which generates some images (is a work about
Chemistry) and returns a page with some results and these images. When I
run the script from the web browser, "all" works fine: the images are
created, some other staff is calculated and the final page with the
results is fine except the images. It does not print the images! I chech
the paths and all is fine.

With it I thought tha maybe there is something wrong in the apache's
configuration. And I'm almost sure the problem is there because the
Handler used only manages .psp documents. I add some code to not apply
the Handler to .png but... help?

Do you have any idea/experience?

Below is the configuration of the host...

<VirtualHost *:80>
ServerAdmin (e-mail address removed)
ServerName www.domain.com
ServerAlias domain.com

# Indexes + Directory Root.
DirectoryIndex index.psp
DocumentRoot /path/to/the/pages
<Directory /path/to/the/pages >
AddHandler mod_python .psp
PythonHandler mod_python.psp
PythonDebug On
<FilesMatch "\.(jpg|gif|png)$">
Sethandler None
</FilesMatch>
</Directory>



# Logfiles
ErrorLog /var/log/apache2/domain.com-error.log
CustomLog /var/log/apache2/domain.com-access.log combined
</VirtualHost>


Thanks in advance!

Regards,
Alfons.


--
------------
Alfons Nonell-Canals, PhD
Chemogenomics Lab
Research Group on Biomedical Informatics (GRIB) - IMIM/UPF
Barcelona Biomedical Research Park (PRBB)
C/ Doctor Aiguader, 88 - 08003 Barcelona
(e-mail address removed) - http://cgl.imim.es
Tel. +34933160528

http://alfons.elmeuportal.cat
http://www.selenocisteina.info
 
L

Lawrence D'Oliveiro

Alfons said:
I developed a script which generates some images (is a work about
Chemistry) and returns a page with some results and these images. When I
run the script from the web browser, "all" works fine: the images are
created, some other staff is calculated and the final page with the
results is fine except the images. It does not print the images! I chech
the paths and all is fine.

Did you view source to check the URLs in the “<IMG SRC="...">†directives?
Did you try copying and pasting the image URLs directly into new
windows/tabs, to see if they came up or you got an error page instead?
 
A

Alfons Nonell-Canals

Hi Lawrence,
Yes, I've tried it! I've saw the code, copyed the src path ans pasted
into the browser and it works. I think it not works only unther a psp
hostname/directory, for this reason I thought the problem is in the
apache2 (site) configuration pasted in my mail...

Thanks!
Alfons.


In message <[email protected]>, Alfons
Nonell-Canals wrote:



Did you view source to check the URLs in the “<IMG SRC="...">†directives?
Did you try copying and pasting the image URLs directly into new
windows/tabs, to see if they came up or you got an error page instead?

--
------------
Alfons Nonell-Canals, PhD
Chemogenomics Lab
Research Group on Biomedical Informatics (GRIB) - IMIM/UPF
Barcelona Biomedical Research Park (PRBB)
C/ Doctor Aiguader, 88 - 08003 Barcelona
(e-mail address removed) - http://cgl.imim.es
Tel. +34933160528

http://alfons.elmeuportal.cat
http://www.selenocisteina.info
 
A

Alfons Nonell-Canals

Anybody of you have any idea?
Hi Lawrence,
Yes, I've tried it! I've saw the code, copyed the src path ans pasted
into the browser and it works. I think it not works only unther a psp
hostname/directory, for this reason I thought the problem is in the
apache2 (site) configuration pasted in my mail...

Thanks!
Alfons.

--
------------
Alfons Nonell-Canals, PhD
Chemogenomics Lab
Research Group on Biomedical Informatics (GRIB) - IMIM/UPF
Barcelona Biomedical Research Park (PRBB)
C/ Doctor Aiguader, 88 - 08003 Barcelona
(e-mail address removed) - http://cgl.imim.es
Tel. +34933160528

http://alfons.elmeuportal.cat
http://www.selenocisteina.info
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,995
Messages
2,570,230
Members
46,818
Latest member
Brigette36

Latest Threads

Top