
Jeżeli Cię dobrze zrozumiałem to będzie w ten sposób:
Kod:
#
#-----[ OPEN ]----------
#
includes/functions.php
#
#-----[ FIND ]----------
#
$rate_id = $row['total'] + 1;
#
#-----[ AFTER, ADD ]----------
#
$sql = "SELECT COUNT(rate_id) AS liczba
FROM " . RATE_USERS_TABLE. "
WHERE rater_id=".$userdata['user_id']."
AND rated_id = ".$profiledata['user_id'];
if ( !($result = $db->sql_query($sql)) )
{
message_die(GENERAL_ERROR, 'Error', '', __LINE__, __FILE__, $sql);
}
while($row = $db->sql_fetchrow($result)) {
$liczba = $row['liczba'];
}
if($liczba >= 1) {
message_die(GENERAL_MESSAGE, 'Już oceniłe¶ tego użytkownika!');
}
PS: Szukaj bo to już było na forum!
Autor postu otrzymał pochwałę