X-Git-Url: http://p2p-next.cs.pub.ro/gitweb/?a=blobdiff_plain;f=application%2Fcontrollers%2Fvideo.php;h=4a15ba57bc685e2b6109d489d04633a66741c3ec;hb=adc2c33c37c781444c4234c6fed38e95d084ed8d;hp=5a4b9d58865f36baf4b0279d90ee6cb261008bda;hpb=d4b234f611d405b8a7935a86f50ec071779c2729;p=living-lab-site.git diff --git a/application/controllers/video.php b/application/controllers/video.php index 5a4b9d5..4a15ba5 100644 --- a/application/controllers/video.php +++ b/application/controllers/video.php @@ -31,27 +31,26 @@ class Video extends CI_Controller { */ public function watch($id, $name = NULL, $plugin = NULL) { - $this->load->helper('url'); - // ** // ** LOADING MODEL // ** // Retrieve video information. $this->load->model('videos_model'); + $this->videos_model->inc_video_var($id, 'views'); $data['video'] = $this->videos_model->get_video($id, $name); + $categories = $this->config->item('categories'); + $data['video']['category_name'] = + $categories[ $data['video']['category_id'] ]; $data['plugin_type'] = ($plugin === NULL ? 'auto' : $plugin); // Display page. $params = array( 'title' => $data['video']['title'] . ' -- ' . $this->config->item('site_name'), 'css' => array( - 'jquery-ui.css', 'jquery.ui.nsvideo.css', 'video.css' ), 'js' => array( - 'jquery.js', - 'jquery-ui.js', 'jquery.ui.nsvideo.js' ), //'metas' => array('description'=>'','keywords'=>'')