搜索 | 用户支持

防范以用户支持为名的诈骗。我们绝对不会要求您拨打电话或发送短信,及提供任何个人信息。请使用“举报滥用”选项报告涉及违规的行为。

详细了解

Ellipsis is not working in mozilla for longer file lenth though its working in Chrome, what is the style that i have to apply for browser default button?

  • 17 个回答
  • 2 人有此问题
  • 1 次查看
  • 最后回复者为 bala2343

more options

i have tried applying the -moz-text-overflow, and -moz-binding :url but its was not worked.

i have tried applying the -moz-text-overflow, and -moz-binding :url but its was not worked.

所有回复 (17)

more options

Adding images for clear understanding.....

more options

What about

text-overflow: ellipsis;
 /* BOTH of the following are required for text-overflow */
 white-space: nowrap;
 overflow: hidden;

?

more options

though i have have added both in my CSS class its not working

more options

Attaching the screenshot here

more options

Is this code work for you?

https://jsfiddle.net/TjGyz/984/

more options

No its not working for me. complete page styling was changed PFA

more options

new button was created below the previous button but styling of page was changed since div tag was used in many places which took the stying of new class which you have sent.

more options

I didn't expect you to use this style on your page. I'm just asking if the ellipsis works for you on that exemplary page.

more options

I see the ellipsis in the DIV container, but not in the input field in the example.

Does that work for you Ty?

more options

cor-el said

I see the ellipsis in the DIV container, but not in the input field in the example. Does that work for you Ty?

Yes, after adding a file with long filename to the input it actually works for me.

more options

... or I may be wrong. Looks completely the same without text-overflow. The filename is not getting out the element. Specifying width is enough.

more options

mask-image works for the input field although the editor doesn't like/recognize it.

more options

https://jsfiddle.net/TjGyz/984/ this one is working fine when i open it in chrome as well as in Mozilla but the actual problem was not solved.

more options

at the end of ellipsis i have to show file extension as well in the UI

more options

in chrome the extension is showing with your code PFA

more options

Firefox and Chrome apply "width" to the file input differently. Firefox hides a length of text corresponding to the width of the Browse button. If you counteract that with padding-right:95px then the control in Firefox expands to show the full contents. Unfortunately, Chrome then has excess white space on the right:

https://jsfiddle.net/TjGyz/1016/

So that's not very satisfying.

由jscher2000 - Support Volunteer于修改

more options

Thanks a lot for your wonderful support... its working fine now in my portal now