Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Agile forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

fake path error in jsp

 
vasanth raman
Greenhorn
Posts: 24
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
<html>
<head>
</head>
<script type="text/javascript">
function play()
{
var file=document.upload.vpath.value;
alert(file);
}
</script>
<body>
<form name="upload">
<input type="file" name="vpath">    <input type="button" value="play" onclick="play()">
</form>
</body>
</html>

this code perfectly work in windowsxp but not working in vista it shows the fackepath in java script
 
David Newton
Author
Rancher
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Please UseCodeTags when posting code or configuration. Unformatted code and configuration is very difficult to read. You can edit your post to include them by using the button.
 
David Newton
Author
Rancher
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
is it the same browser?

In any case, what do you mean by "fake path"?
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64629
86
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
There is no JSP dimension to this question. Moved to the HTML forum.
 
Misha Ver
Ranch Hand
Posts: 470
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
vasanth raman wrote:this code perfectly work in windows xp but not working in vista it shows the fackepath in java script


Windows XP or Windows Vista are red herring in your case. Most likely you have a problem with IE8, look at value property
 
Anbarasu Aladiyan
Ranch Hand
Posts: 182
Chrome Eclipse IDE Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Try after adding to your form tag.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic