Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

PHP Forum


You are currently viewing our PHP Forum as a guest. Please register to participate.
Login



Freelance Jobs

Reply
Display Table Data from SQL Using ID
Old 08-23-2010, 02:10 AM Display Table Data from SQL Using ID
Junior Talker

Posts: 3
Name: Brad Potts
Location: Canada
Trades: 0
I'm developing my own site displaying large amounts of car specs, I will eventually provide data for all cars. I'mm looking at a mountain of data and need to scale quickly.


So far I've been writing plain html tables like this, an example of a block of information. I've been manually using this method like I have been would take way to long for me to get anywhere.

<table class="tittlebar"><tr><td><h2>Manufacture Information</h2></td></tr></table>
<table class="cardata">
<tr class="cardataeditions"><td class ="tittle">Brand</td><td class ="specs">Audi</td><td class ="specs">Audi</td></tr>
<tr class="cardataeven"><td class ="tittle">Model</td><td class ="specs">A6 4-Door Saloon</td><td class ="specs">A6 4-Door Saloon</td></tr>
<tr class="cardataodd"><td class ="tittle">Edition</td><td class ="specs">2.0 TFSI LeMans</td><td class ="specs">2.0 TDI 170 LeMans</td></tr>
</table>

I've been looking for a efficient way to display tables, I want my webpages
to load fast and be compatible with droid and iphones. I run my site off wordpress with php execusion based on a thesis template.

I would like to call up and print tables like the method above but using php to print the specs from sql databases.

<table class="tittlebar"><tr><td><h2>Manufacture Information</h2></td></tr></table>
<table class="cardata">
<tr class="cardataeditions"><td class ="tittle">Brand</td><td class ="specs">sqldata</td><td class ="specs">sqldata</td></tr>
<tr class="cardataeven"><td class ="tittle">Model</td><td class ="specs">sqldata</td><td class ="specs">sqldata</td></tr>
<tr class="cardataodd"><td class ="tittle">Edition</td><td class ="specs">sqldata</td><td class ="specs">sqldata</td></tr>
</table>

I would like some thoughts I'm really open to anything new, or anyother suggestions. I looked a json and xml as well, and I'm willing to utilize mootools or jquery.

statisiticar.com for a view of how data is displayed so far. Open for comments about my site design in general as well. This maybe a no brainer for some.... but I'm truly stuck on this barrier.

regards

Last edited by bradpotts; 08-23-2010 at 02:12 AM..
bradpotts is offline
Reply With Quote
View Public Profile Visit bradpotts's homepage!
 
 
Register now for full access!
Old 08-23-2010, 06:35 AM Re: Display Table Data from SQL Using ID
Extreme Talker

Posts: 181
Name: David Jackson
Trades: 0
you should OO (Object Orientate) this project

If the data is stored in the same set of fields then you could write a method to display the data and just call it again and again passing in the record ID as an argument
__________________

Please login or register to view this content. Registration is FREE
davidj is offline
Reply With Quote
View Public Profile
 
Old 08-23-2010, 09:22 PM Re: Display Table Data from SQL Using ID
Junior Talker

Posts: 3
Name: Brad Potts
Location: Canada
Trades: 0
Thanks I tried a few scripts already. But I'm not satisfied with what I came up with so far, I'm pretty sure I was using procedural scripts.

Are you able to give a link to an example or a tutorial. I usually go and find samples than reverse engineer it myself. I tried google searches and read plenty of theory but nothing specific to my problem.

Thanks for your reply and pointing me into a direction. I'll keep searching. I have a good feeling this will solve my problem.
bradpotts is offline
Reply With Quote
View Public Profile Visit bradpotts's homepage!
 
Old 08-23-2010, 11:34 PM Re: Display Table Data from SQL Using ID
Junior Talker

Posts: 3
Name: Brad Potts
Location: Canada
Trades: 0
http://www.gotapi.com/php/php_object...tutorials.html
this is what I found so far I'll post my code once I figure it out.
bradpotts is offline
Reply With Quote
View Public Profile Visit bradpotts's homepage!
 
Reply     « Reply to Display Table Data from SQL Using ID
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.27451 seconds with 12 queries