homepage Welcome to WebmasterWorld Guest from 54.196.136.119
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member

Home / Forums Index / Code, Content, and Presentation / Apache Web Server
Forum Library, Charter, Moderators: Ocean10000 & incrediBILL & phranque

Apache Web Server Forum

    
Not able to access .ttf and .moff files from apache
Sathishkumarkj




msg:4560870
 7:30 am on Apr 3, 2013 (gmt 0)

Hi All ,
I amnot able to access .ttf and .moff files from Apache server. I am sure these files are present in the server and I am able to browse the other files which are there in the same location.

Pls help ............

 

lucy24




msg:4560873
 8:10 am on Apr 3, 2013 (gmt 0)

Do you mean browse, literally, with your browser? Or do you mean that you can't open the files-- or can't see them-- when you go into the site with ftp or equivalent?

Can the browser itself handle .ttf and .moff extensions? (What is ttf, anyway? To me it means TrueType font-- which I certainly wouldn't expect my browser to open by itself!)

Sathishkumarkj




msg:4560885
 9:21 am on Apr 3, 2013 (gmt 0)

yes this from browser.

when I am trying to open this file in browser it is giving 404 error.

You are correct about ttf file its a font file. If you try to open in browser it should show some content in browser. but it giving 404.

Please help me is it a access issue or some thing else it is access issue pls give me the solution.

phranque




msg:4560969
 1:38 pm on Apr 3, 2013 (gmt 0)

welcome to WebmasterWorld, Sathishkumarkj!


did you check your server error log for clues?

lucy24




msg:4561124
 8:28 pm on Apr 3, 2013 (gmt 0)

If you try to open in browser it should show some content in browser. but it giving 404.

Where "show some content" may = "download the file". (I'd managed to forget this, so I tried on my one-and-only embedded font.)

Just to double check: Do you get your server's ordinary 404 page, the same one you'd get if you typed garbage in the address bar? Error logs probably won't say anything beyond "file could not be found" -- but I'm pretty sure they'll show the real location of the file if there was any rewriting involved.

Further double checking: You're testing this by either typing the name directly into your browser, or using something like Fetch's "Web View" function on the raw file?

I don't know if all ftp-and-similar programs work the same way. If I use WebView it is treated exactly as if I had typed the name in my browser's address bar, meaning that the request passes through config file and htaccess before I'm allowed to see it.

Sathishkumarkj




msg:4561412
 5:19 pm on Apr 4, 2013 (gmt 0)

The url is correct one and there is no clue in logs.

And the file isn't downloading just showing 404.

The same functionality is working fine in other servers....

phranque




msg:4561492
 8:15 pm on Apr 4, 2013 (gmt 0)

if you have a 404 logged in the access log there should also be an error message logged in the error log specifying the missing file path.

lucy24




msg:4561542
 10:57 pm on Apr 4, 2013 (gmt 0)

The url is correct one and there is no clue in logs.


Do you mean, no clue in error logs? Access logs won't say, because they're completely silent about rewrites. You need your error logs, because those will show the actual path after any rewriting.

Sathishkumarkj




msg:4561593
 5:23 am on Apr 5, 2013 (gmt 0)

any suggestion about this issue

phranque




msg:4561594
 5:28 am on Apr 5, 2013 (gmt 0)

look in the error log for the time stamp corresponding to when you requested .ttf or .moff files and make note of the file path the server attempted to access for that request.
then figure out why that file doesn't exist in the expected location or why the server isn't looking for that file in the expected location.
first you should verify where the server is looking for that file.
in the error log...

Sathishkumarkj




msg:4561610
 6:54 am on Apr 5, 2013 (gmt 0)

I verified the location. And I have checked the logs the url which I am accessing is correct. I have doubt some of the security is blocking the access.

Please suggest how to give the access to this file

lucy24




msg:4561630
 8:09 am on Apr 5, 2013 (gmt 0)

If security is blocking access you would not see a 404 ("File does not exist" in error logs). You would see a 403 or 503 --there are other possibilities, but those are the most likely-- with explanation. Details depend on logging level, which you can't change if you are on shared hosting. On mine, a 403 says something unhelpful like "Denied by server configuation".

It will help if you quote a sample from logs showing an attempt to access the file. Show BOTH the access log AND the error log entries.

phranque




msg:4561653
 10:14 am on Apr 5, 2013 (gmt 0)

still assuming a 404 status code, the access log entry should show the url requested and the error log entry should show the file path the server was looking for.

Global Options:
 top home search open messages active posts  
 

Home / Forums Index / Code, Content, and Presentation / Apache Web Server
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved