Mysql
 sql >> Base de Dados >  >> RDS >> Mysql

PHP MYSQL


Você não usa <?php echo ... ?> quando você já está no modo PHP e ecoando algo. Basta concatenar a variável.
echo '<center><strong><font color="#3BB9FF">' . ucfirst($row['t_fn']) . '&nbsp;' . ucfirst($row['t_ln']) . '</font></strong></center>';

<?php echo ... ?> é usado quando você está apenas produzindo HTML diretamente e deseja inserir um pouco de PHP. Por exemplo, assim:
if($row['t_type'] == 1)
{ ?>
<center><strong><font color="#3BB9FF"><a href="view_t_profile.php?t_id=<?php echo $row['t_id']; ?>&t_type=<?php echo $row['t_type']; ?>" class="cls" target="_blank"><br />View Profile</a></font></strong></center>
<center><strong>Main Contact</strong></center>
<center><strong><font color="#3BB9FF"><?php echo ucfirst$row['t_fn']).'&nbsp;'.ucfirst($row['t_ln']); ?></font></strong></center>
<?php
}