Hi guys;
I am developing a website using joomla. and Im using Chrono Form and ChronoConnectivity extensions for form handling.
So using ChronoConnectivity and I am trying to display some form values. Of course no problem I can display that particular data by using ChronoConnectivity. but I need to display those data in two column.Actually those data containing Names.I need to put those name according their First name A to M in first column and N - Z names are second column
ex-
|Col A | Col B |
| A | N |
| B | O |
| C | P |
| . | . |
| . | . |
| M | Z |
I am try to use while loop for it.
<?php
//tabela select
$query2 = "SELECT * FROM `#__chronoconnectivity`" ;
$count = 1;
$column = 1;
//loop statement
while ($myrow = mysql_fetch_array ($query2))
{
// first column display
if ($column == 1)
{
//field is the column in table
printf('<div id="agency" class="agencylist"><a href="http://74.54.206.217/~oakpark/index.php?option=com_chronoconnectivity&connectionname=agencydet&cat_id={cf_id}">',$myrow['{text_2}</a></div>']);
//printf();
}
else{
//second column display
printf('<div id="agency" class="agencylist"><a href="http://74.54.206.217/~oakpark/index.php?option=com_chronoconnectivity&connectionname=agencydet&cat_id={cf_id}">',$myrow['{text_2}</a></div>']);
}
$count += 1;
$column = $count % 2;
}
//loop end
?>
I put this code block at under Body: in Connection View Settings.
So result is this error massage.
Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /../components/com_chronoconnectivity/libraries/connection.php(303) : eval()'d code on line 10
Ok I am agree with you here in my code I had lot of mistake.ok If can tell me either very better way to achieve this my requirement or other proper solution I am so glad.
cheers.
Umanda Jayo Bandara