public function deleteAction()
 {
     $id = $_GET['id'];
     $source = TrafficSourceModel::model()->getRowFromPk($id);
     if ($source) {
         $source->delete();
     }
     header("Location: /trafficsources");
     BTApp::end();
 }
 public function indexAction()
 {
     $this->setupUser();
     $this->useActionAsCurrentNav();
     $this->setVar("redirects", CloakerModel::model()->getRows());
     if (getArrayVar($_GET, 'campaign_id')) {
         $campaign = CampaignModel::model()->getRowFromPk($_GET['campaign_id']);
     } else {
         $campaign = CampaignModel::model();
     }
     $this->setVar('campaign', $campaign);
     $this->setVar("title", "Add A Campaign");
     $this->setVar('traffic_sources', TrafficSourceModel::model()->getRows());
     $campaign->randomizeVariableNames();
     $this->render("tracker/code");
 }
			</div>
		</div>
	<?php 
}
?>
	
	<?php 
if ($show_options['show_traffic_source']) {
    ?>
		<div class="grid_2">
			<div class="box">
				<label>Traffic Source</label>

				<?php 
    $this->loadModel('TrafficSourceModel');
    BTForm::createSelect('traffic_source_id', TrafficSourceModel::model()->getRows(), BTAuth::user()->getPref('traffic_source_id'), 'traffic_source_id', '', 'name', 'traffic_source_id', 'Show All');
    ?>
			</div>
		</div>
	<?php 
}
?>

	<?php 
if ($show_options['show_breakdown']) {
    ?>
		<div class="grid_2">					
			<div class="box">
				<label>Breakdown</label>
				<select name="breakdown">
					<option <?php