<?php 

$tickets = $this->getTickets("WHERE `gd_tickets`.`user_id` = {$_SESSION['user_id']}");

$this->view(array("theme/_common/_header", "theme/tickets/index", "theme/_common/_footer"), array("user" => $this->user, "shops" => $this->shops, "tickets" => $tickets)); 