473,903 Members | 3,317 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Problems with "Rich HTML Balloon Tooltip"

mikek12004
200 New Member
1) Script Title: Rich HTML Balloon Tooltip

2) Script URL :http://www.dynamicdrive.com/dynamici...oontooltip.htm

3) Problem Description:
See this page
General Music
for links you can see without scrolling down the div the tooltip is shown at the desired place but when you scroll donw the div the tooltip's position gets all messed up, e.g in the last "ΤΙΤΛΟΣ ALBUM" (which means Title of album ) the tooltip gets in front of the link and so the user cannot press the link!
Thous far it has proven a very neat easy to implement script which has added a lot visually to my site, for anyone capable of thinking some modification to overcome the div problem any suggestions?
Many thanks for your time
Nov 25 '08 #1
8 4349
acoder
16,027 Recognized Expert Moderator MVP
You need to add scrollTop into the equation. See Element Dimensions.
Nov 25 '08 #2
mikek12004
200 New Member
Should I add or substract the scrollTop property and from which lines?
Apologise for the trouble but do not know much of Javascript plus the code is not mine, for convinience I have posted the js below.
Expand|Select|Wrap|Line Numbers
  1. //Rich HTML Balloon Tooltip: http://www.dynamicdrive.com/dynamicindex5/balloontooltip.htm
  2. //Created: September 10th, 2006
  3.  
  4. var disappeardelay=250  //tooltip disappear delay (in miliseconds)
  5. var verticaloffset=0 //vertical offset of tooltip from anchor link, if any
  6. var enablearrowhead=1 //0 or 1, to disable or enable the arrow image
  7. var arrowheadimg=["images/arrowdown.gif", "images/arrowup.gif"] //path to down and up arrow images
  8. var arrowheadheight=14 //height of arrow image (amount to reveal)
  9.  
  10. /////No further editting needed
  11.  
  12. var ie=document.all
  13. var ns6=document.getElementById&&!document.all
  14. verticaloffset=(enablearrowhead)? verticaloffset+arrowheadheight : verticaloffset;
  15.  
  16. function getposOffset(what, offsettype){
  17. var totaloffset=(offsettype=="left")? what.offsetLeft : what.offsetTop;
  18. var parentEl=what.offsetParent;
  19. while (parentEl!=null){
  20. totaloffset=(offsettype=="left")? totaloffset+parentEl.offsetLeft : totaloffset+parentEl.offsetTop;
  21. parentEl=parentEl.offsetParent;
  22. }
  23. return totaloffset;
  24. }
  25.  
  26. function showhide(obj, e){
  27. dropmenuobj.style.left=dropmenuobj.style.top="-500px"
  28. if (e.type=="mouseover")
  29. obj.visibility="visible"
  30. }
  31.  
  32. function iecompattest(){
  33. return (document.compatMode && document.compatMode!="BackCompat")? document.documentElement : document.body
  34. }
  35.  
  36. function clearbrowseredge(obj, whichedge){
  37. if (whichedge=="rightedge"){
  38. edgeoffsetx=0
  39. var windowedge=ie && !window.opera? iecompattest().scrollLeft+iecompattest().clientWidth-15 : window.pageXOffset+window.innerWidth-15
  40. dropmenuobj.contentmeasure=dropmenuobj.offsetWidth
  41. if (windowedge-dropmenuobj.x < dropmenuobj.contentmeasure)
  42. edgeoffsetx=dropmenuobj.contentmeasure-obj.offsetWidth
  43. return edgeoffsetx
  44. }
  45. else{
  46. edgeoffsety=0
  47. var topedge=ie && !window.opera? iecompattest().scrollTop : window.pageYOffset
  48. var windowedge=ie && !window.opera? iecompattest().scrollTop+iecompattest().clientHeight-15 : window.pageYOffset+window.innerHeight-18
  49. dropmenuobj.contentmeasure=dropmenuobj.offsetHeight
  50. if (windowedge-dropmenuobj.y < dropmenuobj.contentmeasure) //move up?
  51. edgeoffsety=dropmenuobj.contentmeasure+obj.offsetHeight+(verticaloffset*2)
  52. return edgeoffsety
  53. }
  54. }
  55.  
  56. function displayballoontip(obj, e){ //main ballooon tooltip function
  57. if (window.event) event.cancelBubble=true
  58. else if (e.stopPropagation) e.stopPropagation()
  59. if (typeof dropmenuobj!="undefined") //hide previous tooltip?
  60. dropmenuobj.style.visibility="hidden"
  61. clearhidemenu()
  62. //obj.onmouseout=delayhidemenu
  63. dropmenuobj=document.getElementById(obj.getAttribute("rel"))
  64. showhide(dropmenuobj.style, e)
  65. dropmenuobj.x=getposOffset(obj, "left")
  66. dropmenuobj.y=getposOffset(obj, "top")+verticaloffset
  67. dropmenuobj.style.left=dropmenuobj.x-clearbrowseredge(obj, "rightedge")+"px"
  68. dropmenuobj.style.top=dropmenuobj.y-clearbrowseredge(obj, "bottomedge")+obj.offsetHeight+"px"
  69. if (enablearrowhead)
  70. displaytiparrow()
  71. }
  72.  
  73. function displaytiparrow(){ //function to display optional arrow image associated with tooltip
  74. tiparrow=document.getElementById("arrowhead")
  75. tiparrow.src=(edgeoffsety!=0)? arrowheadimg[0] : arrowheadimg[1]
  76. var ieshadowwidth=(dropmenuobj.filters && dropmenuobj.filters[0])? dropmenuobj.filters[0].Strength-1 : 0
  77. //modify "left" value depending on whether there's no room on right edge of browser to display it, respectively
  78. tiparrow.style.left=(edgeoffsetx!=0)? parseInt(dropmenuobj.style.left)+dropmenuobj.offsetWidth-tiparrow.offsetWidth-10+"px" : parseInt(dropmenuobj.style.left)+5+"px"
  79. //modify "top" value depending on whether there's no room on right edge of browser to display it, respectively
  80. tiparrow.style.top=(edgeoffsety!=0)? parseInt(dropmenuobj.style.top)+dropmenuobj.offsetHeight-tiparrow.offsetHeight-ieshadowwidth+arrowheadheight+"px" : parseInt(dropmenuobj.style.top)-arrowheadheight+"px"
  81. tiparrow.style.visibility="visible"
  82. }
  83.  
  84. function delayhidemenu(){
  85. delayhide=setTimeout("dropmenuobj.style.visibility='hidden'; dropmenuobj.style.left=0; if (enablearrowhead) tiparrow.style.visibility='hidden'",disappeardelay)
  86. }
  87.  
  88. function clearhidemenu(){
  89. if (typeof delayhide!="undefined")
  90. clearTimeout(delayhide)
  91. }
  92.  
  93. function reltoelement(linkobj){ //tests if a link has "rel" defined and it's the ID of an element on page
  94. var relvalue=linkobj.getAttribute("rel")
  95. return (relvalue!=null && relvalue!="" && document.getElementById(relvalue)!=null && document.getElementById(relvalue).className=="balloonstyle")? true : false
  96. }
  97.  
  98. function initalizetooltip(){
  99. var all_links=document.getElementsByTagName("a")
  100. if (enablearrowhead){
  101. tiparrow=document.createElement("img")
  102. tiparrow.setAttribute("src", arrowheadimg[0])
  103. tiparrow.setAttribute("id", "arrowhead")
  104. document.body.appendChild(tiparrow)
  105. }
  106. for (var i=0; i<all_links.length; i++){
  107. if (reltoelement(all_links[i])){ //if link has "rel" defined and it's the ID of an element on page
  108. all_links[i].onmouseover=function(e){
  109. var evtobj=window.event? window.event : e
  110. displayballoontip(this, evtobj)
  111. }
  112. all_links[i].onmouseout=delayhidemenu
  113. }
  114. }
  115. }
  116.  
  117. if (window.addEventListener)
  118. window.addEventListener("load", initalizetooltip, false)
  119. else if (window.attachEvent)
  120. window.attachEvent("onload", initalizetooltip)
  121. else if (document.getElementById)
  122. window.onload=initalizetooltip
  123.  
  124.  
Nov 25 '08 #3
mikek12004
200 New Member
In the above code wherever offsetTop (only in the function getposOffset) I substracted scrolltop now in IE works fine but in firefox is still the same any idea why?
The code now is
Expand|Select|Wrap|Line Numbers
  1. //Rich HTML Balloon Tooltip: http://www.dynamicdrive.com/dynamicindex5/balloontooltip.htm
  2. //Created: September 10th, 2006
  3.  
  4. var disappeardelay=250  //tooltip disappear delay (in miliseconds)
  5. var verticaloffset=0 //vertical offset of tooltip from anchor link, if any
  6. var enablearrowhead=1 //0 or 1, to disable or enable the arrow image
  7. var arrowheadimg=["images/arrowdown.gif", "images/arrowup.gif"] //path to down and up arrow images
  8. var arrowheadheight=14 //height of arrow image (amount to reveal)
  9.  
  10. /////No further editting needed
  11.  
  12. var ie=document.all
  13. var ns6=document.getElementById&&!document.all
  14. verticaloffset=(enablearrowhead)? verticaloffset+arrowheadheight : verticaloffset;
  15.  
  16. function getposOffset(what, offsettype){
  17. var totaloffset=(offsettype=="left")? what.offsetLeft-what.scrollLeft  : what.offsetTop-what.scrollTop;
  18. var parentEl=what.offsetParent;
  19. while (parentEl!=null){
  20. totaloffset=(offsettype=="left")? totaloffset+parentEl.offsetLeft-parentEl.scrollLeft : totaloffset+parentEl.offsetTop-parentEl.scrollTop;
  21. parentEl=parentEl.offsetParent;
  22. }
  23. return totaloffset;
  24. }
  25.  
  26. function showhide(obj, e){
  27. dropmenuobj.style.left=dropmenuobj.style.top="-500px"
  28. if (e.type=="mouseover")
  29. obj.visibility="visible"
  30. }
  31.  
  32. function iecompattest(){
  33. return (document.compatMode && document.compatMode!="BackCompat")? document.documentElement : document.body
  34. }
  35.  
  36. function clearbrowseredge(obj, whichedge){
  37. if (whichedge=="rightedge"){
  38. edgeoffsetx=0
  39. var windowedge=ie && !window.opera? iecompattest().scrollLeft+iecompattest().clientWidth-15 : window.pageXOffset+window.innerWidth-15
  40. dropmenuobj.contentmeasure=dropmenuobj.offsetWidth
  41. if (windowedge-dropmenuobj.x < dropmenuobj.contentmeasure)
  42. edgeoffsetx=dropmenuobj.contentmeasure-obj.offsetWidth
  43. return edgeoffsetx
  44. }
  45. else{
  46. edgeoffsety=0
  47. var topedge=ie && !window.opera? iecompattest().scrollTop : window.pageYOffset
  48. var windowedge=ie && !window.opera? iecompattest().scrollTop+iecompattest().clientHeight-15 : window.pageYOffset+window.innerHeight-18
  49. dropmenuobj.contentmeasure=dropmenuobj.offsetHeight
  50. if (windowedge-dropmenuobj.y < dropmenuobj.contentmeasure) //move up?
  51. edgeoffsety=dropmenuobj.contentmeasure+obj.offsetHeight+(verticaloffset*2)
  52. return edgeoffsety
  53. }
  54. }
  55.  
  56. function displayballoontip(obj, e){ //main ballooon tooltip function
  57. if (window.event) event.cancelBubble=true
  58. else if (e.stopPropagation) e.stopPropagation()
  59. if (typeof dropmenuobj!="undefined") //hide previous tooltip?
  60. dropmenuobj.style.visibility="hidden"
  61. clearhidemenu()
  62. //obj.onmouseout=delayhidemenu
  63. dropmenuobj=document.getElementById(obj.getAttribute("rel"))
  64. showhide(dropmenuobj.style, e)
  65. dropmenuobj.x=getposOffset(obj, "left")
  66. dropmenuobj.y=getposOffset(obj, "top")+verticaloffset
  67. dropmenuobj.style.left=dropmenuobj.x-clearbrowseredge(obj, "rightedge")+"px"
  68. dropmenuobj.style.top=dropmenuobj.y-clearbrowseredge(obj, "bottomedge")+obj.offsetHeight+"px"
  69. if (enablearrowhead)
  70. displaytiparrow()
  71. }
  72.  
  73. function displaytiparrow(){ //function to display optional arrow image associated with tooltip
  74. tiparrow=document.getElementById("arrowhead")
  75. tiparrow.src=(edgeoffsety!=0)? arrowheadimg[0] : arrowheadimg[1]
  76. var ieshadowwidth=(dropmenuobj.filters && dropmenuobj.filters[0])? dropmenuobj.filters[0].Strength-1 : 0
  77. //modify "left" value depending on whether there's no room on right edge of browser to display it, respectively
  78. tiparrow.style.left=(edgeoffsetx!=0)? parseInt(dropmenuobj.style.left)+dropmenuobj.offsetWidth-tiparrow.offsetWidth-10+"px" : parseInt(dropmenuobj.style.left)+5+"px"
  79. //modify "top" value depending on whether there's no room on right edge of browser to display it, respectively
  80. tiparrow.style.top=(edgeoffsety!=0)? parseInt(dropmenuobj.style.top)+dropmenuobj.offsetHeight-tiparrow.offsetHeight-ieshadowwidth+arrowheadheight+"px" : parseInt(dropmenuobj.style.top)-arrowheadheight+"px"
  81. tiparrow.style.visibility="visible"
  82. }
  83.  
  84. function delayhidemenu(){
  85. delayhide=setTimeout("dropmenuobj.style.visibility='hidden'; dropmenuobj.style.left=0; if (enablearrowhead) tiparrow.style.visibility='hidden'",disappeardelay)
  86. }
  87.  
  88. function clearhidemenu(){
  89. if (typeof delayhide!="undefined")
  90. clearTimeout(delayhide)
  91. }
  92.  
  93. function reltoelement(linkobj){ //tests if a link has "rel" defined and it's the ID of an element on page
  94. var relvalue=linkobj.getAttribute("rel")
  95. return (relvalue!=null && relvalue!="" && document.getElementById(relvalue)!=null && document.getElementById(relvalue).className=="balloonstyle")? true : false
  96. }
  97.  
  98. function initalizetooltip(){
  99. var all_links=document.getElementsByTagName("a")
  100. if (enablearrowhead){
  101. tiparrow=document.createElement("img")
  102. tiparrow.setAttribute("src", arrowheadimg[0])
  103. tiparrow.setAttribute("id", "arrowhead")
  104. document.body.appendChild(tiparrow)
  105. }
  106. for (var i=0; i<all_links.length; i++){
  107. if (reltoelement(all_links[i])){ //if link has "rel" defined and it's the ID of an element on page
  108. all_links[i].onmouseover=function(e){
  109. var evtobj=window.event? window.event : e
  110. displayballoontip(this, evtobj)
  111. }
  112. all_links[i].onmouseout=delayhidemenu
  113. }
  114. }
  115. }
  116.  
  117. if (window.addEventListener)
  118. window.addEventListener("load", initalizetooltip, false)
  119. else if (window.attachEvent)
  120. window.attachEvent("onload", initalizetooltip)
  121. else if (document.getElementById)
  122. window.onload=initalizetooltip
  123.  
Jan 5 '09 #4
mikek12004
200 New Member
As said in previous post in my page I use the "Rich HTML Balloon Tooltip" which can be found here :
Dynamic Drive DHTML Scripts- Rich HTML Balloon Tooltip
Great script helped a lot but when I used it inside a div for elements that neede to be scrolled to reach the ballon tip was dispalyed at the position they would had in the page without the page. In another thread acoder suggested to use scrolltop wich I did and worked but only in IE, in firefox/safari I get still the same but why?
the .js is
Expand|Select|Wrap|Line Numbers
  1. //Rich HTML Balloon Tooltip: http://www.dynamicdrive.com/dynamicindex5/balloontooltip.htm
  2. //Created: September 10th, 2006
  3.  
  4. var disappeardelay=250  //tooltip disappear delay (in miliseconds)
  5. var verticaloffset=0 //vertical offset of tooltip from anchor link, if any
  6. var enablearrowhead=1 //0 or 1, to disable or enable the arrow image
  7. var arrowheadimg=["images/arrowdown.gif", "images/arrowup.gif"] //path to down and up arrow images
  8. var arrowheadheight=14 //height of arrow image (amount to reveal)
  9.  
  10. /////No further editting needed
  11.  
  12. var ie=document.all
  13. var ns6=document.getElementById&&!document.all
  14. verticaloffset=(enablearrowhead)? verticaloffset+arrowheadheight : verticaloffset;
  15.  
  16. function getposOffset(what, offsettype){
  17. var totaloffset=(offsettype=="left")? what.offsetLeft-what.scrollLeft  : what.offsetTop-what.scrollTop;
  18. var parentEl=what.offsetParent;
  19. while (parentEl!=null){
  20. totaloffset=(offsettype=="left")? totaloffset+parentEl.offsetLeft-parentEl.scrollLeft : totaloffset+parentEl.offsetTop-parentEl.scrollTop;
  21. parentEl=parentEl.offsetParent;
  22. }
  23. return totaloffset;
  24. }
  25.  
  26. function showhide(obj, e){
  27. dropmenuobj.style.left=dropmenuobj.style.top="-500px"
  28. if (e.type=="mouseover")
  29. obj.visibility="visible"
  30. }
  31.  
  32. function iecompattest(){
  33. return (document.compatMode && document.compatMode!="BackCompat")? document.documentElement : document.body
  34. }
  35.  
  36. function clearbrowseredge(obj, whichedge){
  37. if (whichedge=="rightedge"){
  38. edgeoffsetx=0
  39. var windowedge=ie && !window.opera? iecompattest().scrollLeft+iecompattest().clientWidth-15 : window.pageXOffset+window.innerWidth-15
  40. dropmenuobj.contentmeasure=dropmenuobj.offsetWidth
  41. if (windowedge-dropmenuobj.x < dropmenuobj.contentmeasure)
  42. edgeoffsetx=dropmenuobj.contentmeasure-obj.offsetWidth
  43. return edgeoffsetx
  44. }
  45. else{
  46. edgeoffsety=0
  47. var topedge=ie && !window.opera? iecompattest().scrollTop : window.pageYOffset
  48. var windowedge=ie && !window.opera? iecompattest().scrollTop+iecompattest().clientHeight-15 : window.pageYOffset+window.innerHeight-18
  49. dropmenuobj.contentmeasure=dropmenuobj.offsetHeight
  50. if (windowedge-dropmenuobj.y < dropmenuobj.contentmeasure) //move up?
  51. edgeoffsety=dropmenuobj.contentmeasure+obj.offsetHeight+(verticaloffset*2)
  52. return edgeoffsety
  53. }
  54. }
  55.  
  56. function displayballoontip(obj, e){ //main ballooon tooltip function
  57. if (window.event) event.cancelBubble=true
  58. else if (e.stopPropagation) e.stopPropagation()
  59. if (typeof dropmenuobj!="undefined") //hide previous tooltip?
  60. dropmenuobj.style.visibility="hidden"
  61. clearhidemenu()
  62. //obj.onmouseout=delayhidemenu
  63. dropmenuobj=document.getElementById(obj.getAttribute("rel"))
  64. showhide(dropmenuobj.style, e)
  65. dropmenuobj.x=getposOffset(obj, "left")
  66. dropmenuobj.y=getposOffset(obj, "top")+verticaloffset
  67. dropmenuobj.style.left=dropmenuobj.x-clearbrowseredge(obj, "rightedge")+"px"
  68. dropmenuobj.style.top=dropmenuobj.y-clearbrowseredge(obj, "bottomedge")+obj.offsetHeight+"px"
  69. if (enablearrowhead)
  70. displaytiparrow()
  71. }
  72.  
  73. function displaytiparrow(){ //function to display optional arrow image associated with tooltip
  74. tiparrow=document.getElementById("arrowhead")
  75. tiparrow.src=(edgeoffsety!=0)? arrowheadimg[0] : arrowheadimg[1]
  76. var ieshadowwidth=(dropmenuobj.filters && dropmenuobj.filters[0])? dropmenuobj.filters[0].Strength-1 : 0
  77. //modify "left" value depending on whether there's no room on right edge of browser to display it, respectively
  78. tiparrow.style.left=(edgeoffsetx!=0)? parseInt(dropmenuobj.style.left)+dropmenuobj.offsetWidth-tiparrow.offsetWidth-10+"px" : parseInt(dropmenuobj.style.left)+5+"px"
  79. //modify "top" value depending on whether there's no room on right edge of browser to display it, respectively
  80. tiparrow.style.top=(edgeoffsety!=0)? parseInt(dropmenuobj.style.top)+dropmenuobj.offsetHeight-tiparrow.offsetHeight-ieshadowwidth+arrowheadheight+"px" : parseInt(dropmenuobj.style.top)-arrowheadheight+"px"
  81. tiparrow.style.visibility="visible"
  82. }
  83.  
  84. function delayhidemenu(){
  85. delayhide=setTimeout("dropmenuobj.style.visibility='hidden'; dropmenuobj.style.left=0; if (enablearrowhead) tiparrow.style.visibility='hidden'",disappeardelay)
  86. }
  87.  
  88. function clearhidemenu(){
  89. if (typeof delayhide!="undefined")
  90. clearTimeout(delayhide)
  91. }
  92.  
  93. function reltoelement(linkobj){ //tests if a link has "rel" defined and it's the ID of an element on page
  94. var relvalue=linkobj.getAttribute("rel")
  95. return (relvalue!=null && relvalue!="" && document.getElementById(relvalue)!=null && document.getElementById(relvalue).className=="balloonstyle")? true : false
  96. }
  97.  
  98. function initalizetooltip(){
  99. var all_links=document.getElementsByTagName("a")
  100. if (enablearrowhead){
  101. tiparrow=document.createElement("img")
  102. tiparrow.setAttribute("src", arrowheadimg[0])
  103. tiparrow.setAttribute("id", "arrowhead")
  104. document.body.appendChild(tiparrow)
  105. }
  106. for (var i=0; i<all_links.length; i++){
  107. if (reltoelement(all_links[i])){ //if link has "rel" defined and it's the ID of an element on page
  108. all_links[i].onmouseover=function(e){
  109. var evtobj=window.event? window.event : e
  110. displayballoontip(this, evtobj)
  111. }
  112. all_links[i].onmouseout=delayhidemenu
  113. }
  114. }
  115. }
  116.  
  117. if (window.addEventListener)
  118. window.addEventListener("load", initalizetooltip, false)
  119. else if (window.attachEvent)
  120. window.attachEvent("onload", initalizetooltip)
  121. else if (document.getElementById)
  122. window.onload=initalizetooltip
  123.  
  124.  
what I did was insert the scrollTop in lines 17 and 20 (its in the getposOffset function) I suspect lines 47 and 48 but I cannot be sure
Jan 7 '09 #5
acoder
16,027 Recognized Expert Moderator MVP
This link may help.
Jan 9 '09 #6
mikek12004
200 New Member
You have given me this link in your previous post, did I miss something?
In the above code wherever offsetTop (only in the function getposOffset) I substracted scrolltop in lines 17 and 20 I couldn't find anyother point where he calculates these properties, now in IE works fine but only there why? the only lines where I could see a separation based on the browser is in lines 47 and 48 but I think of what to do any tips?
greatly appreciate your time
Jan 23 '09 #7
acoder
16,027 Recognized Expert Moderator MVP
Oh, so I did! Sorry, I didn't realise. In my defence, I could say that it was 1 and a half months later!

I haven't got time to look at this properly, but what I would suggest you do is use a debugging tool like Firebug to see the values as they change to see what they are and what they should be.
Jan 23 '09 #8
mikek12004
200 New Member
Yep 1 nad a half moth since the lat post and more than two since I have this little ermm...problem well, hopefully someine with better knowledge in js than me will see the posted code and figure it out before I find the time and (and the effort) to learn a bit more and correct it myself
thanks anyhow you are always a great help ;)
Jan 26 '09 #9

Sign in to post your reply or Sign up for a free account.

Similar topics

28
1945
by: petermichaux | last post by:
Hi, On my computer apache will see php in .php documents but not in .html documents. Can I configure apache to see php in .html documents? Or is this something that cannot be done at all? Thanks, Peter
2
2044
by: pleaseSeeFooter | last post by:
Pythonagons, I am considering using (building) a client-side application, rather than a browser, for an Internet application. I am aware there are a few resourcesout there like XUL and various Java clients or classes to build one with. Has anyone developed a frame work for this sort of thing in Python? I am looking at the Windows platform initially, but of course would like to have portability. I have not built something like this...
9
13443
by: David D. | last post by:
Does the file extension matter when including a JavaScript file in an HTML page? Normally, one would include a JavaScript file in an HTML page using <script src="foo.JS" type="text/javascript"> However, I have found that I can use an alternate file extension, such as <script src="foo.HTML" type="text/javascript"> It works fine with my IE 6 and Mozilla. Will it work with other browsers?
6
5276
by: Jon Davis | last post by:
I recently learned how to do an <OBJECT> alternative to <IFRAME> in current browsers using: <object id="extendedhtml" type="text/html" data="otherpage.html" width="250" height="400"></object> My question is how do I access the document DOM of this object in Javascript? For example, "alert(extendedhtml.innerHTML);" doesn't work and produces an unknown error. I'd like to both read and write to the document's body element's innerHTML...
2
1372
by: Jim Heavey | last post by:
Why does intellisense not show me all of the available properties for a control, such as a text box when I am adding that control in the HTML view. For example, "ToolTip" does not show up as a "available" property for a textbox that I am adding to an EditItemTemplate. Does not seem to mind that I place the value in the element block, but it does not show it as a valid property. Thanks in advance for your assitance!!!!!!!!
1
6195
by: tilt | last post by:
Hello, I use an object element to replace the iframe element in ie, like this: <object id="x_obj" data="http://.../" type="text/html"> <iframe name="x_if" id="x_if" src="http://.../">
2
4899
by: Mark Collard | last post by:
I've noticed that when you add a ToolTip component to a Form (or UserControl) the other controls on the form display a property in the property grid called "ToolTip on toolTip1", so you can set the tooltip text on the selected control. I'm currently writing my own component, and I want to add the same functionality to the component, so that the other controls on the form display a property in the property grid called "ControlText on...
7
3364
by: Xh | last post by:
Hi All, I have problems with generating valid HTML output there are few HTML elements that i don't what to output as <tagname/> but as <tagname></tagnamebut Xalan keeps generating them as <tagname/> there are few really annoying situations where adding   to some HTML elements is necessary:
1
2944
mikek12004
by: mikek12004 | last post by:
1) Script Title:Rich HTML Balloon Tooltip 2) Script URL http://www.dynamicdrive.com/dynamicindex5/balloontooltip.htm 3) Describe problem: When I try to fetch the balloontips (the divs) and links through AJAX (I have a <span> and when I press a link its content gets replaced through AJAX) the scripts do nothing any help?
0
9999
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9847
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
11283
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
10986
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10501
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
8049
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6093
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4727
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
4308
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.