Solved

MySQL newbie....

Posted on 2002-04-10
4
206 Views
Last Modified: 2006-11-17
I am a complete novice at MySQl, and really all I want to do is:

-> Connect to the db server.
-> Select a db.
-> Select a message to print to the user based on an id supplied to the script via the query string. ie /script.php?id=1 .

I have set up a MySQL table called 'txts', and this table has three fields: 'id', 'heading', and 'message'.

Firstly, I want to display a page which lists all the messages available, in a table like this:

-------------------------------------
| Message Heading (field 'heading') |
-------------------------------------
| The actual message |
| (field 'message') |
-------------------------------------
| A link to another page giving the |
| message id via the query string |
| (using the 'id' field) |
-------------------------------------

Then, on the next page, I would like to be able to put the message into a variable ($message) which I can use later on.... the message will be selected from the table using the ?id= parameter to get the right message.

I know that this is a lot to ask, but can anyone give advice on how to do this. I will be extremely grateful for any help at all.

Thanks,
Nick!
0
Comment
Question by:Nick50000
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 4

Expert Comment

by:lokeshv
ID: 6932967
lot in just 10 points ? :-)
0
 

Author Comment

by:Nick50000
ID: 6934509
yeah sorry, I don't have any more... hey tell you wot - i'll re-register and get some more.....
0
 

Accepted Solution

by:
Nick500000 earned 15 total points
ID: 6934604
I have posted the question again but with A LOT more points! Question title: MySQL and PHP question!
0
 
LVL 4

Expert Comment

by:lokeshv
ID: 6934671
you have got the ans..there ..check

Lk :o)
0

Featured Post

WordPress Tutorial 4: Recommended Plugins

Now that you have WordPress installed, understand the interface, and know how to install new parts, let’s take a look at our recommended plugins.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

These days socially coordinated efforts have turned into a critical requirement for enterprises.
3 proven steps to speed up Magento powered sites. The article focus is on optimizing time to first byte (TTFB), full page caching and configuring server for optimal performance.
The viewer will learn how to dynamically set the form action using jQuery.
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …

626 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question