My new install of 1.4.3 has very little in htdocs, such that the pages are
almost plain text instead of being nicely formatted.
As a test, I replaced the htdocs with the directory from my previous 1.0.3
instance, and all the nice formatting came back. The old directory doesn't
have the subdirs common or ticketopt. The README file states that these are
files used by the genshi templates.
I'm aware 1.4.3 uses Jinja2 instead of Genshi, but what could I have
missed? The htdocs created by trac-admin/deploy doesn't seem to have what
it needs.
Here are the things that I installed:
$ pip install -U Jinja2
$ pip install -U genshi
$ pip install -U babel
$ pip install Trac
$ pip install -U docutils pygments textile
Yikes! I didn't realize until just now that I also installed Genshi. I'm
not sure I intended to do that! A closer look finds the genshi files in
htdocs/common. If I move them up a level from that "common" subdir, then
the nice formatting comes back.
Is the .htaccess file (copied from trac 1.0.3) wrong? I'm currently testing
using tracd. I don't think my ISP will fix any apace settings if that's
what I need to go back to apache. I can get by with tracd if need be; I ran
that way for 2 years a few years ago.
$ cat $TRAC_ENV/.htaccess
#<Files *.cgi>
# SetHandler fastcgi-script
#</Files>
DirectoryIndex index.fcgi
# Make sure rewrites work
Options ExecCGI FollowSymLinks
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{DOCUMENT_ROOT}%{REQUEST_FILENAME} !-d
RewriteCond %{DOCUMENT_ROOT}%{REQUEST_FILENAME} !-f
RewriteCond $1 !^index.fcgi/(.*)
# Keep the graphics and style sheet the way they are
RewriteCond $1 !^htdocs(.*).css$
RewriteCond $1 !^htdocs(.*).js$
RewriteCond $1 !^htdocs(.*).gif$
RewriteCond $1 !^htdocs(.*).jpg$
RewriteCond $1 !^htdocs(.*).png$
RewriteRule ^(.*)$ index.fcgi/$1 [L]
RewriteCond %{DOCUMENT_ROOT}%{REQUEST_FILENAME} !-d
RewriteCond %{DOCUMENT_ROOT}%{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_URI} attachment
RewriteCond $1 !^index.fcgi/(.*)
RewriteRule ^(.*)$ index.fcgi/$1 [L]
</IfModule>
I'm sure I screwed this up. I don't mind starting over again. Can anybody
shed some light on this?
--
You received this message because you are subscribed to the Google Groups "Trac Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to trac-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/trac-users/792db24a-d7cf-454a-964a-9344fa739191n%40googlegroups.com.
almost plain text instead of being nicely formatted.
As a test, I replaced the htdocs with the directory from my previous 1.0.3
instance, and all the nice formatting came back. The old directory doesn't
have the subdirs common or ticketopt. The README file states that these are
files used by the genshi templates.
I'm aware 1.4.3 uses Jinja2 instead of Genshi, but what could I have
missed? The htdocs created by trac-admin/deploy doesn't seem to have what
it needs.
Here are the things that I installed:
$ pip install -U Jinja2
$ pip install -U genshi
$ pip install -U babel
$ pip install Trac
$ pip install -U docutils pygments textile
Yikes! I didn't realize until just now that I also installed Genshi. I'm
not sure I intended to do that! A closer look finds the genshi files in
htdocs/common. If I move them up a level from that "common" subdir, then
the nice formatting comes back.
Is the .htaccess file (copied from trac 1.0.3) wrong? I'm currently testing
using tracd. I don't think my ISP will fix any apace settings if that's
what I need to go back to apache. I can get by with tracd if need be; I ran
that way for 2 years a few years ago.
$ cat $TRAC_ENV/.htaccess
#<Files *.cgi>
# SetHandler fastcgi-script
#</Files>
DirectoryIndex index.fcgi
# Make sure rewrites work
Options ExecCGI FollowSymLinks
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{DOCUMENT_ROOT}%{REQUEST_FILENAME} !-d
RewriteCond %{DOCUMENT_ROOT}%{REQUEST_FILENAME} !-f
RewriteCond $1 !^index.fcgi/(.*)
# Keep the graphics and style sheet the way they are
RewriteCond $1 !^htdocs(.*).css$
RewriteCond $1 !^htdocs(.*).js$
RewriteCond $1 !^htdocs(.*).gif$
RewriteCond $1 !^htdocs(.*).jpg$
RewriteCond $1 !^htdocs(.*).png$
RewriteRule ^(.*)$ index.fcgi/$1 [L]
RewriteCond %{DOCUMENT_ROOT}%{REQUEST_FILENAME} !-d
RewriteCond %{DOCUMENT_ROOT}%{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_URI} attachment
RewriteCond $1 !^index.fcgi/(.*)
RewriteRule ^(.*)$ index.fcgi/$1 [L]
</IfModule>
I'm sure I screwed this up. I don't mind starting over again. Can anybody
shed some light on this?
--
You received this message because you are subscribed to the Google Groups "Trac Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to trac-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/trac-users/792db24a-d7cf-454a-964a-9344fa739191n%40googlegroups.com.