Hi,
I can't seem how to do a confirmation page when someone post an ad.
Here is my code for them when they post the ad:
<?php
require('header.php');
//If you're not logged in...
if($user->name == '')
{
echo 'Sorry, you must be logged in to post an ad...';
require('footer.php');
die('');
}
//If you're trying to post a new ad
if(isset($_POST['NewAd']))
{
//Create the CAd object, and create the ad
$ad = new CAd($sql);
var_dump($_POST);
var_dump($_FILES);
if($ad->NewAd($user->ID, $_POST['title'], $_POST['category'], nl2br($_POST['info'])))
echo '<script="JavaScript">window.location="index.php";</script>';
}
require('footer.php');
?>
If anyone knows of a site that shows me how to, or if someone can tell me the code... It will be greatly appreciated!
Thanks. 🙂