Jump to content

Dynamic tooltip with a mysql result.


skatermike21988

Recommended Posts

Ok, i have a mysql query with a loop, and with what is displayed i am wanting a dynamic tooltip to be displayed, well i can get the tooltip to display but for every thing that is displayed from the query i am only getting the first to be pulled. for example:


say first to be shown is a user by the name of rickie: tooltip shows: Name: Rickie Something etc...

second to be shown is say billy joe: tooltip shows: Name: Rickie Something etc...

get what i am saying???
Link to comment
Share on other sites

Would something like this do what you want? [code]<?php
$result = mysql_query("SELECT * FROM users");
while($user = mysql_fetch_assoc($result)
{
echo "<a href='index.php?profile={$user['id']}' title='{$user['real_name']}'>{$user['username']}</a><br />";
}
?>[/code]
Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.