Apache Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsSystem AdministrationApache Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old April 1st, 2002, 04:36 PM
elysium elysium is offline
Gentleman of leisure
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2002
Location: Sweden
Posts: 44 elysium User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 2 h 31 m
Reputation Power: 7
ForceType causes image-problems

I'm having some problems with the "ForceType" directive. When I use it, some of my .jpg-images gives some weird error-messages (surely because they're being parsed by PHP). When the ForceType is #:ed out the images work just fine.

I can't come up with a good solution to this problem, since I don't want to remove the ForceType. I was thinking of adding another directive to somehow remove the ForceType for the "/usr/local/www/somedir/img/"-dir since all the images are in there. A "UnForceType" directive should probably do the trick Any clues?


WHAT I'M USING:

<Directory "/usr/local/www/somedir/">
ForceType application/x-httpd-php
</Directory>


ERRORMESSAGE:

Warning: Unexpected character in input: '\\' (ASCII=92) state=1 in /usr/local/www/somedir/img/2002_12.jpg on line 43

Warning: Unexpected character in input: '' (ASCII=3) state=1 in /usr/local/www/somedir/2002_12.jpg on line 43

Parse error: parse error in /usr/local/www/somedir/2002_12.jpg on line 43






UPDATE:
The DefaultType seems to working in this particular case since the files I'm trying to force to be parsed by PHP is free of an extension. E.g. "http://domain.com/index/42" instead of "http://domain.com/index.php?somevar=somevalue". But it doesn't feel like the "right" way to go, since every file that doesn't have a respective, registerd mime-type gets parsed as php.

Last edited by elysium : April 1st, 2002 at 04:45 PM.

Reply With Quote
  #2  
Old April 1st, 2002, 10:14 PM
freebsd freebsd is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jan 2001
Posts: 5 freebsd User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
>> A "UnForceType" directive should probably do the trick Any clues?

There's RemoveType, so just start here -> http://httpd.apache.org/docs/mod/mod_mime.html

>> since I don't want to remove the ForceType

You also can use DirectoryMatch directive.

Reply With Quote
Reply

Viewing: Dev Shed ForumsSystem AdministrationApache Development > ForceType causes image-problems


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 5 hosted by Hostway
Stay green...Green IT