On Sun, Feb 27, 2005 at 08:25:29PM +0100, Filippo Rusconi wrote:
> Hello Justin,
> 
> nice to help.
> 
> > I believe that that's intentional.  The webcalendar files are in
> > /usr/share because they are sharable, and apache.conf (or its
> > counterpart) is updated with a web alias: /webcalendar =>
> > /usr/share/webcalendar.
> 
> But I cannot see any webcalendar item anywhere in the apache conf
> files.
You are using apache, no?

grep -r webcalendar /etc/apache*

> > Besides keeping them in share/, this allows an easy way to disable
> > web apps without removing them; just edit apache.conf.
> > 
> > > When I tried to load a /usr/share/webcalendar/index.php file in
> > > mozilla-firefox it asked me if I wanted to store it on disk, not
> > > recognizing that this was php script !
> > That's a php problem, though, not a webcalendar one.  If you haven't
> > already found the solution, check /etc/apache*/conf.d/*php*, and
> > possibly uncomment some lines to enable php preprocessing.  Maybe
> > dpkg-reconfigure php4 will do that for you, actually.
> 
> dpkg-reconfigure apache 
> 
> has let me the opportunity to ask that the mod_php4 module be loaded.
> 
> Then the httpd.conf file mentions this:
> 
>     # And for PHP 4.x, use:
>     #
>     AddType application/x-httpd-php .php
>     AddType application/x-httpd-php-source .phps
> 
> The /etc/apache/conf.d/php4.conf contains this :
> 
> <IfModule mod_php4.c>
>   AddType application/x-httpd-php .php .phtml .php3
>   AddType application/x-httpd-php-source .phps
> </IfModule>
> 
> But still I cannot mozilla-firefox-read the
> /usr/share/webcalendar/index.php file.
You don't want to read the file, you want to read the url.  Otherwise
it will not be preprocessed by PHP (since apache does that, and apache
isn't involved in local files).

> I tried copying that file to /var/www and then pointing
> mozilla-firefox to that directory and, again, it asked if I wanted to
> save that file. I said yes, pointed the file to some place in my home
> directory, and discovered that the file name was changed from
> index.php to g041ghz8.phtml. The file contents are identical in
> g041ghz8.phtml and in /usr/share/webcalendar/index.php.
> 
> This latter observation leads me to think that something dynamic was
> happening, otherwise why would the filename be changed ?
I donno.  The problem is that apache is not preprocessing .php files
with php.  Did you reload apache after loading the php module?
(/etc/init.d/apache reload).  You'll know this works when you can load
a trivial file /var/www/info.php:

<?
        phpinfo();
?>

> I do not know if you are a webcalendar staff member or php one, but
> anyway thank you for helping.
I'm neither, but I'm subscribed to the RC bug list.

Justin


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to