Web Layout
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
 
User Name:
Password:
Remember me
Go Back   ASP Free ForumsWeb DesignWeb Layout

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 ASP Free Forums Sponsor:
  #1  
Old May 10th, 2006, 03:08 PM
dcampos's Avatar
dcampos dcampos is offline
Contributing User
ASP Free Newbie (0 - 499 posts)
 
Join Date: Aug 2004
Posts: 234 dcampos User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 2 Days 7 h 48 m 27 sec
Reputation Power: 5
Red face Hover Pop Up With Database Field

I would like to use Javascript to create a hover box that will pop up when I move over text. In addition to that, I want this hover box to contain information from a field in a database associated with the text that I am mousing over. Does anyone know of a tutorial that will show me how to do this?
__________________
"We're Gonna Need A Lot More Men." Davy Crockett

Reply With Quote
  #2  
Old June 26th, 2006, 09:02 PM
shamrog12's Avatar
shamrog12 shamrog12 is offline
Newton's Apple Wizard
ASP Free Intermediate (1500 - 1999 posts)
 
Join Date: Nov 2003
Location: Los Angeles
Posts: 1,661 shamrog12 User rank is Sergeant Major (2000 - 5000 Reputation Level)shamrog12 User rank is Sergeant Major (2000 - 5000 Reputation Level)shamrog12 User rank is Sergeant Major (2000 - 5000 Reputation Level)shamrog12 User rank is Sergeant Major (2000 - 5000 Reputation Level)shamrog12 User rank is Sergeant Major (2000 - 5000 Reputation Level)shamrog12 User rank is Sergeant Major (2000 - 5000 Reputation Level) 
Time spent in forums: 3 Weeks 2 Days 2 h 39 m 22 sec
Reputation Power: 34
Send a message via AIM to shamrog12
do a google search for Overlib. It can give you the javascript code to do exactly what you're looking for. Instead of having the hover box display text you can just make it display the value from a recordset instead.
__________________
If you found a post of mine helpful, please click on the on my post to add to my reputation.


Reply With Quote
  #3  
Old September 21st, 2006, 09:10 AM
asmoran asmoran is offline
ASPFree Know-It-All
ASP Free Novice (500 - 999 posts)
 
Join Date: Aug 2004
Posts: 930 asmoran User rank is Major (30000 - 40000 Reputation Level)asmoran User rank is Major (30000 - 40000 Reputation Level)asmoran User rank is Major (30000 - 40000 Reputation Level)asmoran User rank is Major (30000 - 40000 Reputation Level)asmoran User rank is Major (30000 - 40000 Reputation Level)asmoran User rank is Major (30000 - 40000 Reputation Level)asmoran User rank is Major (30000 - 40000 Reputation Level)asmoran User rank is Major (30000 - 40000 Reputation Level)asmoran User rank is Major (30000 - 40000 Reputation Level)asmoran User rank is Major (30000 - 40000 Reputation Level) 
Time spent in forums: 1 Week 2 Days 15 h 30 m 7 sec
Reputation Power: 325
Or you can just use the acronym tag.
Code:
<acronym title="World">Hello</acronym>

I take it you're dynamically adding the text to the page, so just add the title for the acronym as you're creating the text.

Reply With Quote
  #4  
Old September 21st, 2006, 01:21 PM
shamrog12's Avatar
shamrog12 shamrog12 is offline
Newton's Apple Wizard
ASP Free Intermediate (1500 - 1999 posts)
 
Join Date: Nov 2003
Location: Los Angeles
Posts: 1,661 shamrog12 User rank is Sergeant Major (2000 - 5000 Reputation Level)shamrog12 User rank is Sergeant Major (2000 - 5000 Reputation Level)shamrog12 User rank is Sergeant Major (2000 - 5000 Reputation Level)shamrog12 User rank is Sergeant Major (2000 - 5000 Reputation Level)shamrog12 User rank is Sergeant Major (2000 - 5000 Reputation Level)shamrog12 User rank is Sergeant Major (2000 - 5000 Reputation Level) 
Time spent in forums: 3 Weeks 2 Days 2 h 39 m 22 sec
Reputation Power: 34
Send a message via AIM to shamrog12
the only problem with the title attribute is that it doesn't appear immediately. it's a good poor man's overlib

Reply With Quote
  #5  
Old September 22nd, 2006, 06:34 AM
D.O.M.I.N.A.T.O.R's Avatar
D.O.M.I.N.A.T.O.R D.O.M.I.N.A.T.O.R is offline
Kingpin contributor
ASP Free Beginner (1000 - 1499 posts)
 
Join Date: Nov 2005
Location: P.E, RSA
Posts: 1,051 D.O.M.I.N.A.T.O.R User rank is First Lieutenant (10000 - 20000 Reputation Level)D.O.M.I.N.A.T.O.R User rank is First Lieutenant (10000 - 20000 Reputation Level)D.O.M.I.N.A.T.O.R User rank is First Lieutenant (10000 - 20000 Reputation Level)D.O.M.I.N.A.T.O.R User rank is First Lieutenant (10000 - 20000 Reputation Level)D.O.M.I.N.A.T.O.R User rank is First Lieutenant (10000 - 20000 Reputation Level)D.O.M.I.N.A.T.O.R User rank is First Lieutenant (10000 - 20000 Reputation Level)D.O.M.I.N.A.T.O.R User rank is First Lieutenant (10000 - 20000 Reputation Level)D.O.M.I.N.A.T.O.R User rank is First Lieutenant (10000 - 20000 Reputation Level) 
Time spent in forums: 1 Week 4 Days 2 h 12 m 16 sec
Reputation Power: 201
Quote:
Originally Posted by shamrog12
the only problem with the title attribute is that it doesn't appear immediately. it's a good poor man's overlib


The best way to achieve this is through CSS. I used it in a ASP.Net datagrid.

Code:
<asp:TemplateColumn>
						<ItemTemplate>
							<a class="info" href="#"><strong><%# DataBinder.Eval(Container.DataItem, "title") %></strong><SPAN><%# DataBinder.Eval(Container.DataItem, "description")%></span></a>
						</ItemTemplate>
					</asp:TemplateColumn>


CSS Code:
Original - CSS Code
  1. <STYLE>
  2.        a.info {
  3.             z-index: 24;
  4.             color: #000;
  5.             position: relative;
  6.             text-decoration: none;
  7.         }
  8.         a.info:hover {
  9.             z-index: 25;
  10.             background-color: #CCC;
  11.             color:#000;
  12.         }
  13.         a.info SPAN {
  14.             display: none
  15.         }
  16.         a.info:hover SPAN {
  17.             display: block;
  18.             left: 2em;
  19.             width: 15em;
  20.             color: #000;
  21.             border: #CCC 1px solid;
  22.             position: absolute;
  23.             top: 2em;
  24.             background-color: #D2D8E0;
  25.             text-align: left;
  26.             padding:3px;
  27.         }
  28.     </STYLE>


Jo.
__________________
Fitness & Diet resources Career Descriptions Boat Cruises
All code that is posted by me has not been tested, and it should only be interpreted as a guideline to a solution. There is no guarantee that any of my code samples will work as provided, and should be customized to suite the required need.

Reply With Quote
Reply

Viewing: ASP Free ForumsWeb DesignWeb Layout > Hover Pop Up With Database Field


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 6 hosted by Hostway
Stay green...Green IT