show one field above looped output table

Questions about the MySQL, PostgreSQL, and most other databases, as well as using it with PHP can be asked here.

Moderator: General Moderators

Post Reply
Nil10
Forum Newbie
Posts: 19
Joined: Thu Jun 30, 2005 1:55 pm

show one field above looped output table

Post by Nil10 »

Well my looped table works. To enter that page with all my data I have a startpage where all the seasondates I have is as links. When clicked the looped table shows only that specific season.
It is not a problem to also show the seasondate within the looped table, but there is no idea in that, when it ofcourse is the same all the way down.
So what I wish to do is show the seasondate above the looped table.

Can anyone point me in the right direction?
User avatar
pickle
Briney Mod
Posts: 6445
Joined: Mon Jan 19, 2004 6:11 pm
Location: 53.01N x 112.48W
Contact:

Post by pickle »

Wow - I have no idea what you're asking or what you're talking about. Could you explain your problem a little more, maybe post some relevant code?
Real programmers don't comment their code. If it was hard to write, it should be hard to understand.
Nil10
Forum Newbie
Posts: 19
Joined: Thu Jun 30, 2005 1:55 pm

Post by Nil10 »

Ok :D

I have this (index.php)

Code: Select all

<?

$username="???";
$password="???";
$database="???";

mysql_connect(localhost,$username,$password);
@mysql_select_db($database) or die("Unable to select database");

$query="SELECT Sæsoner.*, Områder.*, Hold.SæsonID
FROM (Områder INNER JOIN Sæsoner ON Områder.OmrådeID = Sæsoner.OmrådeID) INNER JOIN Hold ON Sæsoner.SæsonID = Hold.SæsonID GROUP BY Hold.SæsonID ORDER BY Sæsoner.SæsonID ASC;";

$result=mysql_query($query);

$num=mysql_numrows($result);

mysql_close();

?>

<table width="300px" border="1" cellspacing="0" cellpadding="2">
<tr>
<th><font face="Arial, Helvetica, sans-serif">Sæson periode</font></th>
<th><font face="Arial, Helvetica, sans-serif">Område</font></th>
</tr>

<?
$i=0;
while ($i < $num) {

$sæsonid=mysql_result($result,$i,"sæsonid");
$sæsonfra=mysql_result($result,$i,"sæsonfra");
$sæsontil=mysql_result($result,$i,"sæsontil");
$område=mysql_result($result,$i,"område");
$seasonstart = date('d-m-Y', strtotime($sæsonfra));
$seasonend = date('d-m-Y', strtotime($sæsontil));
?>

<tr>
<td align="center"><font face="Arial, Helvetica, sans-serif"><a href="undervisning.php?ssid=<? echo $sæsonid ?>&s2id=<? echo $sæsonid ?>" target="_self" Title="Vis sæsonperioden <? echo $seasonstart." - ".$seasonend; ?>"><? echo $seasonstart." - ".$seasonend; ?></a></font></td>
<td><font face="Arial, Helvetica, sans-serif"><? echo $område; ?></font></td>
</tr>

<?
$i++;
}

echo "</table>";

?>
and it outputs this:
Sæson periode Område
14-02-2005 - 04-06-2005 Sjælland
07-02-2005 - 29-05-2005 Jylland
When the date wich is a link is clicked I go to the next page:

Code: Select all

<?

$username="???";
$password="???";
$database="???";

mysql_connect(localhost,$username,$password);
@mysql_select_db($database) or die("Unable to select database");

$query="SELECT Byer.*, Hold.*, Lokaler.*, Minutterfra.*, Minuttertil.*, Niveauer.*, Områder.*, Priser.*, Stilarter.*, Sæsoner.*, Timerfra.*, Timertil.*, Ugedage.*, Undervisere.*
FROM Undervisere INNER JOIN (Ugedage INNER JOIN (Timertil INNER JOIN (Timerfra INNER JOIN ((Stilarter INNER JOIN (Priser INNER JOIN (Områder INNER JOIN (Niveauer RIGHT JOIN (Minuttertil INNER JOIN (Minutterfra INNER JOIN ((Byer INNER JOIN Lokaler ON Byer.ByID = Lokaler.ByID) INNER JOIN Hold ON Lokaler.LokaleID = Hold.LokaleID) ON Minutterfra.MinutterfraID = Hold.MinutterfraID) ON Minuttertil.MinuttertilID = Hold.MinuttertilID) ON Niveauer.NiveauID = Hold.NiveauID) ON Områder.OmrådeID = Byer.OmrådeID) ON Priser.PrisID = Områder.PrisID) ON Stilarter.StilartID = Hold.StilartID) INNER JOIN Sæsoner ON (Områder.OmrådeID = Sæsoner.OmrådeID) AND (Hold.SæsonID = Sæsoner.SæsonID)) ON Timerfra.TimerfraID = Hold.TimerfraID) ON Timertil.TimertilID = Hold.TimertilID) ON Ugedage.UgedagID = Hold.UgedagID) ON Undervisere.UnderviserID = Hold.UnderviserID;
WHERE ((Lokaler.LokaleID='$lkid' && Sæsoner.SæsonID='$ssid') || (Ugedage.UgedagID='$udid' && Sæsoner.SæsonID='$ssid') || (Stilarter.StilartID='$said' && Sæsoner.SæsonID='$ssid') || (Niveauer.NiveauID='$nvid' && Sæsoner.SæsonID='$ssid') || (Undervisere.UnderviserID='$uvid' && Sæsoner.SæsonID='$ssid') || (Sæsoner.SæsonID='$ssid' && Sæsoner.SæsonID='$s2id'))
ORDER BY Lokaler.LokaleID, Ugedage.UgedagID, Timerfra.Timerfra ASC";

$result=mysql_query($query);

$num=mysql_numrows($result);

mysql_close();

?>


//This following little table is what I need to work.
it should be the same date which is clicked on index.php,
for now it is just blank. I can see the logic in why it does not work,
cause it is outside the loop,
so another solution which I can't find is needed.


<table width="200px">
<tr>
<td align="right"><? echo $sæsonfra." - ".$sæsontil; ?></td>
</tr>
</table>
<table width="100%">
<tr>
	<td width="10px"></td>
	<td>
<table width="100%" border="0" cellspacing="0" cellpadding="2" class="sortable" id="1">
<tr>
<th align="left"><font face="Arial, Helvetica, sans-serif">Holdnr</font></th>
<th align="left"><font face="Arial, Helvetica, sans-serif">Stilart</font></th>
<th align="left"><font face="Arial, Helvetica, sans-serif">Niveau</font></th>
<th align="left"><font face="Arial, Helvetica, sans-serif">Tid</font></th>
<th align="left"><font face="Arial, Helvetica, sans-serif">Lokale</font></th>
<th align="left"><font face="Arial, Helvetica, sans-serif">Ugedag</font></th>
<th align="left"><font face="Arial, Helvetica, sans-serif">Underviser</font></th>
</tr>

<?
$i=0;
while ($i < $num) {

$sæsonfra=mysql_result($result,$i,"sæsonfra");
$sæsontil=mysql_result($result,$i,"sæsontil");
$sæsonid=mysql_result($result,$i,"sæsonid");
$holdnr=mysql_result($result,$i,"holdnr");
$timerfra=mysql_result($result,$i,"timerfra");
$minutterfra=mysql_result($result,$i,"minutterfra");
$timertil=mysql_result($result,$i,"timertil");
$minuttertil=mysql_result($result,$i,"minuttertil");
$alderfra=mysql_result($result,$i,"alderfra");
$aldertil=mysql_result($result,$i,"aldertil");
$niveau=mysql_result($result,$i,"niveau");
$niveauid=mysql_result($result,$i,"niveauid");
$stilartnavn=mysql_result($result,$i,"stilartnavn");
$stilartid=mysql_result($result,$i,"stilartid");
$lokale=mysql_result($result,$i,"lokale");
$lokaleid=mysql_result($result,$i,"lokaleid");
$ugedag=mysql_result($result,$i,"ugedag");
$ugedagid=mysql_result($result,$i,"ugedagid");
$undervisernavn=mysql_result($result,$i,"undervisernavn");
$underviserid=mysql_result($result,$i,"underviserid");
?>

<tr>
<td><font face="Arial, Helvetica, sans-serif"><? echo $holdnr; ?></font></td>
<td><font face="Arial, Helvetica, sans-serif"><a href="?ssid=<? echo $sæsonid ?>&said=<? echo $stilartid ?>" target="_self" Title="<? echo $stilartnavn; ?>"><? echo $stilartnavn; ?></a></font></td>
<td><font face="Arial, Helvetica, sans-serif"><? if ($niveauid=="0") {echo $alderfra." - ".$aldertil." år";} elseif ($alderfra=="0") {echo '<a href="?ssid=',$sæsonid,'&nvid=',$niveauid,'" target="_self" Title="',$niveau,'">',$niveau,'</a>';} else {echo $alderfra." - ".$aldertil." år, ".'<a href="?ssid=',$sæsonid,'&nvid=',$niveauid,'" target="_self" Title="',$niveau,'">',$niveau,'</a>';} ?></font></td>
<td><font face="Arial, Helvetica, sans-serif"><? echo $timerfra.":".$minutterfra." - ".$timertil.":".$minuttertil; ?></a></font></td>
<td><font face="Arial, Helvetica, sans-serif"><a href="?ssid=<? echo $sæsonid ?>&lkid=<? echo $lokaleid ?>" target="_self" Title="<? echo $lokale; ?>"><? echo $lokale; ?></a></font></td>
<td><font face="Arial, Helvetica, sans-serif"><a href="?ssid=<? echo $sæsonid ?>&udid=<? echo $ugedagid ?>" target="_self" Title="<? echo $ugedag; ?>"><? echo $ugedag; ?></a></font></td>
<td><font face="Arial, Helvetica, sans-serif"><a href="?ssid=<? echo $sæsonid ?>&uvid=<? echo $underviserid ?>" target="_self" Title="<? echo $undervisernavn; ?>"><? echo $undervisernavn; ?></a></font></td>
</tr>

<?
$i++;
}

echo "</table>";

?>
</td>
</tr>
</table>
User avatar
Burrito
Spockulator
Posts: 4715
Joined: Wed Feb 04, 2004 8:15 pm
Location: Eden, Utah

Post by Burrito »

1) you can loop over your query results much easier than the way you're doing it with a while loop over mysql_fetch_array or mysql_fetch_assoc...search this forum for those and you'll mind a million topics to choose from
2) if the date is being passed in the url, you can either use the $_GET[] array to display your date, or if you want to use the var you grab from the db and you only have one result, use a mysql_fetch_assoc to create an associative array and display your date from there ie: echo $row['date']. If you have multiple rows, you can use mysql_data_seek() to return the pointer back to the beginning of the array after you've displayed the date, or build a new array with the results and display the first key (or whatever key has your date).

most of that was shot from the hip as I still don't fully understand what your problem is 8O
Nil10
Forum Newbie
Posts: 19
Joined: Thu Jun 30, 2005 1:55 pm

Post by Nil10 »

Simplified (I hope) :D :

how can I output just one specific field from my database.

I need that for other information too, like showing teacher dicription above looped table, when a teachername is clicked, and looped table shows all the classes, that teacher has.
User avatar
pickle
Briney Mod
Posts: 6445
Joined: Mon Jan 19, 2004 6:11 pm
Location: 53.01N x 112.48W
Contact:

Post by pickle »

Are you trying to pass the dates on to the next page? If so, why not just make them GET variables in the URL?

Code: Select all

echo "<a href = 'newpage.php?date1=".$date1."&date2=".$date2.">";
Real programmers don't comment their code. If it was hard to write, it should be hard to understand.
Nil10
Forum Newbie
Posts: 19
Joined: Thu Jun 30, 2005 1:55 pm

Post by Nil10 »

Well that could be one solution but I am using this already to tell the looped table what to show

Code: Select all

<a href="undervisning.php?ssid=<? echo $sæsonid ?>&s2id=<? echo $sæsonid ?>" target="_self" ?></a>
The thing is that I also need to do the same with other things. And why send it with url when I already have the information from the database.
After reading burrito's post again I think thats maybe the solution, but I'll have to learn about it before I write back.
Nil10
Forum Newbie
Posts: 19
Joined: Thu Jun 30, 2005 1:55 pm

Post by Nil10 »

Well It were not the solution just better ways to do what I do already. If it works don't fix it. :D

But it suuddently hit me that this line $sæsonfra=mysql_result($result,$i,"sæsonfra"); is the important one and the $i is the field to get so if I am already sending the season id I just have to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=mysql_result($result,$ssid,"sæsonfra");
$sæsontil=mysql_result($result,$ssid,"sæsontil");
Now I just echo that information out above looped table. (stupid me)

Thanks for helping me help myself :D do what I do already. If it works don't fix it. :D

But it suuddently hit me that this line $sæsonfra=mysql_result($result,$i,"sæsonfra"); is the important one and the $i is the field to get so if I am already sending the season id I just have to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=mysql_result($result,$ssid,&quote;sæsonfra&quote;);
 fix it.  

But it suuddently hit me that this line $sæsonfra=mysql_result($result,$i,"sæsonfra"); is the important one and the $i is the field to get so if I am already sending the season id I just have to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=mysql_result($result,$ssid,"sæsonfra&ane $sæsonfra=mysql_result($result,$i,"sæsonfra"); is the important one and the $i is the field to get so if I am already sending the season id I just have to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=my hit me that this line $sæsonfra=mysql_result($result,$i,"sæsonfra"); is the important one and the $i is the field to get so if I am already sending the season id I just have to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=mysql_result($result,$ssid,"sæsonfra");
$sæsontil=mysql_result($result,$ssid,"sæsontil");
Now I just echo that information out above looped table. (stupid me)

Thanks for helping me help myself :Dhe solution just better ways to do what I do already. If it works don't fix it. :D

But it suuddently hit me that this line $sæsonfra=mysql_result($result,$i,"sæsonfra"); is the important one and the $i is the field to get so if I am already sending the season id I just have to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=mysql_result($result,$ssid,"sæsonfra");
$sæsontil=mysql_result($result,$ssid,"sæsontil");
Now I just echo that information out above loopehe solution just better ways to do what I do already. If it works don't fix it. :D

But it suuddently hit me that this line $sæsonfra=mysql_result($result,$i,"sæsonfra"); is the important one and the $i is the field to get so if I am already sending the season id I just have to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=mysql_result($result,$ssid,"sæsonfra");
$sæsontil=mysql_result($result,$ssid,"sæsontil");
Now I just echo that information out above looped table. (stupid me)

Thanks for helping me help myself :Dhelping me help myself :Dt fix it. :D

But it suuddently hit me that this line $sæsonfra=mysql_result($result,$i,"sæsonfra"); is the important one and the $i is the field to get so if I am already sending the season id I just have to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=mysql_result($result,$ssid,"sæsonfra");
$sæsontil=mysql_result($result,$ssid,"sæsontil");
Now I just echo that information out above looped table. (stupid me)

Thanks for helping me help myself :D suuddently hit me that this line $sæsonfra=mysql_result($result,$i,"sæsonfra"); is the important one and the $i is the field to get so if I am already sending the season id I just have to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=mysql_result($result,$ssid,"sæsonfra");
$sæsontil=mysql_result($result,$ssid, I do already. If it works don't fix it.  

But it suuddently hit me that this line $sæsonfra=mysql_result($result,$i,"sæsonfra"); is the important one and the $i is the field to get so if I am already sending the season id I just have to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=mysql_result($result,$ssid,"sæsonfra");
$sæsontil=mysql_result($result,$ssid,&quote;sæsontil&quote;);
Now I just echo that information out above looped table. (stupid me)

Thanks for helping me help myself :Done and the $i is the field to get so if I am already sending the season id I just have to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=mysql_result($result,$ssid,"sæsonfra");
$sæsontil=mysql_result($result,$ssid,"sæsontil");
Now I just echo that informab5ff83fa]$sæsonfra=mysql_result($result,$ssid,"sæsonfra");
$sæsontil=mysql_result($result,$ssid,"sæsontil");Now I just echo that information out above looped table. (stupid me)

Thanks for helping me help myself :Dust better ways to do what I do already. If it works don't fix it. :D

But it suuddently hit me that this line $sæsonfra=mysql_result($result,$i,"sæsonfra"); is the important one and the $i is the field to get so if I am already sending the season id I just have to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=mysql_result($result,$ssid,"sæsonfra");
$sæsontil=mysql_result($result,$ssid,"sæsontil");
Now I just echo that information out above looped table. (stupid me)

Thanks for helping me help myself :D the season id I just have to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=mysql_result($result,$ssid,"sæsonfra");
$sæsontil=mysql_result($result,$ssid,"sæsontil");
Now I just echo that information out above looped table. (stupid me)

Thanks for he_result($result,$ssid,"sæsonfra");
$sæsontil=mysql_result($result,$ssid,"sæsontil");Now I just echo that information out above looped table. (stupid me)

Thanks for helping me help myself :D$i is the field to get so if I am already sending the season id I just have to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=mysql_result($result,$ssid,"sæsonfra");
$sæsontil=mysql_result($result,$ssid,& to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=mysql_result($result,$ssid,"sæsonfra");
$sæsontil=mysql_result($result,$ssid,"sæsontil");
Now I just echo that information out above looped table. (stupid me)

Thanks for helping me help myself :Dtable. (stupid me)

Thanks for helping me help myself :Dhe solution just better ways to do what I do already. If it works don't fix it. :D

But it suuddently hit me that this line $sæsonfra=mysql_result($result,$i,"sæsonfra"); is the important one and the $i is the field to get so if I am already sending the season id I just have to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=mysql_result($result,$ssid,"sæsonfra");
$sæsontil=mysql_result($result,$ssid,"sæsontil");
Now I just echo that information out above looped table. (stupid me)

Thanks for helping me help myself :Duote;);
$sæsontil=mysql_result($result,$ssid,"sæsontil");Now I just echo that information out above looped table. (stupid me)

Thanks for helping me help myself :Dto do what I do already. If it works don't fix it. :D

But it suuddently hit me that this line $sæsonfra=mysql_result($result,$i,"sæsonfra"); is the important one and the $i is the field to get so if I am already sending the season id I just have to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=mysql_result($result,$ssid,"sæsonfra");
$sæsontil=mysql_result($result,$ssid,"sæsontil");
Now I just echo that information out above loope is the important one and the $i is the field to get so if I am already sending the season id I just have to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=mysql_result($result,$ssid,"sæsonfra");
$sæsontil=mysql_result($result,$ssid,"sæsontil");
Now I just echo that information out above looped table. (stupid me)

Thanks for helping me help myself :Ds to do what I do already. If it works don't fix it. :D

But it suuddently hit me that this line $sæsonfra=mysql_result($result,$i,"sæsonfra"); is the important one and the $i is the field to get so if I am already sending the season id I just have to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=mysql_result($result,$ssid,"sæsonfra");
$sæsontil=mysql_result($result,$ssid,&amso if I am already sending the season id I just have to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=mysql_result($result,$ssid,"sæsonfra");
$sæsontil=mysql_result($result,$ssid,"sæsontil");
Now I just echo that information out above looped table. (stupid me)

Thanks for helping me help myself :D the $i is the field to get so if I am already sending the season id I just have to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=mysql_result($result,$ssid,"sæsonfra");
$sæsontil=mysql_result($result,$ssid,"sæsontil");
Now I just echo thasontil=mysql_result($result,$ssid,"sæsontil");Now I just echo that information out above looped table. (stupid me)

Thanks for helping me help myself :Dphp]$sæsonfra=mysql_result($result,$ssid,"sæsonfra");
$sæsontil=mysql_result($result,$ssid,"sæsontil");Now I just echo that information out above looped table. (stupid me)

Thanks for helping me help myself :Dut it suuddently hit me that this line $sæsonfra=mysql_result($result,$i,"sæsonfra"); is the important one and the $i is the field to get so if I am already sending the season id I just have to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=mysql_result($result,$ssid,"sæsonfra");
$sæsontil=mysql_result($result,$ssid,"sæsontil");
Now I just echo that information out above looped table. (stupid me)

Thanks for helping me help myself :Dt better ways to do what I do already. If it works don't fix it. :D

But it suuddently hit me that this line $sæsonfra=mysql_result($result,$i,"sæsonfra"); is the important one and the $i is the field to get so if I am already sending the season id I just have to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=mysql_result($result,$ssid,"sæsonfra");
$sæsontil=mysql_result($result,$ssid,"sæsontil");
Now I just echo that information out above looped table. (stupid me)

Thanks for helping me help myself :Dlt($result,$ssid,"sæsonfra");
$sæsontil=mysql_result($result,$ssid,"sæsontil");Now I just echo that information out above looped table. (stupid me)

Thanks for helping me help myself :Dhe solution just better ways to do what I do already. If it works don't fix it. :D

But it suuddently hit me that this line $sæsonfra=mysql_result($result,$i,"sæsonfra"); is the important one and the $i is the field to get so if I am already sending the season id I just have to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=mysql_result($result,$ssid,"sæsonfra");
$sæsontil=mysql_result($result,$ssid,"sæsontil");
Now I just echo that informatioand the $i is the field to get so if I am already sending the season id I just have to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=mysql_result($result,$ssid,"sæsonfra");
$sæsontil=mydy. If it works don't fix it.  

But it suuddently hit me that this line $sæsonfra=mysql_result($result,$i,"sæsonfra"); is the important one and the $i is the field to get so if I am already sending the season id I just have to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=mysql_result($result,$ssid,&quote;sæsonfra&quote;);
$sæsontil=mysql_result($result,$ssid,&quote;sæsontil&quote;);
Now I just echo that information out above looped table. (stupid me)

Thanks for helping me help myself :onfra"); is the important one and the $i is the field to get so if I am already sending the season id I just have to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=mysql_result($result,$ssid,"sæsonfra");
$sæsontil=mysql_result($result,$ssid,"sæsontil");
Now I just echo that information out above looped table. (stupid me)

Thanks for helping me help myself :Dhe solution just better ways to do what I do already. If it works don't fix it. :D

But it suuddently hit me that this line $sæsonfra=mysql_result($result,$i,"sæsonfra"); is the important one and the $i is the field to get so if I am already sending the season id I just have to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=mysql_result($result,$ssid,&quote;sæsonfra&quote;);
$sæsontil=mysql_result($result,$ssid,&q the important one and the $i is the field to get so if I am already sending the season id I just have to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=mysql_result($result,$ssid,&quote;sæsonfra&quote;);
$sæsontil=mysql_result($result,$ssid,&quote;sæsontil&quote;);
Now I just echo that information out above looped table. (stupid me)

Thanks for helping me help myself :Dresult($result,$i,"sæsonfra"); is the important one and the $i is the field to get so if I am already sending the season id I just have to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=mysql_result($result,$ssid,"sæsonfra");
$sæsontil=mysql_result($result,$ssid,"sæsontil");
Now I just echo that information out above looped table. (stupid me)

Thanks for helping me help myself :D
Thanks for helping me help myself :Dlt,$ssid,"sæsonfra");
$sæsontil=mysql_result($result,$ssid,"sæsontil");Now I just echo that information out above looped table. (stupid me)

Thanks for helping me help myself :Dsæsonfra"); is the important one and the $i is the field to get so if I am already sending the season id I just have to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=mysql_result($result,$ssid,"sæsonfra");
$sæsontil=mysql_result($result,$ssid,"sæsontil");
Now I just echo that information out above looped table. (stupid me)

Thanks for helping me help myself :Dhe solution just better ways to do what I do already. If it works don't fix it. :D

But it suuddently hit me that this line $sæsonfra=mysql_result($result,$i,"sæsonfra"); is the important one and the $i is the field to get so if I am already sending the season id I just have to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=mysql_result($result,$ssid,"sæsonfra");
$sæsontil=mysql_result($result,$ssid,"sæsontil");
Now I just echo that information out above looped table. (stupid me)

Thanks ks don't fix it. :D

But it suuddently hit me that this line $sæsonfra=mysql_result($result,$i,"sæsonfra"); is the important one and the $i is the field to get so if I am already sending the season id I just have to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=mysql_result($result,$ssid,"sæsonfra");
$sæsontil=mysql_reways to do what I do already. If it works don't fix it.  

But it suuddently hit me that this line $sæsonfra=mysql_result($result,$i,"sæsonfra"); is the important one and the $i is the field to get so if I am already sending the season id I just have to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=mysql_result($result,$ssid,"sæsonfra");
$sæsontil=mysql_result($result,$ssid,"sæsontil");
Now I just echo that information out above looped table. (stupid me)

Thanks for helping me help myself :D);
$sæsontil=mysql_result($result,$ssid,"sæsontil");Now I just echo that information out above looped table. (stupid me)

Thanks for helping me helesult,$i,"sæsonfra"); is the important one and the $i is the field to get so if I am already sending the season id I just have to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=mysql_result($result,$ssid,&quote;sæsonfra&quote;);
$sæsontil=mysqlt me that this line $sæsonfra=mysql_result($result,$i,"sæsonfra"); is the important one and the $i is the field to get so if I am already sending the season id I just have to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=mysql_result($result,$ssid,"sæsonfra");
$sæsontil=mysql_result($result,$ssid,"sæsontil");
Now I just echo that information out above looped table. (stupid me)

Thanks for helping me help myself :Dto do what I do already. If it works don't fix it. :D

But it suuddently hit me that this line $sæsonfra=mysql_result($result,$i,"sæsonfra"); is the important one and the $i is the field to get so if I am already sending the season id I just have to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=mysql_result($result,$ssid,"sæsonfra");
$sæsontil=mysql_result($result,$ssid,"sæsontil");
Now I just echo that information out above looped table. (stupid me)

Thanks for helping me help myself :Di,"sæsonfra"); is the important one and the $i is the field to get so if I am already sending the season id I just have to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=mysql_result($result,$ssid,&quote;sæsonfra&quote;)  

But it suuddently hit me that this line $sæsonfra=mysql_result($result,$i,"sæsonfra"); is the important one and the $i is the field to get so if I am already sending the season id I just have to move those two lines above the loop and write them like this.

Code: Select all

$sæsonfra=mysql_result($result,$ssid,"sæsonfra");
$sæsontil=mysql_result($result,$ssid,"sæsontil");
Now I just echo that information out above looped table. (stupid me)

Thanks for helping me help myself :Dra");
$sæsontil=mysql_result($result,$ssid,"sæsontil");Now I just echo that information out above looped table. (stupid me)

Thanks for helping me help myself :D$sæsonfra=mysql_result($result,$ssid,"sæsonfra");
$sæsontil=mysql_result($result,$ssid,"sæsontil");Now I just echo that information out above looped table. (stupid me)

Thanks for helping me help myself :D
Post Reply