SunQuest
 
      SQL Basics
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Tutorialized ForumsDatabasesSQL Basics

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Tutorialized Forums Sponsor:
  #1  
Old July 21st, 2004, 05:38 PM
meat meat is offline
Contributing User
Tutorialized Newbie (0 - 499 posts)
 
Join Date: Jun 2004
Location: San Diego
Posts: 156 meat New User: is a brand new recruit and a unknown entity at this point. 
Time spent in forums: 11 m 16 sec
Reputation Power: 0
Send a message via AIM to meat Send a message via Skype to meat
SQL tutorial description prob

Hello, I am working on a tutorial site as most of you might know. I have a sql database set with pretty much everything working. But I am trying to find way in order to make a new <td> in php. Lemme go into farther detail:

The sql database connects and finds tutorial descriptions for the category given. It then displays info in a new <td>.

So, if the descriptions it finds equals 2, it creates 2 td's and fills the given areas. now is this even possible. Or am I over my head?
__________________
Mwahaha, Eat meat!!

Runescape Database

Reply With Quote
  #2  
Old July 21st, 2004, 07:24 PM
Acecool Acecool is offline
Senior Member
Tutorialized Newbie (0 - 499 posts)
 
Join Date: Jul 2004
Posts: 117 Acecool New User: is a brand new recruit and a unknown entity at this point. 
Time spent in forums: < 1 sec
Reputation Power: 0
Im not really understanding you correctly, you mean make a new table td?

if so, Im sure its possible but would need more information like the query / loop etc.
__________________

If you plan on contacting me, please read this: Legal Terms & Conditions

Reply With Quote
  #3  
Old July 22nd, 2004, 03:00 AM
meat meat is offline
Contributing User
Tutorialized Newbie (0 - 499 posts)
 
Join Date: Jun 2004
Location: San Diego
Posts: 156 meat New User: is a brand new recruit and a unknown entity at this point. 
Time spent in forums: 11 m 16 sec
Reputation Power: 0
Send a message via AIM to meat Send a message via Skype to meat
Ok, imma try to explain. I kinda rushed it. Here we go:

I want to have a page where a SQL database selects categorys and the descriptions for the tutorials contained in the category. It selects it by the following code.

Code:
SELECT * FROM tut_descr WHERE tut_cat='$cat' LIMIT 30


Now, I am pretty sure that will work. Now how would I show each of the rows selected in seperate td's ?

Reply With Quote
  #4  
Old July 22nd, 2004, 04:51 AM
Acecool Acecool is offline
Senior Member
Tutorialized Newbie (0 - 499 posts)
 
Join Date: Jul 2004
Posts: 117 Acecool New User: is a brand new recruit and a unknown entity at this point. 
Time spent in forums: < 1 sec
Reputation Power: 0
while ($row = mysql_fetch_assoc(mysql_query($query))) {
echo $row['id']
}

would echo all ids etc.

id is a column name, you can put html in there and put the $row['****'] in between to show in different areas etc.

Reply With Quote
Reply

Viewing: Tutorialized ForumsDatabasesSQL Basics > SQL tutorial description prob


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 1 hosted by Hostway