Shoutbox

Gestart doorBengt6 reacties44 weergaven

7 berichten · pagina 1 van 1

Bengt

Lid · Topicstarter

Berichten
803
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
Hallo,

Ik wil graag dat hij de laatste shout aangeeft in een balk, alleen nu geeft hij ze allemaal aan in een rijtje,
hoe kan ik dit veranderen?

<div id="shout">
            [COLOR= #0000BB]<?php[/COLOR]
    [URL="http://www.php.net/while"]while[/URL] [COLOR= #007700]([/COLOR][COLOR= #0000BB]$bFetch[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/mysql_fetch_assoc"]mysql_fetch_assoc[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$bQuery[/COLOR][COLOR= #007700]))
    {[/COLOR]

    ?>
    [COLOR= #0000BB]<?php
    $uQuery[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/mysql_query"]mysql_query[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"SELECT avatar FROM leden WHERE naam = "[/COLOR] [COLOR= #007700].[/COLOR] [URL="http://www.php.net/mysql_real_escape_string"]mysql_real_escape_string[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$bFetch[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]poster[/COLOR][COLOR= #007700]]) .[/COLOR] [COLOR= #DD0000]""[/COLOR][COLOR= #007700])[/COLOR] or [URL="http://www.php.net/die"]die[/URL][COLOR= #007700]([/COLOR][URL="http://www.php.net/mysql_error"]mysql_error[/URL][COLOR= #007700]());[/COLOR]
    [COLOR= #0000BB]$uFetch[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/mysql_fetch_assoc"]mysql_fetch_assoc[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$uQuery[/COLOR][COLOR= #007700]);[/COLOR]
    [URL="http://www.php.net/if"]if[/URL] [COLOR= #007700](![/COLOR][URL="http://www.php.net/empty"]empty[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$uFetch[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]avatar[/COLOR][COLOR= #007700]]))
    {[/COLOR]
        [COLOR= #0000BB]$avatar[/COLOR] [COLOR= #007700]=[/COLOR] [COLOR= #DD0000]<img src="http://www.bengt.s2.one2xs.com/avatar/[/COLOR] [COLOR= #007700].[/COLOR] [COLOR= #0000BB]$uFetch[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]avatar[/COLOR][COLOR= #007700]] .[/COLOR] [COLOR= #DD0000]" border="0" width="37" height="37"/>[/COLOR][COLOR= #007700];
    }[/COLOR][URL="http://www.php.net/else"]else[/URL][COLOR= #007700]{[/COLOR]
        [COLOR= #0000BB]$avatar[/COLOR] [COLOR= #007700]=[/COLOR] [COLOR= #DD0000]<div style="width: 35px; height: 35px; border: 1px #000 solid; background: #FFFFFF;"><div style="margin-top: 10px;"><center>?</center></div></div>[/COLOR][COLOR= #007700];
    }[/COLOR]
    ?>
         <div class="shout" id="shout_<?=$bFetch[id] ?>" ">
        
            <table cellspacing="0" cellpadding="0" width="100%">
                <tr>
                    <td width="40" style="padding-top: 6px; padding-left: 5px;">
                    <a href="http://<?=htmlentities($bFetch[poster]); ?>.bengt.s2.one2xs.com/">
                    <?=$avatar; ?>
                    </td>
                    <td style="padding-left: 7px;">
                    [COLOR= #0000BB]<?php[/COLOR] 
                    [URL="http://www.php.net/if"]if[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$bFetch[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]kleur[/COLOR][COLOR= #007700]] ==[/COLOR] [COLOR= #DD0000]"roze"[/COLOR][COLOR= #007700])
                        {[/COLOR]
                            ?>
                            <a href="http://<?=htmlentities($bFetch[poster]); ?>.bengt.s2.one2xs.com/"><b><font color=fuchsia><?=htmlentities($bFetch[poster]); ?></font></b></a>: <?=smilies(htmlentities(stripslashes($bFetch[bericht]))); ?> ~ Geplaatst op <?=smilies(htmlentities(stripslashes($bFetch[gepostop]))); ?>
                        [COLOR= #0000BB]<?php[/COLOR] 
                        [COLOR= #007700]}[/COLOR]
                    [URL="http://www.php.net/elseif"]elseif[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$bFetch[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]kleur[/COLOR][COLOR= #007700]] ==[/COLOR] [COLOR= #DD0000]"blauw"[/COLOR][COLOR= #007700])
                        {[/COLOR]
                        ?>
                            <a href="http://<?=htmlentities($bFetch[poster]); ?>.bengt.s2.one2xs.com/"><b><font color=blue><?=htmlentities($bFetch[poster]); ?></font></b></a>: <?=smilies(htmlentities(stripslashes($bFetch[bericht]))); ?> ~ Geplaatst op <?=smilies(htmlentities(stripslashes($bFetch[gepostop]))); ?>
                        [COLOR= #0000BB]<?php[/COLOR]
                        [COLOR= #007700]}[/COLOR]            
    [URL="http://www.php.net/elseif"]elseif[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$bFetch[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]kleur[/COLOR][COLOR= #007700]] ==[/COLOR] [COLOR= #DD0000]"rood"[/COLOR][COLOR= #007700])
                        {[/COLOR]
                        ?>
                            <a href="http://<?=htmlentities($bFetch[poster]); ?>.bengt.s2.one2xs.com/"><b><font color=red><?=htmlentities($bFetch[poster]); ?></font></b></a>: <?=smilies(htmlentities(stripslashes($bFetch[bericht]))); ?> ~ Geplaatst op <?=smilies(htmlentities(stripslashes($bFetch[gepostop]))); ?>
                        [COLOR= #0000BB]<?php[/COLOR]
                        [COLOR= #007700]}[/COLOR]                            
                    [URL="http://www.php.net/else"]else[/URL]
                        [COLOR= #007700]{[/COLOR]
                        ?>
                            <a href="http://<?=htmlentities($bFetch[poster]); ?>.bengt.s2.one2xs.com/"><b><font color=black><?=htmlentities($bFetch[poster]); ?></font></b></a>: <?=smilies(htmlentities(stripslashes($bFetch[bericht]))); ?> ~ Geplaatst op <?=smilies(htmlentities(stripslashes($bFetch[gepostop]))); ?>
                        [COLOR= #0000BB]<?php[/COLOR]
                        [COLOR= #007700]}[/COLOR]                
                        ?>

                    
                    </td>
                </tr>
            </table>
            
            
    </div>


-Bengt
0
Berichten
93.699
Reputatie
0
Punten
1,27
Lid sinds
Laatst gezien
Ben ik ook benieuwd na, hoop dat iemand het weet! hypocriteen openbaar zegen kan yummie
0
Bengt

Lid · Topicstarter

Berichten
803
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
ontopic smile
0
Berichten
5.957
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
Bedoel je bv. enkel de laatste 10?
0
Bengt

Lid · Topicstarter

Berichten
803
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
nee alleen de laatste..
0
Berichten
93.699
Reputatie
0
Punten
1,27
Lid sinds
Laatst gezien
Daarvoor moeten we wel even de $bQuery zien.
Maar je doet dat via: ORDER BY id DESC LIMIT 1 op het einde te zetten. Dat toont de laatste
0
Bengt

Lid · Topicstarter

Berichten
803
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
dankjewel! smile
0

Jouw reactie

Deel je idee, stel een vraag of help een ander verder.

Editor laden…

Praat mee met de One2xs-community.

Inloggen om te reageren