• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Jeanne Boyarsky
  • Devaka Cooray
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Knute Snortum
  • Bear Bibeault
Saloon Keepers:
  • Ron McLeod
  • Tim Moores
  • Stephan van Hulst
  • Piet Souris
  • Ganesh Patekar
Bartenders:
  • Frits Walraven
  • Carey Brown
  • Tim Holloway

Chinese Attached filename can't be shown

 
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I found that Chinese attached filename can't be shown probably. (see the attached jpg)
I have also created an issue (JF-327) in the isue tracking system.

[originally posted on jforum.net by willchoy]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
How to solve?
[originally posted on jforum.net by Anonymous]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Open templates/default/post_form.htm, search for the <form> tag and remove the attribute

accept-charset="${encoding}"

Rafael
[originally posted on jforum.net by Rafael Steil]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
But I cannot find this attribute
Version of Jforum i used is 2.1.4
[originally posted on jforum.net by Anonymous]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hhmm.. right..

I'll take a closer look.

Rafael
[originally posted on jforum.net by Rafael Steil]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I got this problem, too.
I've tested it on the 2.1.5 cvs version.
How to fix it?
[originally posted on jforum.net by andowson]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
OK, I got this problem fixed now.
Modify src/net/jforum/ActionServletRequest.java


Now, there's only one little problem remained: How to make the download filename displayed as it originally uploaded not a random coded string like CAX0AC.
[originally posted on jforum.net by andowson]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I found a solution from MVNForum's Chinese support board.
:arrow: First, add a method toUtf8String to src/net/jforum/view/forum/PostAction.java


:arrow: Secod, modify the downloadAttach() method
Change this line:

into


:arrow: Finally, recompile the source code and reload the class files.

Notice:
I've tried the other ways to do so, but they all failed.
So, you may skip trying these methods:




OK, that's all.
[originally posted on jforum.net by andowson]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
toUtf8String() can encode chinese filename for IE,but it don't work in Firefox.
In Firefox chinese filename is '%xx%xx...'
[originally posted on jforum.net by Anonymous]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Anonymous wrote:toUtf8String() can encode chinese filename for IE,but it don't work in Firefox.
In Firefox chinese filename is '%xx%xx...'


OK, the Firefox fix is as follows:
Edit src/net/jforum/view/forum/PostAction.java
modify the downloadAttach() method,

as follows:

[originally posted on jforum.net by andowson]
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!