Displaying Records Question.
7 posts by 2 authors in: Forums > CMS Builder
Last Post: January 22, 2009 (RSS)
By JoeKMT - January 21, 2009
Thanks!
Re: [JoeKMT] Displaying Records Question.
By Dave - January 21, 2009
The first step is to create a mockup of how you want the schedule to look. Do you have a mockup that you can post the url to and/or can you attach your current viewer file?
It really depends on the layout of your page and setup of your section but you can check for records like this:
<?php if ($record): ?>
Display record content
<?php endif ?>
<?php if (!$record): ?>
There is no record.
<?php endif ?>
Hope that helps!
interactivetools.com
Re: [Dave] Displaying Records Question.
By JoeKMT - January 21, 2009
I have also uploaded the viewer code.
Thanks for your fast response.
Joe
Re: [JoeKMT] Displaying Records Question.
By Dave - January 22, 2009
Are you using a single record or multi record section?
Looks like that link is gone but you can try something like this:
<?php if ($record['wedclass1']): ?>
<tr>
<td>Wednesday</td>
<td><?php $record['wedtime1'] ?></td>
<td><?php $record['wedclass1'] ?></td>
</tr>
<?php endif ?>
<?php if ($record['wedclass2']): ?>
<tr>
<td> </td>
<td><?php $record['wedtime2'] ?></td>
<td><?php $record['wedclass2'] ?></td>
</tr>
<?php endif ?>
...etc...
Let me know if that works for you.
interactivetools.com
Re: [Dave] Displaying Records Question.
By JoeKMT - January 22, 2009
http://irvine.directrouter.com/~alternat/pages/schedule.php
I think I understand the code you posted, it adds the table cells if there is a record to post, could still take a look at the link, let me know if you see anything wrong.
Thanks,
Joe
Re: [JoeKMT] Displaying Records Question.
By Dave - January 22, 2009
interactivetools.com
Re: [Dave] Displaying Records Question.
By JoeKMT - January 22, 2009
Joe