Estou com o seguinte problema:
Tenho um sistema de News em Flash. Ele chama um arquivo em php que consulta o MySQL e retorna as notícias para o Flash. Inicialmente o meu sistema comportava até 3 notícias mostradas na tela. Mas agora estou precisando colocar um scroll de rolagem no Flash. Ele tem um retângulo onde aparecem os primeiros 110 caracteres da notícia. Quando você clica no retângulo, ele chama uma imagem e a notícia inteira, que aparece em outro quadro.
A dúvida é:
Como eu faço o flash criar um retângulo desses, de pré-visualização, para cada registro que recebe do PHP?
Aí eu posso fazer um scroll de rolagem em eixo Y comum.
Ou tem algum outro jeito?
Arquivo carregar_noticias.php
QUOTE
include "conexao.php";
$query = mysql_query("select nw_id, nw_tit, nw_cont, nw_file from tab_news where nw_active=1 order by nw_date") or die("sem query");
$totquery = mysql_num_rows($query);
for ($r=1;$fetch = mysql_fetch_row($query);$r++){
$vtemp1 = "prenoticia" . $r;
$vtemp2 = "noticia" . $r;
$vtemp3 = "arquivo" . $r;
$prenoticia = $fetch[1];
$noticia = $fetch[2];
$arquivo = $fetch[3];
//Pega os primeiros 110 caracteres da notícia pra pré-visualizacao
//Testa pra ver se a pré-visualização não vai cortar uma palavra ao meio.
for ($t=110;empty($end);$t--){
$subtes = substr($noticia, $t, 1);
if ($subtes == " "){
$sub = substr($noticia, 0, $t);
$end = true;
}//end if
}//end for
unset($end);//destrói a variável $end
$sub .= " ...";//acrescenta reticências à prenoticia
print "
&$vtemp1=$sub
&$vtemp2=$noticia
&$vtemp3=$arquivo
";
}//end for
$query = mysql_query("select nw_id, nw_tit, nw_cont, nw_file from tab_news where nw_active=1 order by nw_date") or die("sem query");
$totquery = mysql_num_rows($query);
for ($r=1;$fetch = mysql_fetch_row($query);$r++){
$vtemp1 = "prenoticia" . $r;
$vtemp2 = "noticia" . $r;
$vtemp3 = "arquivo" . $r;
$prenoticia = $fetch[1];
$noticia = $fetch[2];
$arquivo = $fetch[3];
//Pega os primeiros 110 caracteres da notícia pra pré-visualizacao
//Testa pra ver se a pré-visualização não vai cortar uma palavra ao meio.
for ($t=110;empty($end);$t--){
$subtes = substr($noticia, $t, 1);
if ($subtes == " "){
$sub = substr($noticia, 0, $t);
$end = true;
}//end if
}//end for
unset($end);//destrói a variável $end
$sub .= " ...";//acrescenta reticências à prenoticia
print "
&$vtemp1=$sub
&$vtemp2=$noticia
&$vtemp3=$arquivo
";
}//end for
Grato
Eduardo Hayashi

Help














