Graphs

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • 1066

    Graphs

    I've created a wizzy Javascript function embedded within PL/SQL that
    generates html bar charts. I would like to know if it is possible to get the
    javascript function to write another javascript function (embedded in
    PL/SQL) so I can do mouseover and display the values?


  • kaeli

    #2
    Re: Graphs

    In article <burc85$hr7$1@v isp.bt.co.uk>, james.hastings@ bt.com
    enlightened us with...[color=blue]
    > I've created a wizzy Javascript function embedded within PL/SQL that
    > generates html bar charts. I would like to know if it is possible to get the
    > javascript function to write another javascript function (embedded in
    > PL/SQL) so I can do mouseover and display the values?
    >
    >
    >[/color]

    That would highly depend on the way it was written and when it runs on
    the client.

    If it runs after the page loads, you know the names or ids of the
    mouseover elements, and you know your users' browsers support
    dynamically adding events, yes, it can be done.

    But...why?

    If you have the script on the page when the client needs it, you can
    just add the mouseover code right to the html. Maybe you want it so
    anyone can include it, I suppose...but if that were the case, your
    script wouldn't know the ids of the elements to add the event handler
    to.

    Hrm. Need more info.

    --
    --
    ~kaeli~
    If at first you don't succeed, skydiving is not for you.



    Comment

    • 1066

      #3
      Re: Graphs

      What i'm saying is I can't seem to get the script on the page
      The technical structure is as follows:

      Pg1 - Form to gather request

      Pg2 (hidden) - PL/SQL gathers data and submits it in another form to
      graphing package.

      Pg3 - onLoad event on inital graphing page calls Javascript function "Draw
      Graph"
      Javscript function writes html and unfortunately seems to ignore the other 2
      functions (mouse over, etc) to be loaded. Is this because a new 'document'
      is being written?

      This has led me to ask if I can get the javascript to write another 2
      javascript functions.


      "kaeli" <tiny_one@NOSPA M.comcast.net> wrote in message
      news:MPG.1a7b0b 4517de04b0989b6 1@nntp.lucent.c om...[color=blue]
      > In article <burc85$hr7$1@v isp.bt.co.uk>, james.hastings@ bt.com
      > enlightened us with...[color=green]
      > > I've created a wizzy Javascript function embedded within PL/SQL that
      > > generates html bar charts. I would like to know if it is possible to get[/color][/color]
      the[color=blue][color=green]
      > > javascript function to write another javascript function (embedded in
      > > PL/SQL) so I can do mouseover and display the values?
      > >
      > >
      > >[/color]
      >
      > That would highly depend on the way it was written and when it runs on
      > the client.
      >
      > If it runs after the page loads, you know the names or ids of the
      > mouseover elements, and you know your users' browsers support
      > dynamically adding events, yes, it can be done.
      >
      > But...why?
      >
      > If you have the script on the page when the client needs it, you can
      > just add the mouseover code right to the html. Maybe you want it so
      > anyone can include it, I suppose...but if that were the case, your
      > script wouldn't know the ids of the elements to add the event handler
      > to.
      >
      > Hrm. Need more info.
      >
      > --
      > --
      > ~kaeli~
      > If at first you don't succeed, skydiving is not for you.
      > http://www.ipwebdesign.net/wildAtHeart
      > http://www.ipwebdesign.net/kaelisSpace
      >[/color]


      Comment

      • kaeli

        #4
        Re: Graphs

        In article <burml4$4tb$1@v isp.bt.co.uk>, james.hastings@ bt.com
        enlightened us with...[color=blue]
        >
        > Pg3 - onLoad event on inital graphing page calls Javascript function "Draw
        > Graph"
        > Javscript function writes html and unfortunately seems to ignore the other 2
        > functions (mouse over, etc) to be loaded. Is this because a new 'document'
        > is being written?
        >[/color]

        Only if you're using the archaic (but necessary if supporting NN4)
        document.write function. Document.write will wipe out the document.

        Are you?

        Do you need to? That is, do you know your users? If so, do they use NN4
        or can you say they use NN6+/IE5+?
        If you need to, you'd have to modify the document.write so it writes to
        a layer instead of to the document root. That way, it'll wipe out the
        "document" in that layer, which would have been blank anyhow.
        If you don't need to, get that out of there and move to either using
        innerHTML or document.create Element/appendchild DOM functions.


        --
        --
        ~kaeli~
        Dancing cheek-to-cheek is really a form of floor play.



        Comment

        Working...