space Baylys
Just practicing to pass the Turing test.
space
space
space
space
Developer for Hire!
space
addedValues Plugin
space

Home

What's new

Bayly.Root

Cornershop Plugin

Career

edutools Root

Enhancements

Interests

linguist Plugin

Manila

Patches

space

mainresponder

space
space

adminSite

calendar

controlpanel

discuss

getFileMimeType

members

parseMultipart

respond

subscriptions

space

manilaData

manilamacros

manilaSuite

system

Patches by Group

Papers

Sales

Sign My Guestbook

User(land) Relations.

Contact Address

Search Baylys

urlchains

space
Join Now
Login
space space space

mainresponder.getFileMimeType

Files of type 'TEXT' are given the wrong mimetype by mainresponder when served as files.

on getFileMimeType (f) //get the MIME type of a file (not a folder)
  «Get the MIME type of a file.
 unaltered lines omitted
  «local (adrCache = @system.temp.mainResponder.mimeTypeCache)
 
  «if not defined (adrCache^) //PBS 12/07/01: don't do caching
 unaltered lines omitted
  «else
 unaltered lines omitted
 
  local (mimeType = "text/html")
  local (objectType = file.type (f))
 
  if system.environment.isWindows
 unaltered lines omitted
 
  if system.environment.isMac
 unaltered lines omitted
 
  «adrCache^.[f] = mimeType //cache the mime type //PBS 12/07/01: don't do caching
 
  return (mimeType)

Relative to Frontier version 9.7b10