Solved

Link in MYSQL

Posted on 2004-04-02
3
233 Views
Last Modified: 2010-04-17
Hi,

I am trying to write a program in PHP and MYQL, which in this program, after geting the information from Database which one one the field of Database is Link to some other pages.

How can I get this link from Database field and visitor be able to click on the link?

Thank you,
M G
0
Comment
Question by:Mohamad_111
[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
3 Comments
 

Accepted Solution

by:
strolfey earned 125 total points
ID: 10746740
I'm a bit confused. Do you mean how do you make the data linkable?

<?php
$query="SELECT link, text FROM table";
$result=mysql_query($query);
while( $data=mysql_fetch_array($result) ) {
  echo "<a href=\"" . $data["link"] . "\">" . $data["text"] . "</a><br>\n";
}
?>

something like that..?
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
ejb stateless example 2 69
Selenium and Interactive Data Language 3 78
C qsort compare function issue 6 70
C# Windows Form Navigation - Total Beginner 9 96
This article is meant to give a basic understanding of how to use R Sweave as a way to merge LaTeX and R code seamlessly into one presentable document.
In this post we will learn different types of Android Layout and some basics of an Android App.
An introduction to basic programming syntax in Java by creating a simple program. Viewers can follow the tutorial as they create their first class in Java. Definitions and explanations about each element are given to help prepare viewers for future …

710 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