A Flash Developer Resource Site

Results 1 to 2 of 2

Thread: issue with dynamic data

  1. #1
    Senior Member
    Join Date
    Jul 2000

    issue with dynamic data

    I am working on an example from an article and i am having a problem but i don't really know where the breakdown is or how to fix it.

    The following code gets variables from a php page

    function lv(l, n, t, e, f) {
    sb.setSize(null, 200);
    //sb2.setSize(null, 30);
    //create a new loadVars object if one doesn't already exist if it does, use it
    if (l == undefined) {
    l = new LoadVars();
    l.onLoad = function() {
    var i;
    //clear out any text that might already be there
    n.htmlText = "";
    //to show a single entry at a time we use the following code
    if (t == undefined) {
    n.htmlText += "<b>"+this["title"+e]+" - "+this["date"+e]+"</b><br><br>";
    n.htmlText += this["entry"+e];
    } else {
    //cycle through and show all entries
    for (i=0; i<this.n; i++) {
    n.txt.htmlText += "<u><a href='asfunction:_root.loadArc,"+this["id"+i]+"'>"+this["title"+i]+" - "+this["date"+i]+"</a></u><br>";
    function loadArc(passed) {
    arcNum = passed-1;
    lv(blog_lv, entries_txt, undefined, arcNum, "blog_result.php");
    //for the large entry textfield
    lv(blog_lv, entries_txt, undefined, 0, "blog_result.php"); **this one works fine**
    //for the archives text field
    lv(archive_lv, archive_txt, "cycle", null, "blog_result.php"); **this one doesn't

    The text field that the last function call should fill is always empty I am not sure why the first one will work but the second won't. I have tried eveything i can think of. Anyone see anything that i have done wrong here?


  2. #2
    Senior Member
    Join Date
    Jul 2000


    I found the answer
    the line
    n.txt.htmlText +=
    should have been n.htmlText +=

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Click Here to Expand Forum to Full Width

HTML5 Development Center