dcsimg
A Flash Developer Resource Site

Page 1 of 2 12 LastLast
Results 1 to 20 of 26

Thread: links in a dynamic text box

  1. #1
    Member
    Join Date
    Aug 2002
    Posts
    89

    links in a dynamic text box

    Hello everyone,

    I'm trying to assign hyperlinks/actionscript links to some text in a dynamic text box. Since the text box's properties does not give you this option, how else could it be done? has anyone ever done this before?

    Thanks
    Great minds discuss ideas; Average minds discuss events; Small minds discuss People.

  2. #2
    Senior Member
    Join Date
    Feb 2001
    Location
    On the fifth floor.
    Posts
    1,202
    Who's told you that "the text box's properties does not give you this option"?
    Whoever has told it to you, - do not trust him.
    Take a look at the example.
    Attached Files Attached Files

  3. #3
    FK's Official War Driver wiReZ's Avatar
    Join Date
    Jun 2002
    Location
    wireless
    Posts
    615
    If you have HTML enabled on your dynamic text, it shouldn't be a problem making hyperlinks within the text field. For all valid HTML tags allowed within Flash, please go to the following link. http://www.macromedia.com/support/fl...s/htmltext.htm
    My current rig: AMD Athlon64 3500+(Winchester Core) MSI K8N Neo2 Platinum - 1GB
    (2x512MB) Kingston HyperX DDR333 BH5 - ATI All-In-Wonder 9800 Pro 128mb - SB Audigy 2
    WD 80GB 7200RPM 8MB - WD 250GB 7200RPM 8MB - MAX 120GB 7200RPM 8MB - Dell 2001FP 20.1 LCD

  4. #4
    Member
    Join Date
    Aug 2002
    Posts
    89
    Thanks guys,

    sergwiz , I'm going to try your solution, but since I'm new to actionscript, I might have a hard time following it... I'll keep you posted.

    wiReZ, I followed the tutorial, but it still only showed the "value" field as text in my swf... it didn't switch it to a link for some reason. here is the output:

    Go to <A HREF="http://www.macromedia.com">Macromedia's website</A>

    It wasn't hard to follow, yet it didn't work. maybe cuz I'm using flash MX?! which shouldn't be the issue.
    Great minds discuss ideas; Average minds discuss events; Small minds discuss People.

  5. #5
    Member
    Join Date
    Aug 2002
    Posts
    89
    Go to Macromedia's website
    it worked in FK, but not in flash MX

    the actuall output was:

    Go to HREF="http://www.ma cromedia.com">Macromedia's website
    Great minds discuss ideas; Average minds discuss events; Small minds discuss People.

  6. #6
    Senior Member
    Join Date
    Mar 2003
    Location
    Maryland
    Posts
    378
    Originally posted by 7amood
    it worked in FK, but not in flash MX

    the actuall output was:

    Go to HREF="http://www.ma cromedia.com">Macromedia's website
    PHP Code:
    <a href="http://www.macromedia.com">Macromedia's website</a> 
    Should work if HTML rendering is on, if it doesn't you're either

    a: using a static text box

    b: you're doing something wrong, post the .fla you jsut did this in

    EDIT: The stupid admin who runs these boards put on parse HTML tags, yeah real smart move
    Last edited by kasracer; 05-12-2003 at 12:21 AM.

  7. #7
    Member
    Join Date
    Aug 2002
    Posts
    89
    there ya go
    Attached Files Attached Files
    Great minds discuss ideas; Average minds discuss events; Small minds discuss People.

  8. #8
    Senior Member
    Join Date
    Mar 2003
    Location
    Maryland
    Posts
    378
    Originally posted by 7amood
    there ya go
    Uh... you didn't turn HTML rendering on turkey

    Its the button that looks like <>. Try pressing it. You gotta select the textbox first to get the button

  9. #9
    Member
    Join Date
    Aug 2002
    Posts
    89
    being in a rush... I had the box next to it clicked thinking it was right one

    but still... this doesn't solve my problem since it applies the link on the whole textbox rather than some text within it...
    Great minds discuss ideas; Average minds discuss events; Small minds discuss People.

  10. #10
    Senior Member
    Join Date
    Mar 2003
    Location
    Maryland
    Posts
    378
    Originally posted by 7amood
    being in a rush... I had the box next to it clicked thinking it was right one

    but still... this doesn't solve my problem since it applies the link on the whole textbox rather than some text within it...
    Uh... it didn't do that for me, it rendered only onto the text... are you smoking something?

  11. #11
    Member
    Join Date
    Aug 2002
    Posts
    89
    Originally posted by kasracer
    Uh... it didn't do that for me, it rendered only onto the text... are you smoking something?
    danm...u cought me ... want some?

    I'll take another look at it when i'm sober... cheerz
    Great minds discuss ideas; Average minds discuss events; Small minds discuss People.

  12. #12
    Member
    Join Date
    Aug 2002
    Posts
    89
    kasracer, my original question still holds. where did my other text go? all I can see is the link. here is the file I'm working on.
    Attached Files Attached Files
    Great minds discuss ideas; Average minds discuss events; Small minds discuss People.

  13. #13
    Senior Member stoc's Avatar
    Join Date
    Nov 2001
    Location
    Romania, Arad
    Posts
    428
    in A tag , use apostrophes - not commas(macromedia spec.)

  14. #14
    Member
    Join Date
    Aug 2002
    Posts
    89
    Originally posted by stoc
    in A tag , use apostrophes - not commas(macromedia spec.)
    I don't see any commas in my code. I'm not sure what you are refering to
    Great minds discuss ideas; Average minds discuss events; Small minds discuss People.

  15. #15
    Senior Member stoc's Avatar
    Join Date
    Nov 2001
    Location
    Romania, Arad
    Posts
    428

  16. #16
    Member
    Join Date
    Aug 2002
    Posts
    89
    Originally posted by stoc
    http://www.s-toc.com/f_kit/projects_2.html
    stoc, you've just replaced my link with yours

    I still don't see my original text above, below, or around this link. I'm not sure if you understand the situation... whenever I add the link the way you just did, I loose my original text that I had before starting this whole thing.
    Great minds discuss ideas; Average minds discuss events; Small minds discuss People.

  17. #17
    Senior Member stoc's Avatar
    Join Date
    Nov 2001
    Location
    Romania, Arad
    Posts
    428
    but its ABSOLUT normal to lose Ur initial text ... if U assign to that variable other value ....don t u think!?!??!!!!!!!!!!!!!!???

  18. #18
    Member
    Join Date
    Aug 2002
    Posts
    89
    Am I supposed to enter ALL this text as a variable?!! if so, how am I gonna keep the format?!

    I am new to this whole actionscript manipulation thing, so if you would like to help.. please bare with me.
    Great minds discuss ideas; Average minds discuss events; Small minds discuss People.

  19. #19
    Senior Member stoc's Avatar
    Join Date
    Nov 2001
    Location
    Romania, Arad
    Posts
    428
    U can use a txt file :

    myfile.txt content:

    &myvar=a lot of text here ...and now ... <a href='http://www.yoursite.com'>my site</a> the rest of the text ...


    ...

    and in fla :

    loadVariables("myfile.txt",0)

    ...

  20. #20
    Senior Member stoc's Avatar
    Join Date
    Nov 2001
    Location
    Romania, Arad
    Posts
    428

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