Add to Google

Displaying Html In Flash - Using ActionScript

free web hosting
Open Discussion > CONTRIBUTE > The Internet > Web Design

Displaying Html In Flash - Using ActionScript

BlueInkAlchemist
Since ActionScript.org appears to be down, I'm going to annoy you all with more design questions. wink.gif

I know I can use the getURL and URLLoader classes to bring HTML content into Flash. But can these also be used if I only want to show part of an HTML page? For example, if the content I want to show is in a <div> tag, and that's all I want to show, how would I go about calling for that part of the HTML source?

Thanks in advance...

Comment/Reply (w/o sign-up)

Nabb
Using javascript, it's something like document.documentElement.innerHTML=document.getElementById('lolz').innerHTML (could be wrong though)

I'm not sure how you'd integrate that into Flash though..

But if you have the source as a string, can't you use indexOf and substr to get that? Or something...

Comment/Reply (w/o sign-up)

galexcd
I think it would be easier to make a php page to load the html page you want to, parse out everything except the contents in the div, and then have flash load your php page. Perhaps if you were a bit more specific I could whip up a php script to do this for you.

Comment/Reply (w/o sign-up)

BlueInkAlchemist
QUOTE(galexcd @ Nov 26 2008, 01:41 PM) *
I think it would be easier to make a php page to load the html page you want to, parse out everything except the contents in the div, and then have flash load your php page. Perhaps if you were a bit more specific I could whip up a php script to do this for you.


Basically, what I want to do is, within a Flash movie, when a navigation button is selected, a content area (a MovieClip more than likely) should be populated with formatted text from an outside page.

Also, this is going to be hosted on my domain which is currently held by Microsoft Office Live, meaning it's an ASP-based site. It'll be ASP wrapped around Flash, but still.

Comment/Reply (w/o sign-up)

galexcd
Well I'm not that familiar with ASP, but you should be able to do the same thing. Basically instead of having flash load that certain external page, have flash load an ASP page you created, which loads and parses the external page.

Comment/Reply (w/o sign-up)

BlueInkAlchemist
QUOTE(galexcd @ Nov 27 2008, 01:19 AM) *
Well I'm not that familiar with ASP, but you should be able to do the same thing. Basically instead of having flash load that certain external page, have flash load an ASP page you created, which loads and parses the external page.


What about XML? For example, within Flash, ActionScript will read the nodes of an XML file which contain external file names, corresponding variables, etc. On an event (a Mouse Click more than likely), the selected variable will load the corresponding external file in a content area. That's the rough idea.

Comment/Reply (w/o sign-up)

galexcd
Well if you are planning to do it like that you would be better off using actionscript string parsing function such as split.

For example:
CODE
String cont;  //Or whatever the name of your content variable is

temp=cont.split("<div>");
temp2=temp[1].split("</div>");
cont=temp2[0];

Comment/Reply (w/o sign-up)

actuarymath
QUOTE(BlueInkAlchemist @ Nov 26 2008, 03:07 PM) *
Since ActionScript.org appears to be down, I'm going to annoy you all with more design questions. wink.gif

I know I can use the getURL and URLLoader classes to bring HTML content into Flash. But can these also be used if I only want to show part of an HTML page? For example, if the content I want to show is in a <div> tag, and that's all I want to show, how would I go about calling for that part of the HTML source?

Thanks in advance...


How about flashprobe?
http://www.flashprobe.com/

Comment/Reply (w/o sign-up)

galexcd
QUOTE(actuarymath @ Nov 27 2008, 10:24 PM) *
How about flashprobe?
http://www.flashprobe.com/


BlueInkAlchemist is trying to get html into flash dynamically, not extract text and images from flash, which is what this tool seems to do. He would need to either have flash or some other server side script parse the html and have flash load the content when the swf is played.

Comment/Reply (w/o sign-up)

BlueInkAlchemist
QUOTE(galexcd @ Nov 27 2008, 11:44 PM) *
Well if you are planning to do it like that you would be better off using actionscript string parsing function such as split.

For example:
CODE
String cont;  //Or whatever the name of your content variable is

temp=cont.split("<div>");
temp2=temp[1].split("</div>");
cont=temp2[0];


I'll have to try this out, see if it will preserve HTML text formatting when taken from the source page into Flash...

Comment/Reply (w/o sign-up)



Got an Opinion! Express your Views! (no registration):-
Add your Reply/ Opinion/ Views/ Comments/ Suggestion/ Questions/ Queries etc.
Posts with decent grammar & English will be accepted and please refrain from profanities.
For asking a Question, We recommend you to sign-up (for free) so that you can track the topic easily.

Nature of your Post*: Opinion/ Reply/ Comments
Question/Query
Feedback to us.
       
Name   Email
Title/Question*

Recent Queries:-
  1. html flash logo codes - 2.09 hr back. (1)
  2. flash html content - 28.37 hr back. (1)
  3. how to make words flash in html - 56.81 hr back. (1)
  4. html flashing word - 61.86 hr back. (1)
  5. flash load html content - 71.77 hr back. (1)
  6. flash load html page - 72.15 hr back. (1)
  7. flash load asp - 72.44 hr back. (1)
  8. flash load html - 106.51 hr back. (1)
  9. flash html if loaded - 111.27 hr back. (1)
  10. flash actionscript display page - 126.19 hr back. (1)
  11. flash parse html - 156.27 hr back. (1)
  12. parse text actionscript - 227.65 hr back. (1)
  13. html flashing texts - 235.61 hr back. (1)
  14. displaying html in flash - 246.20 hr back. (1)
Similar Topics

Keywords : displaying, html, flash, actionscript

  1. Help Me Flash My Website.
    web designing (7)
  2. How To Add The Flash In Our Website ?
    Animated image in website make the site atractive, but take more time (3)
    Animation in this world: We see in most of the website that company icon, logos, memorandom,
    Advertisement, smily,even todat Button etc. in the website are animated in a sequencial manner so
    any body who see this get impressed, even so many time i also get impressed and want to give thanks
    that one who creates this logic a fantastic idea, adobe website we read some articles, i want a
    proper process or command from starting to end till image(how many types of image) animated in my
    website. what software, hardware, required to do complete this task. any idea, tutorial, not....
  3. Website Structure
    PHP, MySQL, HTML, etc. (3)
    Hey guys, I am a very, VERY, curious person on finding out how things work on the computer if I find
    them interesting and I can't stop thinking about the thing until I find the answer. The sooner
    I find the answer, the less time I get a headache.

    So I was wondering how websites work. I mean how
    everything would be put together. Like how a game would be put together lin....
  4. Stop Your Html Codes From Being Stolen
    Stop your Html codes from being stolen on your HTML pages. (15)
    Hello people! Obviously a lot of people use these little scripts to stop you from right clicking on
    websites/HTML pages etc. I know many many people use near enough the same kind of coding as the one
    I just made. I decided not to put this in the Tutorials section because I know alot of other codes
    do exactly the same thing as this one I am going to be sharing with you! This code may be
    re-distributed if you wish. I have no copyright on it, but please put some kind of "Thanks for the
    no right-click script". Here it is: QUOTE oncontextmenu="return false" onselectsta....
  5. Flash Navbar: Populate From Center
    Looking for advice or a tutorial (0)
    I'm working with Flash CS3, ActionScript 3, and items in an XML document. I'm looking for
    advice or a tutorial on making a navigation bar that loads items dynamically and populates from the
    center of the bar rather than the left side. I know there'll be some coordinate math to be done,
    but I'm unsure where to begin. Can you suggest a site like gotoandlearn, or is there something
    already there that I'm missing? Thanks in advance.....
  6. Actionscript 3 & Xml Error #1010
    Why must it vex me so? (0)
    This post is about a project I'm working on in Flash CS3, using ActionScript 3 and an external
    XML file. I am trying to populate dynamic text fields in a movie clip generated by ActionScript
    using data from XML. The line is formatted like so (leaving out the array brackets to avoid code
    confusion): CODE clip.txt = xmlList.vname When I run the file like this, the movieclips
    appear but are empty. I then modify the code this way: CODE clip.txt.htmlText = xmlList.vname
    This generates Error #1010: "A term is undefined and has no properties." Can any ....
  7. Actionscript 3
    (0)
    Just a quick question... would discussions on ActionScript programming, ideas and troubleshooting be
    here, or in another forum? Thanks in advance.......
  8. Flash And Transparency
    (7)
    Hi folks. I want to know if its possible to modify the transparency of an image in flash to give a
    gradual transparent gradient? EG like the T17 banner where the text "Trap17" reflects. I know i
    can do this in the GIMP but i need the background of the image/text to be transparent, and GIF is
    the onyl format i can do that reliably and of course GIF is indexed and so i cant have a gradual
    fade effect. Im really stuck on this one and im no Flash expert so any ideas? Ive attached a
    screenie. Thats the effect i want (the black background is there so the effect is easy....
  9. Flippingbook Html Edition
    download FREE version (1)
    You can create professional online albums/books with this simple and convenient tool: FlippingBook
    HTML Edition . The main attraction with this Javascript+SWF application is the page-flipping or
    page-turning feature, like we are used to do with physical publications like books, magazines, etc.
    http://www.page-flip.com/downloads.htm this free version has several limitation however: up to 10
    pages only, and you gotta retain the copyright link embedded in it. of course there is the paid
    edition too, in case you want to use it beyond the limitations of the free version.....
  10. Flash Header Edit?
    flash header edit (2)
    Can someone help me edit a flash header from a template. I can figure out MX 2004. I am a novice web
    designer at best and need some help editing this header. Thanks so much ....
  11. Naming Web Page Files
    Which way you like- MyPage.html or my-page.html or my_page.html (9)
    Everybody talks about meta tags, keywords, good title names and how they can increase page rankings,
    etc. But I was wondering whether the page name itself holds any value in indexing. Yes, I am
    talking about the web page file names (some-thing.html) NOT the one which you put in title tags. I
    am going to express my views and want to know what you think is correct. I have seen pages named in
    various ways like these: 1) my_web_page.html 2) DoYouLikeMyPage.html 3) hey-see-my-webpage.html (I
    think this way is more appropriate) 4) this.is.a.page.html (somewhat confusing) ....
  12. Cms For Video, Embedding Flash
    (2)
    Hello, I was wondering if anyone knew of a good open source CMS that allows dynamically embedding
    flash videos such as those from youtube (needs to be able to embed flash with parameters), and also
    allows uploading any type of file to the main server. Thanks! =)....
  13. What Is The Best Free Html Editor?
    (24)
    im looking for any kind that is free really.... i use windows but if you have one for a different
    platfor, go ahead and add it for reference for other users. If you have one for normal text editor
    and wysiwyg, add them both. i have been using notepad as my normal html editor but im looking for
    something different... at least so i can see the different colors of the codes. Right now i am
    downloading moxilla's seamonkey suite but im not sure how good it is... i will post a review if
    i ever use one. If you have used the html editor you suggest or you just heard abou....
  14. Html Problem
    (9)
    how to make my intro page in the middle not CENTER ....
  15. Scroll And Pan The Screen Via Mouse In Flash
    does anyone know how to pan across the screen using the mouse in flash (1)
    Hi Need help for a project , hope u guys could help out and teach me a little something. I saw some
    flash that if you click on a icon or if u point ur mouse to the left of the screen it will keep
    going left, and if right it'll keep scrolling right, as if ur checking out a room Or something
    like this website.. www.mcdonalds.com.au , and choose broadband if you see on that site, when user
    clicks on the icon to the right. the rest of the icons would kinda shift.. does anyone know how to
    do that or know if there is anywhere out there a tutorial to do that? if u do.. it&....
  16. Flash Media Into Html/css Website
    does anyone know how to import a flash into a webpage with transparenc (3)
    Hi I need some help , Im designing this website for school studies However, I made a flash drop down
    menu, works perfectly, but you know how flash has a background when you export it in to a SWF file?
    For example my flash is width= 800, and height = 200 but my div box on my html page for my
    navigation is only 50 px my buttons is width of 50px and the rest of the content is the drop down
    animations i want to insert it into my navigation div box but i want to set the flash background to
    transparent so that when the drop down menu comes down it overlaps the text or whateva....
  17. Flash Newbie Question
    question (3)
    hello i'm new to flash. i have a .swf movie which i decompiled with Sothink SWF Decompiler in
    .fla and I also exported the resources. so far so good, i entered the resources directory,i changed
    the names and texts with my own and now I am wondering how do i rebuild the whole "resources"
    directory as a .swf ? can someone help ? thanks.....
  18. A Twist On Basic Authentification
    html help (4)
    Alright, i am working on a website where a number of different users from different companies will
    be looking hooking into one website. What i want is to know how i can differentiate between the
    users based on the information passed by the webserver. I've been told to that information
    will be passed along html_user(and if i have a distinct user then i can just query the database with
    that info and get what i want) But how does this work? I am sorry i know this is cryptic i'm
    kind of searching to see if this strikes a bell with anyone. So to sum, many user....
  19. Has Anybody Tried Ms Expression Web Html Editor
    It's much better than Frontpage (3)
    I was desperate to finish a site I was designing after I lost my hard drive and my software. I
    downloaded Expression Web from the Microsoft site for a 3 month free trial, and guess what? It's
    surprisingly good! Nothing like that crappy frontpage, it's standards compliant and very good
    for writing CSS. Haven't heard anybody mention the program and wondering if anybody else has
    tried it out. It's free to try from the MS site.....
  20. I Need Some Help With Flash And Div Overlay
    using wmode in IE problems (5)
    Hi guys, I have a problem with one of my designs at the moment. Here's the problem: I have a
    flash game in the middle of a page. However, the site navigation has dropdown menus that go on top
    of the flash. Now, the navigation works if I use "wmode = transparent" or "wmode = opaque" in the
    flash code. Yet, there is another problem: In Internet Explorer (I'm running version 7) the
    arrow keys "up" and "down" in most flash games will not work properly. Instead, they will make the
    page scroll up and down, even if the flash file has focus. This situation does not exi....
  21. Where Is There A Good Site To Learn Web Html?
    (20)
    im a noob when it comes to web html to design web sites, can some one tell me where to find a good
    website that has good tutorials on how to use web html?....
  22. Flash Actionscript Help
    i need help on some actionscript for flash galleries and such (10)
    Hi guys i was hoping if anyone that is good at coding could pretty please help me out im rather
    good at designing compared to coding for flash.. so here goes.. Im trying to make a flash gallery..
    ive started. and i know how to make buttons to go nxt and back and so forth... but i want to know if
    anyone knows the actionscript to make a thumbnail .. so that you click on it .and it will load the
    larger version on a little flash popup screen or just somewhere on the page.. its hard to explain
    but ill try to find an example to show u /smile.gif" style="vertical-align:middl....
  23. Help! Php Or Just Html?
    i want to start buliding my website. which is better, php or basic htm (16)
    i try to start this topic in webhost category but it seems like i cant. i dont have the permission
    so i just post my topic here. im sorry mod.. i want to build a website which contains: - Links to
    videos - Informations - photos - flash i don't know if i should use php or just HTML. guys,
    what are your opinions..??....
  24. A Small Html Problem
    How to display foreign characters correctly when designing a site. (5)
    I was wondering how I could solve a small problem. I was told that some people see accented and
    umlauted letters (such as " é " and " ë ") as question marks (" ? ") on my website. I come across
    the same thing sometimes when looking at websites which use non-English characters. Funnily enough,
    the other day, I looked at a site and the apostrophy ( ' ) was also shown as a question mark.
    That is a very common character usually, I would think. I thought it had something to do with the
    character encoding settings, and let me also mention I use Mozilla Firefox as my brows....
  25. Psd --> Editable Html
    (4)
    Here's the deal. I am new at working with web objects in photoshop. I have CS3, and I created a
    really nice template. I'm told I have to do something with slicing. So I have the template, and
    it has images, buttons, and text on the buttons, and text fields, etc. How can I export this to HTML
    and images, and be able to open it up in dreamweaver in an editable web page? I've tried
    exporting to "web and devices" and exporting as HTML and Images, but when I open it up in
    dreamweaver, it looks right, but it is all images. Thanks....
  26. Php Or Html?
    which do you use? (41)
    Well being a HTML its easy for me but what do people use the most? Is it HTML or PHP. It depends
    really on which you learnt first. So im gonna have a poll.Post HTML for Html and PHP for php and we
    will see which is more popular.....
  27. Giving A Flash Button A Link
    i get errors (6)
    oke well i made my button and i addet the actionscript to give the button an url,see the screenshot
    below now for some reason it gives me errors,and i don't know what i did wrong to be
    honest,so can some one help me out with this p.s i do use flash cs3 so i dunno maybe its another
    way to put an url on ur button with this version cause with flash pro8 and mx i never had a problem
    with this....
  28. Getting Flash Images On A Site
    (1)
    well, i don' t have a site yet, but about 6 months ago i made a template, with flash buttons and
    all, with sound and everything i was so proud so i tryed to put em on there with a special code u
    needet or something ,so i did, but i got blank images,, i even tryed uploading it on the site it
    didn't work, so i asked around they said u can' t install them on a cpanel, u need ftp, so i
    downloadet the program needet and i got stuck there, so basicly how do u do that,and could some1
    help me out how to get it working on a cpanel....
  29. Making A Scroll Bar In Flash
    with an image and words on it (6)
    does anybody know how to make a scrollbar for my game page I am making on my site. This whole site
    is completely in flash. I know how to make a scrollbar for just words but not when there is an
    image on there also. Does anybody know?....
  30. Best Free Flash Editor
    (9)
    Anyone know where I can find the best free Flash editor?....

    1. Looking for displaying, html, flash, actionscript
Similar
Help Me Flash My Website. - web designing
How To Add The Flash In Our Website ? - Animated image in website make the site atractive, but take more time
Website Structure - PHP, MySQL, HTML, etc.
Stop Your Html Codes From Being Stolen - Stop your Html codes from being stolen on your HTML pages.
Flash Navbar: Populate From Center - Looking for advice or a tutorial
Actionscript 3 & Xml Error #1010 - Why must it vex me so?
Actionscript 3
Flash And Transparency
Flippingbook Html Edition - download FREE version
Flash Header Edit? - flash header edit
Naming Web Page Files - Which way you like- MyPage.html or my-page.html or my_page.html
Cms For Video, Embedding Flash
What Is The Best Free Html Editor?
Html Problem
Scroll And Pan The Screen Via Mouse In Flash - does anyone know how to pan across the screen using the mouse in flash
Flash Media Into Html/css Website - does anyone know how to import a flash into a webpage with transparenc
Flash Newbie Question - question
A Twist On Basic Authentification - html help
Has Anybody Tried Ms Expression Web Html Editor - It's much better than Frontpage
I Need Some Help With Flash And Div Overlay - using wmode in IE problems
Where Is There A Good Site To Learn Web Html?
Flash Actionscript Help - i need help on some actionscript for flash galleries and such
Help! Php Or Just Html? - i want to start buliding my website. which is better, php or basic htm
A Small Html Problem - How to display foreign characters correctly when designing a site.
Psd --> Editable Html
Php Or Html? - which do you use?
Giving A Flash Button A Link - i get errors
Getting Flash Images On A Site
Making A Scroll Bar In Flash - with an image and words on it
Best Free Flash Editor

Searching Video's for displaying, html, flash, actionscript




advertisement



Displaying Html In Flash - Using ActionScript