Advertisement
hmeco

hest

Jan 31st, 2015
196
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.54 KB | None | 0 0
  1.     function addNewsItem($newsTitle, $newsSlug, $newsIntro, $newsStorry){
  2.         $tools = new toolbox();
  3.         $sendNewsItemToDB = "INSERT INTO tblNews (newsTitle,newsSlug,newsIntro,newsStorry) VALUES ('".$newsTitle."','".$newsSlug."','".$newsIntro."','".$newsStorry."')";
  4.             echo $sendNewsItemToDB;
  5.             $result = $tools->executeSqlQuery($sendNewsItemToDB);
  6.             if ($sendNewsItemToDB($sql) === TRUE) {
  7.                     echo "New record created successfully";
  8.                 } else {
  9.                     echo "Error: " . $sql . "<br>" . $conn->error;
  10.                 }
  11.              }
  12.    
  13.         }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement