<div><input type='file' title="Choose a video please" id="aa"
onchange="pressed()"><label id="fileLabel">Select New
file</label></div>
<style>
input[type=file]{
width:80px;
color:transparent;
}
</style>
<script>
window.pressed = function(){
var a = document.getElementById('aa');
if(a.value == "")
{
fileLabel.innerHTML = "Select New file";
}
else
{
var theSplit = a.value.split('\\');
fileLabel.innerHTML = theSplit[theSplit.length-1];
}
};
</script>
<style>
input[type=file]{
width:80px;
color:transparent;
}
</style>
<script>
window.pressed = function(){
var a = document.getElementById('aa');
if(a.value == "")
{
fileLabel.innerHTML = "Select New file";
}
else
{
var theSplit = a.value.split('\\');
fileLabel.innerHTML = theSplit[theSplit.length-1];
}
};
</script>
No comments:
Post a Comment