Tags:
create new tag
, view all tags

Question

  • I have attached a html page to a topic (*.html).
  • I expect that the attachment is opened in the browser when I click the created link but only the html code of the attachment is shown.
  • If I directly click the attachment link at the bottom of the topic it is opened correctly.
  • I have looked to the configure script. The filter for html and htm is set but despite of this the files are not renamed to *.html.txt. I have looked in the folder.
  • I have tried a much simpler html file and it works fine within Internet Explorer but not in Firefox.
  • %INCLUDE% works fine but that is not what I really want because I only want a link to the attached html file.
  • Do you know what I can do in order to open a html page correctly when I just click the link and not the attachment itself?

Environment

TWiki version: TWikiRelease04x01x02
TWiki plugins: DefaultPlugin, EmptyPlugin, InterwikiPlugin
Server OS: RedHat
Web server: Apache
Perl version: 5.8
Client OS: MS Windows XP service pack 2
Web Browser: Internet Explorer 6, Firefox
Categories: Missing functionality

-- KirstinWeber - 29 May 2007

Answer

ALERT! If you answer a question - or have a question you asked answered by someone - please remember to edit the page and set the status to answered. The status is in a drop-down list below the edit box.

The links in the attachment table go through the viewfile script - this is probably messing up the file type. We recently have changed these links to 'plain' pub urls - that is scheduled for TWiki 4.2.

In the meantime, are you able to edit the file templates/attachtable.pattern.tmpl? In that file, change %A_URL% to <a href="%PUBURL%/%WEB%/%TOPIC%/%A_FILE%">%A_FILE%</a>.

-- ArthurClemens - 29 May 2007

Check also the {MimeTypesFileName} in configure, it should point to a valid and readable mime types files.

-- PeterThoeny - 29 May 2007

What is the result of %A_FILE%? At the moment, one link shows the pure code the other the correct page. Will I get the code or the correct page?

-- KirstinWeber - 31 May 2007

Sorry, I wanted to write <a href="%PUBURL%/%WEB%/%TOPIC%/%A_FILE%">%A_FILE%</a>

-- KirstinWeber - 31 May 2007

 
Change status to:
Topic revision: r4 - 2007-05-31 - KirstinWeber
 
Twitter Delicious Facebook Digg Google Bookmarks E-mail LinkedIn Reddit StumbleUpon    
  • Download TWiki
TWiki logo Powered by Perl Hosted by OICcam.com Ideas, requests, problems regarding TWiki? Send feedback. Ask community in the support forum.
Copyright © 1999-2012 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.