Hola
A ver si esto te da alguna idea
Código Javascript
:
Ver original<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta name="http-equiv" content="Content-type: text/html; charset=UTF-8"/>
<script type="text/javascript">
var cad_inv, cade = ""
var valor = Math.round(175000*Math.random())+50000
var cadena = valor.toString();
for (var z = 0; z < cadena.length; z++) {
numero = cadena.charAt(z)
if ((cadena.length <= 5 && z == 1) || (cadena.length == 6 && z == 2) || (cadena.length >= 7 && z == 4)) {
//alert("punto")
numero += "."
}
document.write(numero);
}
</script>
</head>
<body>
</body>
</html>
Serte