/**
	* Show waiting approvals
	*/
	function showapprovals($rows, $pageNav)
	{
		global $smartyvs, $limitstart, $Itemid, $option;

		/** define template variables **/
		$hidden_inputs = '<input type="hidden" name="boxchecked" value="0" />
		<input type="hidden" name="option" value="com_hwdvideoshare" />
		<input type="hidden" name="limitstart" value="'.$limitstart.'" />
		<input type="hidden" name="task" value="approvals" />
		<input type="hidden" name="hidemainmenu" value="0">';
		$search = _HWDVIDS_RPP.'&nbsp;';
		$search.= $pageNav->getLimitBox().'&nbsp;';

		/** assign template variables **/
		$smartyvs->assign( "hidden_inputs" , $hidden_inputs );
		$smartyvs->assign( "header_title" , _HWDVIDS_SECTIONHEAD_APPROVALS );
		$smartyvs->assign( "print_search", 1 );
		$smartyvs->assign( "search", $search );
		$smartyvs->assign( "totalvideos", count($rows) );
		$smartyvs->assign( "writePagesLinks", $pageNav->getPagesLinks() );
		$smartyvs->assign( "writePagesCounter", $pageNav->getPagesCounter() );

		/** assign template arrays **/
		$list_all = array();
		$k = 0;
		for ($i=0, $n=count($rows); $i < $n; $i++) {
			$row = $rows[$i];

			$list_all[$i]->id = $row->id;
			$list_all[$i]->checked = JHTML::_('grid.checkedout', $row, $i);
			if ( $row->checked_out && ( $row->checked_out != $my->id ) ) {
				$list_all[$i]->title = stripslashes($row->title);
			} else {
				$link = 'index.php?option=com_hwdvideoshare&task=editvidsA&hidemainmenu=1&cid='. $row->id;
				$list_all[$i]->title = '<a href="'.$link.'" title="Edit Category">'.stripslashes($row->title).'</a>';
			}
			$list_all[$i]->length = $row->video_length;
			$list_all[$i]->rating = $row->updated_rating;
			$list_all[$i]->views = $row->number_of_views;
			$list_all[$i]->access = hwd_vs_tools::generateVideoAccess($row->public_private);
			$list_all[$i]->date = $row->date_uploaded;
			$list_all[$i]->status = hwd_vs_tools::generateVideoStatus($row->approved);
			$list_all[$i]->published_task = $row->published ? 'unpublish' : 'publish';
			$list_all[$i]->published_img = $row->published ? 'publish_g.png' : 'publish_x.png';
			$list_all[$i]->featured_task = $row->featured ? 'unfeature' : 'feature';
			$list_all[$i]->featured_img =$row->featured ? 'publish_g.png' : 'publish_x.png';
			$list_all[$i]->approve_task = 'approve';
			$list_all[$i]->approve_img = 'publish_g.png';

			$list_all[$i]->k = $k;
			$list_all[$i]->i = $i;
			$k = 1 - $k;
		}
		$smartyvs->assign( "list_all", $list_all );

		/** display template **/
		$smartyvs->display('admin_approvals.tpl');
		return;
	}