Jump to content

Klein_Kipje

New Members
  • Posts

    5
  • Joined

  • Last visited

Klein_Kipje's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. I have programmed in php / mysql but i teached myself. So to begin this i just wanted to asked your opion how to approach it
  2. I do not have code yet, i just want a general idea how to get started. I have a database with +/- 15 columns. 6 people are using this database. Not all columns are relevant for each user. So my idea was that each user will be able to make his preference by checking checkboxes for each column -> store this in the database so that when he logs in , his preference will be retrieved and used to make the right query. second question, how do i make the headers so that they are the same als the preferences from the user ? Just put me on the right track (or if someone has it on the shelf, post the code) thanks in advance
  3. Would it be possible that you put your solution in my code, because it goes i little above my head.
  4. I mean a sql result table its to create a timetable now i have every event on the same left allign like a normal sql table its has 3 locations and my idea was to allign every location different to make it more easy viewable This is the code so far, the <td class = "'.$NewClass.'"> makes the table cell a different color depending on the location $result = mysql_query($sql) or die(mysql_error()); $begin = strtotime('13:00'); echo'<table>'; while($row = mysql_fetch_array($result)) { $PODIUM = $row['PODIUM']; if ($row['PODIUM'] == 1) { $NewClass = "JA" ; } elseif ($row['PODIUM'] == 2) { $NewClass = "NEE"; } elseif ($row['PODIUM'] == 3) { $NewClass = "MISSCHIEN"; } $duur = $row['DUUR']; $end = strtotime("+ $duur minutes", $begin); echo'<tr> <td class = "'.$NewClass.'">'.$row['POSITIE'].'</td> <td class = "'.$NewClass.'">'.$row['NAAMBAND'].'</td> <td class = "'.$NewClass.'">'; if($PODIUM == 1){ echo "<div class='item'><label>Hoofdpodium</label></div>"; }; if($PODIUM == 2){ echo "<div class='item'><label>DJ Toren</label></div>"; }; if($PODIUM == 3){ echo "<div class='item'><label>Talentstage</label></div>"; }; echo'<td class = "'.$NewClass.'">'.$row['DUUR'].'</td> <td class = "'.$NewClass.'">'.date('H:i', $begin).'</td> <td class = "'.$NewClass.'">'.date('H:i', $end).'</td> '; echo'</tr>'; $begin = $end; } echo'</table>'; ?>
  5. I googled myself lame to find out, but no luck. Is it possible to allign every row in a sql result table different. And i mean, not the text but the whole row. 01 | ** | ** | left 02 | ** | ** | center 03 | ** | ** | right 04 | ** | ** | center 05 | ** | ** | left depending of the value of one of the cell in that row. I'm able to assign a different class to <TD> to change color of the cell (or whatever) depending on that value. Is it possible at all to allign rows different from each other ?
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.