Welcome Guest, Not a member yet? Register   Sign In
how to pass variiables from view to controller ??
#1

[eluser]aamiraziz[/eluser]

Respected helpers,

i am working on job portal. i have a problem in showing job details.

i displayed all the Jobs with few attributes of job table on one page for specific user (who has posted that jobs), and provide a link that if user like to view complete detail. i have written code:

<?php
echo "<tr>";
echo "<td> <b> Job Title </b> </td>";
echo "<td> <b> Job Department </b> </td>";
echo "<td> <b> Job Type </b> </td>";
echo "</tr>";

$i = 1;
foreach ($myjobs as $ti => $a){
echo "<tr>";
echo "<td>";
echo $a['title'];
echo "</td>";

echo "<td>";
echo $a['Dpt'];
echo "</td>";

echo "<td>";
echo $a['Type'];
echo "</td>";


$id[$i] = $a['JobID'];
$x= $id[$i];
$i++;



echo "<td>";

echo "<li class='register'><a href=";
echo site_url('jbcontroller/showjob/$x');

/* wrong page redirection $x is not allowed only value is allowed
i need to pass a variable here, in which JobID is stored so that i can retrieve it from database.
1) how can i do that ??
2) is there any alternate logic to to this type of task ??
please help me i'll be very thank full to you*/

echo">Show Job Detail</li>";

echo "</td>";
echo "</tr>";

echo "<br />";
echo "<br />";
}
?&gt;




pastebin link: http://pastebin.com/m50dff433[size=3]
[/size]


Messages In This Thread
how to pass variiables from view to controller ?? - by El Forum - 06-21-2009, 10:24 PM
how to pass variiables from view to controller ?? - by El Forum - 06-21-2009, 10:35 PM
how to pass variiables from view to controller ?? - by El Forum - 06-21-2009, 10:54 PM
how to pass variiables from view to controller ?? - by El Forum - 06-21-2009, 11:04 PM
how to pass variiables from view to controller ?? - by El Forum - 06-21-2009, 11:17 PM
how to pass variiables from view to controller ?? - by El Forum - 06-21-2009, 11:33 PM



Theme © iAndrew 2016 - Forum software by © MyBB