Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Just a quick question:

How can I prevent nginx from trimming file name with ... in listing directory?

share|improve this question

1 Answer 1

up vote 5 down vote accepted

It looks like the only way to that is to edit the source code. The following #define in src/http/modules/ngx_http_autoindex_module.c have to be changed:

#define NGX_HTTP_AUTOINDEX_NAME_LEN     50

Maybe something else needs to be tweaked too, but that's what I saw at first glance.

share|improve this answer
    
This could be time consuming. You sure there is no other way around this? If not I could start write a small php script. –  DucDigital Sep 12 '11 at 16:27
    
There's no other way, maximal length is hard-coded with the #define above. Yep, external script for directory listing may be a better solution. –  Vladimir Blaskov Sep 12 '11 at 16:32

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.