4) { $p1=(strpos(1,$linha,"|") ? strpos(1,$linha,"|")+1 : 0); $cod=substr($linha,0,$p1-1); $p2=(strpos($p1+1,$linha,"|") ? strpos($p1+1,$linha,"|")+1 : 0); $nome=substr($linha,$p1+1-1,$p2-$p1-1); $tex=substr($linha,strlen($linha)-(strlen($linha)-$p2)); if ($tex!="??") { // Insert new record $SQLQuery="Insert into cas (rca, lin, cod, val) Values (".$rca.",".$lin.",".$cod.",'".str_replace("'","''",$tex)."')"; mysql_query($SQLQuery); } $i1=$i2+3; $i2=(strpos($i1,$txt,"||") ? strpos($i1,$txt,"||")+1 : 0); if ($i2>0) { $linha=substr($txt,$i1-1,$i2-$i1); } else { $linha=""; } } // Show results header("Location: "."ca.asp?".$args."&r=".$rca."&c=".$cmdCMfic); } return $function_ret; } function ca_motores($rca,$rmo) { extract($GLOBALS); if (substr($rmo,strlen($rmo)-(1))=="#") { $SQLQuery="SELECT papi.rmo, mot.tipo, mm.nome as mo_model, mon.rma, mon.nome as mo_nome FROM ((papi inner join mot on papi.rmo=mot.rmo) inner join mm on mot.rmm=mm.rmm) inner join mon on mon.rma=mm.rma Where papi.rca=".$rca." and mon.lin=".$linx." GROUP BY papi.rca, papi.rmo, mot.tipo, mm.nome, mon.rma, mon.nome, mon.lin order by papi.rmo"; } else { $SQLQuery="SELECT mot.rmo, mot.tipo, mm.nome as mo_model, mon.rma, mon.nome as mo_nome FROM (mot inner join mm on mot.rmm=mm.rmm) inner join mon on mon.rma=mm.rma Where mot.rmo=".$rmo." and mon.lin=".$linx; } $result = mysql_query($SQLQuery); while ($RSList= mysql_fetch_array($result)) { ?>&c=">  
0) { $SQLQuery="SELECT fotos.*, contactos.copynote FROM fotos inner join contactos on fotos.sig=contactos.sig where fotos.ref=".$rca." and fotos.cref=".$REF_CA." Limit ". rand(0,$n-1) .", 1"; $result = mysql_query($SQLQuery); $RSfoto= mysql_fetch_array($result); tab_bor(); if ($n>1) { tab_bar2(4); ?>$Modo_publico) { $SQLQuery="SELECT ca.rca, ca.nome as ca_model, can.nome as ca_nome FROM ca inner join can on ca.rco=can.rco where ca.rco=".$rco." and can.lin=".$linx; if (($result = mysql_query($SQLQuery)) and ($RSList = mysql_fetch_array($result))) { tab_bor(); tab_bar(4); ?>0) { ?>
 =$Modo_privado) { ?> <?       echo $titulo[$N_MODEL]; ?>
" ALT="Photo">
">" ALT="Zoom" BORDER="0">
[Edit]
  
0) { if ($nf > 1) echo(""); $SQLQuery="Select fotos.foto, fotos.zoom, contactos.copynote from fotos, contactos, papi where fotos.sig=contactos.sig and papi.rpa=fotos.ref and fotos.dat<=".$hiso." and fotos.camp=1 and fotos.cref=".$REF_PA." and papi.rca=$rca and (fotos.gal='img' or fotos.gal is NULL) order by fotos.ref limit ".rand(0,$nf-1).", 1"; if (($result = mysql_query($SQLQuery)) and ($RSList = mysql_fetch_array($result))) { echo(""); tab_bar1(10); } } } // Pilotos e respectivas participações $SQLQuery="SELECT count(papi.rpi) as total, papi.rpi, pin.nome as pi_nome FROM papi, pin Where papi.rpi=pin.rpi and papi.rca=".$rca." and papi.rpi>0 GROUP BY papi.rpi, papi.rca order by total desc, pin.apel"; if (($result = mysql_query($SQLQuery)) and mysql_num_rows($result) > 0) { ?>






0) { ?>
-
0) { ?>
-
0) { ?>
-

$titulo[$N_PGAL]
"); if ($RSList["zoom"] == 0) echo("\"Photo\"
"); else echo("\"Zoom\"
"); echo("".$RSList["copynote"]."
:
&c=0"> &rca=">