This week's book giveaway is in the Clojure forum.
We're giving away four copies of Clojure in Action and have Amit Rathore and Francis Avila on-line!
See this thread for details.
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Struts2 Play audio file

 
Dev Anand
Ranch Hand
Posts: 41
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I have written following code to play audio file. It is neither showing any error message nor playing the mp3 song.



I'm calling the above class from jsp file as below :



can anybody help me why its not getting played?

Thank you.

Regards
Dev Anand. P
 
Joe Ess
Bartender
Posts: 9214
9
Linux Mac OS X Windows
  • 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Struts and JSP code run on the server, so I'm not sure your code even does what you want it to do (not to mention using Java code in JSP's is a Bad Idea).
If you want to play a file for the user through the browser, you should probably look at the java.applet.Applet play() method.
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic