Loading ...
Sorry, an error occurred while loading the content.

Image Not Loading - Overlay

Expand Messages
  • Raja
    I m trying to imitate a Yahoo Quote Popup, with an image loading in the overlay. theOverlay.setBody(companyName +
    Message 1 of 11 , Jul 30, 2008
    • 0 Attachment
      I'm trying to imitate a Yahoo Quote Popup, with an image loading in the
      overlay.

      theOverlay.setBody(companyName + "<img name='quoteChart'
      id='quoteChart' src='"+symbolInfo.image+"' border='1' hspace='3'><br>"
      + chartNav);
      theOverlay.setFooter(generateFooter(symbol));
      theOverlay.render(document.body);
      theOverlay.align();
      theOverlay.show();

      The image wont load, but when tried in the browser loading the URL,
      the image loads fine.

      Any suggestions?

      thanks,
      Raja
    • Frank Dietrich
      ... Works flawlessly for me: http://www.personalplanung.com/YUI/Test_OverlayFollowsMouse.html must be some kind of pathing problem.
      Message 2 of 11 , Jul 30, 2008
      • 0 Attachment
        >I'm trying to imitate a Yahoo Quote Popup, with an image loading in the
        >overlay.
        >
        >theOverlay.setBody(companyName + "<img name='quoteChart'
        >id='quoteChart' src='"+symbolInfo.image+"' border='1' hspace='3'><br>"
        >+ chartNav);
        > theOverlay.setFooter(generateFooter(symbol));
        > theOverlay.render(document.body);
        > theOverlay.align();
        > theOverlay.show();
        >
        >The image wont load, but when tried in the browser loading the URL,
        >the image loads fine.
        >

        Works flawlessly for me:

        http://www.personalplanung.com/YUI/Test_OverlayFollowsMouse.html

        must be some kind of pathing problem.
      • Raja
        can you try this image please.
        Message 3 of 11 , Jul 30, 2008
        • 0 Attachment
          can you try this image please.
          src="http://app.quotemedia.com/quotetools/getChart.go?webmasterId=501&chtype=AreaChart&symbol=CSCO&chmrg=4&chscale=1m&chhig=110&chwid=110&chsym=Cisco
          month&chbg=333366&chln=000080&chgrd=cccccc&chxyc=ffffff&chmrg=2&chbgch=000000&chbdr=000000&chton=on&chtcol=ffff00&chfill=cccccc&chfill2=6699cc"

          Thanks for the quick response.

          -Raja
          --- In ydn-javascript@yahoogroups.com, "Frank Dietrich"
          <fdietrich@...> wrote:
          >
          >
          >
          > >I'm trying to imitate a Yahoo Quote Popup, with an image loading in
          the
          > >overlay.
          > >
          > >theOverlay.setBody(companyName + "<img name='quoteChart'
          > >id='quoteChart' src='"+symbolInfo.image+"' border='1' hspace='3'><br>"
          > >+ chartNav);
          > > theOverlay.setFooter(generateFooter(symbol));
          > > theOverlay.render(document.body);
          > > theOverlay.align();
          > > theOverlay.show();
          > >
          > >The image wont load, but when tried in the browser loading the URL,
          > >the image loads fine.
          > >
          >
          > Works flawlessly for me:
          >
          > http://www.personalplanung.com/YUI/Test_OverlayFollowsMouse.html
          >
          > must be some kind of pathing problem.
          >
        • Frank Dietrich
          Raja, ... when I first tried to assign it to my demo source var symbolInfo = { image: http://app.quotemedia.com/quotetools/getCh ....
          Message 4 of 11 , Jul 30, 2008
          • 0 Attachment
            Raja,


            >can you try this image please.
            >src="http://app.quotemedia.com/quotetools/getChart.go?webmasterId=501&chtype=AreaChart&symbol=CSCO&chmrg=4&chscale=1m&chhig=110&chwid=110&chsym=Cisco
            >month&chbg=333366&chln=000080&chgrd=cccccc&chxyc=ffffff&chmrg=2&chbgch=000000&chbdr=000000&chton=on&chtcol=ffff00&chfill=cccccc&chfill2=6699cc"


            when I first tried to assign it to my demo source

            var symbolInfo = {
            image: 'http://app.quotemedia.com/quotetools/getCh .... chfill=cccccc&chfill2=6699cc'
            }

            I got an error "unterminated string literal".

            I think the string is just too long

            So I tried:

            var symbolInfo = {
            image: 'http://app.quotemedia.com/quotetools/getChart.go?webmasterId=501&chtype=AreaChart'+
            '&symbol=CSCO&chmrg=4&chscale=1m&chhig=110&chwid=110&chsym=Cisco'
            }


            and that worked. I can see the image

            funnily, when I paste the link into my browser it cuts after "Cisco", but shows the image... ah, I see then it's only white and shows "Cisco" not "Cisco Month".

            But, yes, this way it works for me.

            Update for You:

            http://www.personalplanung.com/YUI/Test_OverlayFollowsMouse.html

            the fourth div should show the image.
          • Raja
            Hi Frank, the same image wont load on my overlay. Could this be an image loading issue, the image is rendered dynamically on mouseover over some cells in my
            Message 5 of 11 , Jul 31, 2008
            • 0 Attachment
              Hi Frank,

              the same image wont load on my overlay. Could this be an image loading
              issue, the image is rendered dynamically on mouseover over some cells
              in my Table. The image is not loaded when the window load occurs.

              thank you,
              Raja
            • Frank Dietrich
              Raja, hi, ... Did You try to split the URL as I did in my code? As You can see, I also dynamically write the code to the overlay when I move over it. Maybe You
              Message 6 of 11 , Jul 31, 2008
              • 0 Attachment
                Raja, hi,

                >the same image wont load on my overlay. Could this be an image loading
                >issue, the image is rendered dynamically on mouseover over some cells
                >in my Table. The image is not loaded when the window load occurs.

                Did You try to split the URL as I did in my code?

                As You can see, I also dynamically write the code to the overlay when
                I move over it. Maybe You can compare What You do to what I did in my
                sample.
              • Raja
                Hi, this is what I have tried : theOverlay.setBody(companyName +
                Message 7 of 11 , Jul 31, 2008
                • 0 Attachment
                  Hi,

                  this is what I have tried :

                  theOverlay.setBody(companyName + "<img id='quoteChart'
                  src='http://app.quotemedia.com/quotetools/getChart.go?webmasterId=91664&chtype=AreaChart&"

                  +"symbol=YHOO&chmrg=3&chwid=160&chhig=130&chbg=ffffff&chln=104E8B&chgrd=CAE1FF&chxyc=000000&chton=off'
                  border='1' hspace='3'><br>" + chartNav);
                  theOverlay.setFooter(generateFooter(symbol));
                  theOverlay.render(document.body);
                  theOverlay.symbolCell.addClass('hoversymbol_active');
                  theOverlay.align();
                  theOverlay.show();

                  Thank You,
                  Raja

                  --- In ydn-javascript@yahoogroups.com, "Frank Dietrich"
                  <fdietrich@...> wrote:
                  >
                  >
                  > Raja, hi,
                  >
                  > >the same image wont load on my overlay. Could this be an image loading
                  > >issue, the image is rendered dynamically on mouseover over some cells
                  > >in my Table. The image is not loaded when the window load occurs.
                  >
                  > Did You try to split the URL as I did in my code?
                  >
                  > As You can see, I also dynamically write the code to the overlay when
                  > I move over it. Maybe You can compare What You do to what I did in my
                  > sample.
                  >
                • Frank Dietrich
                  Raja, sorry. Had no time to look into this yet... Already 10pm here *********** REPLY SEPARATOR ***********
                  Message 8 of 11 , Aug 1 12:43 PM
                  • 0 Attachment
                    Raja,

                    sorry. Had no time to look into this yet... Already 10pm here

                    *********** REPLY SEPARATOR ***********

                    On 31.07.08 at 22:49 Raja wrote:

                    >Hi,
                    >
                    >this is what I have tried :
                    >
                    >theOverlay.setBody(companyName + "<img id='quoteChart'
                    >src='http://app.quotemedia.com/quotetools/getChart.go?webmasterId=91664&chtype=AreaChart&"
                    >
                    >+"symbol=YHOO&chmrg=3&chwid=160&chhig=130&chbg=ffffff&chln=104E8B&chgrd=CAE1FF&chxyc=000000&chton=off'
                    >border='1' hspace='3'><br>" + chartNav);
                    > theOverlay.setFooter(generateFooter(symbol));
                    > theOverlay.render(document.body);
                    > theOverlay.symbolCell.addClass('hoversymbol_active');
                    > theOverlay.align();
                    > theOverlay.show();
                    >
                    >Thank You,
                    >Raja
                    >
                    >--- In ydn-javascript@yahoogroups.com, "Frank Dietrich"
                    ><fdietrich@...> wrote:
                    >>
                    >>
                    >> Raja, hi,
                    >>
                    >> >the same image wont load on my overlay. Could this be an image loading
                    >> >issue, the image is rendered dynamically on mouseover over some cells
                    >> >in my Table. The image is not loaded when the window load occurs.
                    >>
                    >> Did You try to split the URL as I did in my code?
                    >>
                    >> As You can see, I also dynamically write the code to the overlay when
                    >> I move over it. Maybe You can compare What You do to what I did in my
                    >> sample.
                    >>
                    >
                    >
                    >
                    >------------------------------------
                    >
                    >Yahoo! Groups Links
                    >
                    >
                    >
                  • dietrich.frank
                    Raja, ... src= http://app.quotemedia.com/quotetools/getChart.go?webmasterId=91664& chtype=AreaChart& ... late, but I ve tried. I have copied Your code
                    Message 9 of 11 , Aug 1 2:53 PM
                    • 0 Attachment
                      Raja,

                      > this is what I have tried :
                      >
                      > theOverlay.setBody(companyName + "<img id='quoteChart'
                      > src='http://app.quotemedia.com/quotetools/getChart.go?webmasterId=91664&chtype=AreaChart&"...


                      late, but I've tried. I have copied Your code exactely in my example and created dummy variables for the ones You use. I only commented the SetFooter() and the setclass() points out.

                      Works wonderful. You don't need the render(document.body) everytime, only the first time it's needed.

                      http://www.personalplanung.com/YUI/test_OverlayFollowsMouse.html 


                      This is the code:

                          if (o.target.id.substr(0,3) == "Raj"){

                              if (o.target.id == currentTarget) {
                                  // nothing
                              }
                              else {
                                  // Test using code from Raja

                                  // some dummy-vars, so that

                                  // his code works
                                  var companyName = "dd-tech.de";
                                  var chartNav    = "-- Nav here --";

                                  // check if the overlay is there; if not, create it
                                  checkOverlay();

                                  var theOverlay = toolTip;

                                  theOverlay.setBody(companyName +
                                       "<img id='quoteChart' src='http://app.quotemedia.com/quotetools/getChart.go?webmasterId=91664&chtype=AreaChart&"
                                       +"symbol=YHOO&chmrg=3&chwid=160&chhig=130&chbg=ffffff&chln=104E8B&chgrd=CAE1FF&chxyc=000000&chton=off' border='1' hspace='3'><br>" + chartNav);

                                   // theOverlay.setFooter(generateFooter(symbol));
                                   theOverlay.render(document.body);
                                   // theOverlay.symbolCell.addClass('hoversymbol_active');
                                   theOverlay.align();
                                   theOverlay.show();
                             }
                          }

                       

                      from my side this works great.  If You still can't get it to work, start reducing things or try to follow the script in firebug. Maybe it vanishes somewhere without producing an error.

                      some of the YUI-methods use TRY...CATCH blocks that simply catch errors without complaining.

                      HTH

                      Frank
                    • dietrich.frank
                      Raja, FYI,I just tried the sample locally calling it via http://localhost... and I don t see the images either. as soon as I call it via file:// , via my
                      Message 10 of 11 , Aug 1 4:01 PM
                      • 0 Attachment
                        Raja,

                        FYI,I just tried the sample locally calling it via
                        "http://localhost..." and I don't see the images either.
                        as soon as I call it via "file://", via my local ip address
                        (http://195.168...) or call it on my webserver, the images appear

                        Maybe this is the issue in Your case.
                      • Raja
                        Thanks! Frank, I m working on it, I observed the same. Waiting on the other team to include a doctype, and retry the same. Cheers, Raja
                        Message 11 of 11 , Aug 4 10:40 AM
                        • 0 Attachment
                          Thanks! Frank,

                          I'm working on it, I observed the same. Waiting on the other team to
                          include a doctype, and retry the same.

                          Cheers,
                          Raja
                          --- In ydn-javascript@yahoogroups.com, "dietrich.frank"
                          <fdietrich@...> wrote:
                          >
                          >
                          >
                          > Raja,
                          >
                          > FYI,I just tried the sample locally calling it via
                          > "http://localhost..." and I don't see the images either.
                          > as soon as I call it via "file://", via my local ip address
                          > (http://195.168...) or call it on my webserver, the images appear
                          >
                          > Maybe this is the issue in Your case.
                          >
                        Your message has been successfully submitted and would be delivered to recipients shortly.