По сути, я делаю загрузку и загрузку кода. Я загружаю .mp3 в tomcat apache, затем перемещаюсь в папку нашего проекта, и после этого я пытаюсь воспроизвести эту песню на странице JSP, но я не могу этого сделать.Во-первых, я думаю, что, возможно, путь к mp3-файлу неправильный.Затем я пытаюсь использовать HTML, в файле HTML все работает, но не в JSP.
Примечание. Очень много звуковых тегов, потому что ссылка (источник звукового тега) неверна.
КОД ТЕЛА JSP
<body>
<embed src="file:///E:/Code_IDE/apache-tomcat-9.0.14/apache-tomcat-9.0.14/somesh/text_fileuploadzeAmhjygg6.mp3" type="application/x-mplayer2" pluginspage="http://www.microsoft.com/Windows/MediaPlayer/" name="mediaplayer1" ShowStatusBar="true" EnableContextMenu="false" width="700" height="500" autostart="false" loop="false" align="middle" volume="60" ></embed>
<audio controls>
<source src="file:///E:/Code_IDE/apache-tomcat-9.0.14/apache-tomcat-9.0.14/somesh/text_fileuploadzeAmhjygg6.mp3" type="audio/wav" >
</audio>
<audio controls>
<source src="/MusicAppForCuples/WebContent/musicAdmin/somesh.mp3" type="audio/mpeg" >
</audio>
<audio controls>
<source src="MusicAppForCuples/WebContent/musicAdmin/somesh.mp3" type="audio/mpeg" >
</audio>
<audio controls>
<source src="/musicAdmin/somesh.mp3" type="audio/mpeg" >
</audio>
<audio controls>
<source src="/musicAdmin/somesh.mp3" type="audio/mpeg" >
</audio>
<audio controls>
<source src="file:///E:/Code_IDE/apache-tomcat-9.0.14/apache-tomcat-9.0.14/somesh/text_fileuploadzeAmhjygg6.mp3"
type="audio/mpeg">
</audio>
<audio controls>
<source src="E:/Code_IDE/apache-tomcat-9.0.14/apache-tomcat-9.0.14/somesh/text_fileuploadzeAmhjygg6.mp3"
type="audio/mpeg">
</audio>
<br>
<audio controls>
<source src=" <% out.print((rootPath));%>\text_fileuploadzeAmhjygg6.mp3" type="audio/mpeg">
Your browser does not support the audio element.
</audio>
<audio controls>
<source src=" <% out.print(rootPath);%>text_fileuploadzeAmhjygg6.mp3" type="audio/mpeg">
Your browser does not support the audio element.
</audio>
<audio controls>
<source src="/text_fileuploadzeAmhjygg6.mp3" type="audio/mpeg">
Your browser does not support the audio element.
</audio>
<embed src="E:/Code_IDE/apache-tomcat-9.0.14/apache-tomcat-9.0.14/somesh/text_fileuploadzeAmhjygg6.mp3">
</body>
КОД ТЕЛА HTML
<embed src="file:///E:/Code_IDE/apache-tomcat-9.0.14/apache-tomcat-9.0.14/somesh/text_fileuploadzeAmhjygg6.mp3" type="application/x-mplayer2" pluginspage="http://www.microsoft.com/Windows/MediaPlayer/" name="mediaplayer1" ShowStatusBar="true" EnableContextMenu="false" width="700" height="500" autostart="false" loop="false" align="middle" volume="60" ></embed>
<audio controls>
<source src="file:///E:/Code_IDE/apache-tomcat-9.0.14/apache-tomcat-9.0.14/somesh/text_fileuploadzeAmhjygg6.mp3" type="audio/wav" >
</audio>
<audio controls>
<source src="/MusicAppForCuples/WebContent/musicAdmin/somesh.mp3" type="audio/mpeg" >
</audio>
<audio controls>
<source src="MusicAppForCuples/WebContent/musicAdmin/somesh.mp3" type="audio/mpeg" >
</audio>
<audio controls>
<source src="/musicAdmin/somesh.mp3" type="audio/mpeg" >
</audio>
<audio controls>
<source src="/musicAdmin/somesh.mp3" type="audio/mpeg" >
</audio>
<audio controls>
<source src="file:///E:/Code_IDE/apache-tomcat-9.0.14/apache-tomcat-9.0.14/somesh/text_fileuploadzeAmhjygg6.mp3"
type="audio/mpeg">
</audio>
<audio controls>
<source src="E:/Code_IDE/apache-tomcat-9.0.14/apache-tomcat-9.0.14/somesh/text_fileuploadzeAmhjygg6.mp3"
type="audio/mpeg">
</audio>
<br>
<audio controls>
<source src=" <% out.print((rootPath));%>\text_fileuploadzeAmhjygg6.mp3" type="audio/mpeg">
Your browser does not support the audio element.
</audio>
<audio controls>
<source src=" <% out.print(rootPath);%>text_fileuploadzeAmhjygg6.mp3" type="audio/mpeg">
Your browser does not support the audio element.
</audio>
<audio controls>
<source src="/text_fileuploadzeAmhjygg6.mp3" type="audio/mpeg">
Your browser does not support the audio element.
</audio>
<embed src="E:/Code_IDE/apache-tomcat-9.0.14/apache-tomcat-9.0.14/somesh/text_fileuploadzeAmhjygg6.mp3">
</body>
```[JSP image -- not working][1]
[HTML page -- with same coding -- 4 tags are working (other tags are not wrking because of link issue)][2]
[1]: https://i.stack.imgur.com/5zgbe.png
[2]: https://i.stack.imgur.com/Vj1E6.png
NOTE -- If you want other details like code and all please let me know.