it is such that I need to build a system like facebook where you can write something on a poster, but this is how to lookup a database for themselves, and use a database for themselves. but I must have in some way made such that it is the same. What I should have few user database it’s image and it is approved image. and the user’s name
This her is my Users Database
CREATE TABLE IF NOT EXISTS `bruger` (
`id_bruger` int(200) NOT NULL AUTO_INCREMENT,
`rank` int(11) NOT NULL,
`brugernavn` varchar(255) NOT NULL,
`password` varchar(300) NOT NULL,
`profilbillede` varchar(255) NOT NULL,
`profilbillede_godkendt` int(2) NOT NULL,
`navn` varchar(100) NOT NULL,
`efternavn` varchar(200) NOT NULL,
`profiltekst` longtext NOT NULL,
`alder` int(50) NOT NULL,
PRIMARY KEY (`id_bruger`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 AUTO_INCREMENT=3 ;
This is my entry database
CREATE TABLE IF NOT EXISTS `opslag` (
`id_opslag` int(11) NOT NULL AUTO_INCREMENT,
`tekst` longtext NOT NULL,
`id_bruger` int(11) NOT NULL,
PRIMARY KEY (`id_opslag`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 AUTO_INCREMENT=2 ;
How have I try to build it but I do not know if I’ve done it right,
<table border="0">
<?php
if ($stmt = $mysqli->prepare('SELECT `tekst`, `id_bruger` FROM `opslag`')) {
$stmt->execute();
$stmt->store_result();
$stmt->bind_result($tekst, $id_bruger);
while ($stmt->fetch()) {
?>
<tr>
<td>
</td>
<td><?php echo $tekst;?></td>
</tr>
<?php
}
$stmt->close();
} else {
echo 'Der opstod en fejl i erklæringen: ' . $mysqli->error;
}
?>
</table>
What I need from the user system is
profilbillede
profilbillede_godkendt
brugernavn
Feel free to ask if there is more you want to know about this?
Hope you can help me
Jesper – Danmark
In that case you should use the following query instead of the one you have there
And your bind statement to this