I have a classified ad script that I would like something done to it...
When a user posts his/her classified, I would like it to take them to it when it's uploaded.
Example:
I fill all the fields of my classifieds out, hit submit and when it finishes loaded I will be viewing my ad.
Can anyone help me with this?
Here's my code:
//If you're trying to post a new ad
if(isset($_POST['NewAd']))
{
$info = nl2br($info);
//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'], ((isset($_POST['image_l']) && $_POST['image_l'] != '') ? $_POST['image_l'] : $_FILES['image_f']), $_POST['category'], $_POST['price'], $info, $_POST['location']))
echo '<script language="JavaScript">alert("Success. Your ad has been placed.");</script>';
}
Thanks! 🙂