Tengo un pegueño problema con un scritp que muestra un scroll de texto. Esta hecho en javascript pero lo tengo dentro de una función en php: os incluyo el codigo y ahora os cuento:
Código PHP:
function scrollnoticias()
{
echo"
<script language=\"JavaScript1.2\">
// ancho
var marqueewidth=150
// alto
var marqueeheight=80
// velocidad
var speed=1
// contenido
";
$rs=conexion();
$ssql = "select * from scroll order by id desc limit 1";
$rs = mysql_query($ssql);
$fila =mysql_fetch_array($rs);
echo"
var marqueecontents='<font face=\"Arial\"><small>".ECHO $fila[texto];."</small></font>' //AQUI ESTA MI PROBLEMA
if (document.all)
document.write('<marquee direction=\"up\" scrollAmount='+speed+' style=\"width:'+marqueewidth+';height:'+marqueeheight+'\">'+marqueecontents+'</marquee>')
// el codigo continua
Un saludo