[Php-avanzado] ej imagenes
Daniel Billia
ferudine en sion.com
Sab Jun 15 12:13:02 ART 2013
Leo disculpa que se tan rompe te mando el que
vimos lo probé de nuevo pero no funca
<HTML>
<HEAD>
<TITLE>New Document</TITLE>
</HEAD>
<body>
<form name="Upload" enctype="multipart/form-data" method="post">
Filename: <INPUT type="file"
id="carga"> <INPUT type="button" id="send" value="Upload">
</form>
<div id="divfoto" align="center" style="height:
200px;width: 500px;border-style: ridge;border-color: red">
</div>
<script type="text/javascript">
var img_id=0
var image = new Array()
document.getElementById('send').onclick=function()
{
img_id++
var id="imgid"+img_id
image = document.getElementById('carga').value;
alert(id+' '+image);
document.getElementById('divfoto').innerHTML="<img
id='"+id+"' src='"+image+"' width=500px height=200px>"
}
document.getElementById('carga').onchange=function()
{
//console.log('entra');
alert('entra');
img_id++
var id="imgid"+img_id
image = document.getElementById('carga').value;
document.getElementById('divfoto').innerHTML="<img
id='"+id+"' src='"+image+"' width=500px height=200px>"
}
</script>
</body>
</html>
------------ próxima parte ------------
Se ha borrado un adjunto en formato HTML...
URL: <http://www3.fi.mdp.edu.ar/pipermail/php-avanzado/attachments/20130615/a8985186/attachment.html>
Más información sobre la lista de distribución Php-avanzado