<?php

class AdcSearchForm extends AdcWidget{

	static function register_shortcode( $atts ){
		$w = new self();
 		return $w->widget(array(),array());
	}

    public function __construct() {
        parent::__construct("text_widget", "ADC Search Form",
            array("description" => ""));
    }	

	public function widget($args, $instance) {
		$view = new View("search_form");
 		$settings = $this->getSettings();
 		$view->setVar("settings", $settings);
 		$categories = $this->api->categories();
 		$view->setVar("categories", $categories);
	    return $view->fetch();
	}    
}