mirror of
https://github.com/lkddi/nexusphp.git
synced 2026-04-14 20:40:49 +08:00
add event news_created
This commit is contained in:
@@ -48,8 +48,10 @@ if ($action == 'add')
|
||||
$notify = 'no';
|
||||
sql_query("INSERT INTO news (userid, added, body, title, notify) VALUES (".sqlesc($CURUSER['id']) . ", $added, " . sqlesc($body) . ", " . sqlesc($title) . ", " . sqlesc($notify).")") or sqlerr(__FILE__, __LINE__);
|
||||
$Cache->delete_value('recent_news',true);
|
||||
if (mysql_affected_rows() != 1)
|
||||
stderr($lang_news['std_error'], $lang_news['std_something_weird_happened']);
|
||||
if (mysql_affected_rows() != 1) {
|
||||
stderr($lang_news['std_error'], $lang_news['std_something_weird_happened']);
|
||||
}
|
||||
fire_event("news_created", mysql_insert_id());
|
||||
header("Location: " . get_protocol_prefix() . "$BASEURL/index.php");
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user