Welcome Guest, Not a member yet? Register   Sign In
selecting data from 2 tables
#9

[eluser]Bigil Michael[/eluser]
i want to display the person with maximum votes as result

so i changed my controller
Quote:function index($pgoffset=’‘)
{
$config[‘per_page’] = 9;

$this->data[‘pagetitle’] =‘Election Results’;

$build_array = array();
$fleets = $this->Election_result_model->select_constituency($config[‘per_page’], $pgoffset);

foreach($fleets as $row){
$build_array[] = array (
‘fleets_array’ => $row,
‘listefleets_array’ => $this->Election_result_model->list_constituency($row[‘constituency_id’])
);
}
$this->data[‘meow’] = $build_array;

$this->load->view(‘election_result’,$this->data);
}

to
Quote:function index($pgoffset='')
{
$config['per_page'] = 9;

$this->data['pagetitle'] ='Election Results';

$build_array = array();
$fleets = $this->Election_result_model->select_constituency($config['per_page'], $pgoffset);

foreach($fleets as $row){
$build_array[] = array (
'fleets_array' => $row,
'listefleets_array' => $this->Election_result_model->list_constituency($row['constituency_id'],
'winner' => $this->Election_result_model->select_winner($row['constituency_id'],$row['elect_year'])
);
}
$this->data['meow'] = $build_array;

$this->load->view('election_result',$this->data);
}

it shows parse error
can anyone help me
urgent...
thanks in advance.......


Messages In This Thread
selecting data from 2 tables - by El Forum - 04-16-2011, 12:43 AM
selecting data from 2 tables - by El Forum - 04-16-2011, 01:00 AM
selecting data from 2 tables - by El Forum - 04-16-2011, 01:09 AM
selecting data from 2 tables - by El Forum - 04-16-2011, 01:24 AM
selecting data from 2 tables - by El Forum - 04-16-2011, 01:30 AM
selecting data from 2 tables - by El Forum - 04-16-2011, 01:49 AM
selecting data from 2 tables - by El Forum - 04-16-2011, 02:21 AM
selecting data from 2 tables - by El Forum - 04-16-2011, 03:24 AM
selecting data from 2 tables - by El Forum - 04-16-2011, 03:46 AM
selecting data from 2 tables - by El Forum - 04-16-2011, 03:48 AM
selecting data from 2 tables - by El Forum - 04-16-2011, 04:03 AM
selecting data from 2 tables - by El Forum - 04-16-2011, 04:07 AM
selecting data from 2 tables - by El Forum - 04-16-2011, 04:15 AM
selecting data from 2 tables - by El Forum - 04-16-2011, 04:23 AM
selecting data from 2 tables - by El Forum - 04-16-2011, 04:41 AM
selecting data from 2 tables - by El Forum - 04-16-2011, 04:51 AM
selecting data from 2 tables - by El Forum - 04-16-2011, 04:52 AM
selecting data from 2 tables - by El Forum - 04-16-2011, 05:09 AM
selecting data from 2 tables - by El Forum - 04-16-2011, 05:56 AM
selecting data from 2 tables - by El Forum - 04-16-2011, 06:12 AM
selecting data from 2 tables - by El Forum - 04-16-2011, 06:25 AM
selecting data from 2 tables - by El Forum - 04-16-2011, 06:33 AM
selecting data from 2 tables - by El Forum - 04-16-2011, 06:38 AM
selecting data from 2 tables - by El Forum - 04-16-2011, 06:47 AM
selecting data from 2 tables - by El Forum - 04-18-2011, 12:34 AM
selecting data from 2 tables - by El Forum - 04-18-2011, 12:44 AM
selecting data from 2 tables - by El Forum - 04-18-2011, 12:51 AM
selecting data from 2 tables - by El Forum - 04-18-2011, 01:01 AM
selecting data from 2 tables - by El Forum - 04-18-2011, 01:03 AM
selecting data from 2 tables - by El Forum - 04-18-2011, 01:07 AM
selecting data from 2 tables - by El Forum - 04-18-2011, 01:09 AM
selecting data from 2 tables - by El Forum - 04-18-2011, 01:10 AM
selecting data from 2 tables - by El Forum - 04-18-2011, 01:17 AM
selecting data from 2 tables - by El Forum - 04-18-2011, 01:23 AM
selecting data from 2 tables - by El Forum - 04-18-2011, 01:29 AM
selecting data from 2 tables - by El Forum - 04-18-2011, 01:38 AM
selecting data from 2 tables - by El Forum - 04-18-2011, 01:45 AM
selecting data from 2 tables - by El Forum - 04-18-2011, 02:28 AM
selecting data from 2 tables - by El Forum - 04-18-2011, 02:40 AM
selecting data from 2 tables - by El Forum - 04-18-2011, 02:45 AM
selecting data from 2 tables - by El Forum - 04-18-2011, 03:04 AM
selecting data from 2 tables - by El Forum - 04-18-2011, 03:11 AM
selecting data from 2 tables - by El Forum - 04-18-2011, 03:15 AM
selecting data from 2 tables - by El Forum - 04-18-2011, 03:16 AM
selecting data from 2 tables - by El Forum - 04-18-2011, 03:22 AM
selecting data from 2 tables - by El Forum - 04-18-2011, 03:23 AM
selecting data from 2 tables - by El Forum - 04-18-2011, 03:25 AM
selecting data from 2 tables - by El Forum - 04-18-2011, 03:31 AM
selecting data from 2 tables - by El Forum - 04-18-2011, 03:33 AM
selecting data from 2 tables - by El Forum - 04-18-2011, 03:53 AM
selecting data from 2 tables - by El Forum - 04-18-2011, 04:52 AM
selecting data from 2 tables - by El Forum - 04-18-2011, 05:09 AM
selecting data from 2 tables - by El Forum - 04-18-2011, 10:44 PM
selecting data from 2 tables - by El Forum - 04-19-2011, 06:11 AM



Theme © iAndrew 2016 - Forum software by © MyBB