Display JPEG in Browser from Flash

Hi All,
I'm working on a Flash project that will be distributed via
CD or DVD. I need to include several jpegs in the Flash file that
can be opened in the user's browser by a simple mouse click when
the user runs the Flash program from their CD/DVD player.
Any help would be much appreciated. I'm a nOOb and need help!
Many Thanks,
Scott

unless you import the image to the stage, an image will never
be included inside the flash file. If that is what you want though,
it would work something like this...
Import all of your art work (jpgs etc) to the library. Create
a movie clip which contains x number of frames where x is the total
number of art work items you want to show. On each frame of your
clip, place a single image that you want shown.
Drop this clip on the stage and name it images or something
similar. My code below will reflect a name of images....
Now instead of calling getURL from your button, you'd instead
do a
images.gotoAndStop(X);
where x is the number of the frame the image you want shown
resides. This method won't use a web browser instead it will show
the image inside the projector.
If you absolutely insist on it opening the image in safari or
IE or Mozilla, you will need to include the images on the CD or if
you can guarantee that the clients seeing this will indeed have an
internet connection, you can place the images online and then use
getURL to direct them to that location instead. There are numerous
options, but each has it's pros and cons.
Since this is a kiosk, this should not present any issues. If
you want to post this on the web though, at some future date, I'd
choose to use one of the two different getURL options since they
provide the greatest amount of flexibility.

Similar Messages

  • Displaying Japanese in Browser from MySQL query

    Hi All,
    I have the following jsp where I am trying to query a MySQL database for japanese words and display them on a web page.
    <html>
    <head>
    <%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%>
    <%@page import="java.sql.*" %>
    </head>
    <%
    String connectionURL = "jdbc:mysql://localhost:3306/japanese?user=;password=";
    Connection connection = null;
    Statement statement = null;
    ResultSet rs = null;
    %>
    <body>
    <%
    Class.forName("com.mysql.jdbc.Driver").newInstance();
    connection = DriverManager.getConnection(connectionURL, "root", "");
    statement = connection.createStatement();
    rs = statement.executeQuery("SELECT kanji, kana, english FROM vocab");
    while (rs.next()) {
    out.println("Kanji: " + rs.getString("kanji")+"<br>");
    out.println("Kana: " + rs.getString("kana")+"<br>");
    out.println("English: " + rs.getString("english")+"<br>");
    rs.close();
    %>
    </body>
    </html>But when I run this through my browser (http://localhost:8180/japanese/mysql.jsp) I get the following output:
    Kanji: ???
    Kana: ??????
    English: elephant
    I am using:
    * mysqld Ver 5.0.22-Debian_0ubuntu6.06.3-log for pc-linux-gnu on i486 (Debian Etch distribution)
    * Apache/Tomcat 5.0
    * java-6-sun
    Can someone please tell me what I need to do?

    That is fine, but has following limitations.
    (1)     Blob has limitation of size of 4kb and you cannot afford to load heavy objects in session which messes performance
    (2)     Content type (gif/jpeg) dependency, I need to explicitly declare content type.
    (3)     I need to know the size of image
    Hence following one of the ways is suggested to store
    and retrieve. Use <iamge src to
    retrieve the file
    Steps involved in displaying image from the database
    works with post Oracle 9i
    (1)     Provide read permission to the Oracle account to
    read the file from a directory
    (2)     Create an image table that contains
    ordsys.ordimage column.
    (3)     Upload the file into Oracle Database in
    ordsys.ordimage column table using a procedure.
    (4)     Provide java file write permission to the Oracle
    account.
    (5)     Export the file from the Oracle Database to
    output directory.
    (6)     Read the file in JSP using src image tag
    Regards,
    Shankar G. Pednekar

  • Open PDF in browser from Flash

    I want people to be able to click a link in my Flash site and
    for Acrobat to open the PDF, or have it open in their browser,
    instead of downloading the PDF to their desktop. Thanks!

    You can click on the button/ go to windows/ behaviors/ click
    on the drop down list of the plus sign symbol/ web/ go to web page/
    then you put NameofyourFile.pdf......... But I have an extra
    question if someone could help when i publish my movie after doing
    this the file opens twice why is this happening how can i fix
    this?

  • Display in PDF Browser - Item failed to convert in Outlook

    Display in PDF Browser - Item failed to convert in Outlook
    ben soules - 09:26pm Aug 22, 2007 Pacific
    Hi Experts,
    This is a bit of a pain I have to distrubte
    Adobe Acrobat Pro 8.1 to about 3000+ users and I am having a problem,
    In Prefs in "Adobe Acrobat Pro 8.1"
    When I tick then untick, "display in PDF Browser" from the Preferences, My Outlook will fail to convert to PDF. I get an "Item failed to convert" message and a log file. Also Word 2003 will not post a .PDF to an email.
    If I restart "Outlook 2003" it will create a "pdf" when I click the icon the first time, the second time I click it will fail.
    Please help.
    ===================================================
    Requested: 1,
    Converted to PDF: 0,
    Skipped [Already in PDF]: 0,
    Skipped [PDFMaker failed to convert]: 1
    Details of Email to PDF conversion:
    Failed to Convert:
    From: WS XXXX XX XXXXXXX, Subject: FW: testing, Date: 8/08/2007, Status: Item failed to convert

    We also deployed 8.12 to over 1000 users with the "Disable PDF in browser" option checked using the customization wizard. Now we're finding some users need it to view certain PDFs in a web-based application.
    We would like to add the option, but removing the registry key doesn't actually install the option when you check it. It seems you might have to create a new mst then redeploy. We'd really like to not have to do that, if at all possible.
    In the Reader archives, one guy suggested running this:
    msiexec /i Adobe_Reader_8.1_MUI.msi ADDLOCAL=ReaderBrowserIntegration
    I haven't tried that yet. Any feedback or other suggestions?
    E Long
    Austin, TX

  • Generate JPEG from Flash

    I have this Flash application that'd allow users to select
    cliparts, enter text to create custom designs. At the end of the
    process, I want them to be able to capture the design area and save
    it as a JPEG file. I can get Flash to pass the pixel information of
    the movie screen, but I can't figure out how to get CF to generate
    the image on the receiving end. I searched online and found a
    couple of PHP examples on dynamically generating JPEG files from
    pixel information passed from Flash - is there a Coldfusion
    equivalent of that? thanks in advance.

    thanks! recreating PHP in CF might be the better choice.
    below is the PHP code - is there a CF equivalent to
    imagecreatetruecolor? thanks again!
    <?php
    error_reporting(0);
    * Get the width and height of the destination image
    * from the POST variables and convert them into
    * integer values
    $w = (int)$_POST['width'];
    $h = (int)$_POST['height'];
    // create the image with desired width and height
    $img = imagecreatetruecolor($w, $h);
    // now fill the image with blank color
    // do you remember i wont pass the 0xFFFFFF pixels
    // from flash?
    imagefill($img, 0, 0, 0xFFFFFF);
    $rows = 0;
    $cols = 0;
    // now process every POST variable which
    // contains a pixel color
    for($rows = 0; $rows < $h; $rows++){
    // convert the string into an array of n elements
    $c_row = explode(",", $_POST['px' . $rows]);
    for($cols = 0; $cols < $w; $cols++){
    // get the single pixel color value
    $value = $c_row[$cols];
    // if value is not empty (empty values are the blank pixels)
    if($value != ""){
    // get the hexadecimal string (must be 6 chars length)
    // so add the missing chars if needed
    $hex = $value;
    while(strlen($hex) < 6){
    $hex = "0" . $hex;
    // convert value from HEX to RGB
    $r = hexdec(substr($hex, 0, 2));
    $g = hexdec(substr($hex, 2, 2));
    $b = hexdec(substr($hex, 4, 2));
    // allocate the new color
    // N.B. teorically if a color was already allocated
    // we dont need to allocate another time
    // but this is only an example
    $test = imagecolorallocate($img, $r, $g, $b);
    // and paste that color into the image
    // at the correct position
    imagesetpixel($img, $cols, $rows, $test);
    // print out the correct header to the browser
    header("Content-type:image/jpeg");
    // display the image
    imagejpeg($img, "", 90);
    ?>

  • Display a BLOB data from Oracle in the browser

    Hello,
    I am trying to display Oracle BLOB(ie ORDSYS.ORDVIR) directly in the browser using ASP.
    It is working in SQL Server, but Oracle seems to be giving a problem...
    The code written in ASP is as follows :
    <%
    'Clear out the existing HTTP header Response.Expires = 0
    Response.Buffer = TRUE
    Response.Clear
    ' Change the HTTP header to reflect that an image is being passed.
    Response.ContentType = "image/jpeg"
    Set cn = Server.CreateObject("ADODB.Connection")
    cn.Open "UID=cbir;PWD=cbir;DSN=trying"
    ' Here thumbnaildata is of type ORDSYS.ORDVIR
    SQLQuery = "SELECT thumbnaildata from image where imagekey='1.JPG'"
    set rsBlob = cn.Execute(SQLQuery)
    Response.BinaryWrite rsBlob(0)
    rsBlob.Close
    Set rsBlob = Nothing
    Response.End
    %>
    The the following is displayed in the browser
    after the asp is executed...
    <font face="Arial" size=2>
    <p>Provider</font> <font face="Arial" size=2>error '80004005'</font>
    <p>
    <font face="Arial" size=2>Unspecified error</font>
    <p>
    <font face="Arial" size=2>/ASPSamp/oracbir/sujal/imgtrialora.asp</font><font face="Arial" size=2>, line 38</font>
    NB:- Line 38 is where the query is executed. i.e set rsBlob = cn.Execute(SQLQuery)
    Could you tell me what I did wrong? I am using Oracle 8.1.6 on Win NT..
    Does field of type ORDSYS.ORDVIR have extra info stored along with the image which needs to be removed before displaying the image..
    null

    Since ODBC does not understand Oracle object types, you must select the BLOB locater, not the VIR Object.
    One you've done that you need to loop over the data in the BLOB, pushing it out the Binary response object.
    You may also want to select the mimetype from the VIR object and use that value to set the content type of the response object.
    Here's a piece of code that does the job:
    strSQL = "SELECT t.IMAGE_THUMB.getMimetype(), t.IMAGE_THUMB.getContentLength(), t.IMAGE_THUMB.getContent() FROM IMPB.IMAGE_ITEMS t WHERE IMAGE_ID = 1"
    set rsOrdMediaSource = Server.CreateObject("ADODB.Recordset")
    rsOrdMediaSource.ActiveConnection = "dsn=impb_imperf;uid=impb;pwd=impb;"
    rsOrdMediaSource.Source = strSQL
    rsOrdMediaSource.CursorType = 0
    rsOrdMediaSource.CursorLocation = 2
    rsOrdMediaSource.LockType = 1
    rsOrdMediaSource.MaxRecords = 1
    rsOrdMediaSource.Open()
    If rsOrdMediaSource.EOF Then
    Response.Status = "404 Not Found"
    Response.End
    End If
    Dim blob
    Dim bytesToGo
    bytesToGo = rsOrdMediaSource.Fields.Item(1).value
    Dim vBuffer
    set blob = rsOrdMediaSource.Fields.Item(2)
    If Response.Buffer Then Response.Clear
    Response.Buffer = false
    Response.ContentType=rsOrdMediaSource.Fields.Item(0).value
    While bytesToGo > 0
    vBuffer = blob.getChunk(CLng(32768))
    Response.BinaryWrite(vBuffer)
    bytesToGo = bytesToGo - 32768
    Wend
    Reponse.End
    null

  • Browser can resolve, access, and display JPEG image, but ImageIcon can't.

    I've got this weird problem that only happens with images accessed through a customer's VPN:
    Microsloth Internet Imploder can resolve, access, and display a JPG image from a VPN URL, in the general form:
    http://intranet/part?FOOBAR.JPG which the browser apparently transmogrifies into
    http://mogrify.foo.com/images/scripts/cgi/detail.cgi?FOOBAR.JPG(as Jack Webb often said, the names have been changed to protect the innocent)
    Firefox can also resove, access, and display the image.
    But an ImageIcon, when fed either URL, quietly fails to get anything, No errors, no exceptions, but no image, either.
    The application, if it detects the failure of ImageIcon to come up with the image, somehow (not my code) defers to "Windoze Image and Fax Viewer," which locks up trying to resolve, access, and display the image.
    What could possibly be going on here?

    I'd love to have the luxury of saying, "You lost me at Windoze." Then again, to paraphrase a running gag from Airplane!, it looks like I picked the wrong week to quit hemlock.
    As my final message on my other thread on this topic indicates, the problem is that even though the URL ends in JPG, the server isn't really serving up a JPEG, but rather, an HTML page containing the JPEG.
    Knowing this, a solution (of sorts) presented itself: if the URL doesn't produce a displayable ImageIcon, try constructing a JEditorPane on the URL. The results aren't exactly pretty, and you do have to try the ImageIcon first, but it does work.
    JHHL

  • Displaying jpegs from folder

    Hi,
    I would like to display jpegs from a folder, and be able to somehow scroll through them?
    So far i have been able to display them by using listfolder and linking it to a for loop containing readjpeg, but this basically creates a slideshow of jpegs. I would like to control which jpeg is being displayed by having 2 buttons, one to go through the pictures, and one to go backwards. .
    I hope this makes sense, I'm new to LabVIEW.
    Any help would be greatly appreciated!
    Attachments:
    VIEW_JPEG.vi ‏14 KB

    here is one simple possibility. 'hope it make sense.
    LabVIEW Champion . Do more with less code and in less time .
    Attachments:
    VIEW_JPEG_MOD.vi ‏22 KB

  • Opening a new browser window from flash

    Does anyone know of a method fo opening a link in a new
    window in firefox from within flash that isn't blocked by the popup
    blocker. It seems like the security in FF 2.0.0.6 (I'm on 2.0.0.11)
    has been tightened to prevent any _blank or window.open calls from
    flash getting through. I've tried the standard getURL, fscommand
    and ExternalInterface call to a javascript window.open method.
    Nothing now works.
    I understand the need for the popup blockers, but this is a
    legitimate popup only invoked on user interaction (click) - the
    same window.open call in an onClick event outside of flash works
    fine and I guess it is blocked from within flash because there is
    no way of knowing if the call is invoked from user interaction or
    automatically - but seems a shame.
    So any other way of getting a new browser window to open from
    within flash in firefox?

    Use target="_blank" in your form declaration.<FORM METHOD=POST ACTION="someAction" TARGET="_blank">The _blank keyword tells the browser to load the results in a new window.
    If you need more control over your window (size, address bar, etc.) you'll need to use javascript.<SCRIPT>
    function submitForm(windowName){
       newWin = window.open("",windowName, "menubar=no,resizable=no,...");
       document.myForm.target = windowName;
       document.myForm.submit();
    </SCRIPT>
    <FORM NAME="myForm" METHOD=POST ACTION="some.jsp" TARGET="">
    <INPUT TYPE=BUTTON VALUE="Submit" onclick="submitForm();">
    </FORM>

  • How do I open a new browser window from Flash

    I wish to open a new browser window from Flash and when the new window closes to return to the location from whence I started.
    ThomasChen

    The command to open a new window would be the "_blank" part of a command to link to a web page in the code below.
    navigateToURL(new URLRequest("http://www.anothersite.com", "_blank"));
    As far as the new window closing and getting back to where you were in the original window, I don't understand where that original window might have gone to... You should be wherever you last left it.

  • Launching Flash in the browser from the command line

    I am writing behavior test Flash using external interface in Flash, JavaScript in website and Selenium WebDriver in my program. All test is runing on Windows Server 2008 R2 within Internet Explorer 9. Everything works fine when remote desktop is connected to server (turned on). But when remote desktop is disabled, Flash doesn't work in browser. Program executes fine, browser is spawned, but JavaScript does not get response from Flash. I am running test on server from Jenkins using command line. How to resolve this problem? Maybe cheat Windows or Flash telling it, that remote desktop is connected? But how?

    Place the Timeline playhead on the clip, press f. The original (source) clip should load into the viewer.
    -DH

  • Print a webpage direct from flash

    hi all i have input text field that the user type a number EX
    : 223344
    and when he click the send button the browser open the page
    EX :
    http://mysite/223344.htm
    it is done now
    what i want that if this page is exist i want from flash to
    print it directly without open it
    and if not exist a message to the user said to him that
    ensure the number is correct
    plz help me
    i prefere that the print dialog not appear to the user
    because it is touch screen and i know the default printer

    you can load an html page into flash and assign it to a
    html-enabled textfield but only the most basic tags can be handled
    by flash.
    in addition, any graphics used won't be displayed (unless the
    html page is in the same directory as the swf's embedding html
    file).

  • Problem displaying dynamically loaded text in Flash CS3

    I created a Flash CS3 application that does not display
    dynamically loaded text (from internal AS3 scripts) on 3/6 of my
    client's computers. All computers run IE 6 and Flash Player 9. I
    cannot replicate the problem on any computer in my department. The
    problem seems to be related to Flash Player 9 or a browser
    setting/IT restriction. Has anyone encountered this? If so, have
    you found a solution?
    If I cannot find a solution, then I will need to almost
    completely redo the application.
    One slightly insane idea I have considered is to, if
    possible, convert dynamically loaded text to an image real-time. Is
    that possible?
    Btw, I have created a font in my library. Should I try
    manually embedding the font from the Properties menu and selecting
    all characters?
    Thanks in advance.

    yes, even though you may be using a font from the library,
    you still have to specify that each text field that uses that font
    embeds the font, and you'll need to select all characters(well not
    all, unless you require all the different scripts of the world -
    upper-case, lower-case, numerals and punctuation usual suffices).
    I bet if you checked, the computers where the font did not
    appear did not have the font on their system.
    Good luck
    Craig

  • The window title bar displays incorrectly after publishing a flash file.  Captivate 4

    When I open the .htm file after using the Flash option to publish, the wrong title displays in the title bar at the top of Internet Explorer's window; instead it displays a former file name.  I was told that the window name is determined by the field located here: File> Document Info> Project Name; however, this is not the case on my PC.  My coworker is able to publish it correctly, but I am not.  The first picture below is the IE title bar and the second is where (I think) that title bar pulls from, Project Name.  Please notice that mine differ.  Any suggestions?

    I've run into this issue in CP4 as well though I've never been sure why it happens. It looks like you're opening the swf through a browser to so, for want of a solution, the easiest workaround is the edit the html file.
    open it in a text editor such as Notepad.
    Five or six lines down you'll find the title element which defines the title as it will display in your browser titlebar:  <title>This text is the title that displays in your browser title bar</title>
    Just change the text the the title you want and save the html file.
    If you go with this solution, I suggest that when you are publishing the project again you deselect the option "Export HTML" in the publish wondow. Otherwise you will have to edit your html file each time you publish.
    Hope this helps.
    Niamh

  • XML editing from flash, any idea, suggestion

    Hello,
    I have created for a client a website dynamically loaded with
    XML formatted content (XML Files), now the client wants to be able
    to edit the contents of its site (CMS), the site displays several
    things but more specifically a list of products, which you can see
    by browsing the "PRODUCT RANGE" section of
    http://www.cellap.com/.
    I planned to use a php to rewrite the XML with the edited
    data sent from the flash (oldData, newData), it works fine, except
    that there are several problems:
    -I use the "ereg_replace" command of PHP, which seems not to
    handle correctly special charachters such as "*"...
    -If the php is told to replace i.e. "FACE" with "FIGURE", it
    will replace it everywhere on the XML, which is not what I want; so
    maybe I'm not using the right technique; I know it'd be more easy
    to do if the content was on a MySQL database, but the client wanted
    XML, to be able to browse the site offline...
    Any help or suggestions would be greatly appreciated!
    Tks

    loading yes. editing no.
    you need some sort of server script to do the editing(php,
    asp, cmf)
    Dan Mode
    *THE online Radio*
    http://www.tornadostream.com
    *Must Read*
    http://www.smithmediafusion.com/blog
    *Flash Helps*
    http://www.smithmediafusion.com/blog/?cat=11
    "ELTIGRE" <[email protected]> wrote in
    message
    news:e94vsk$fjb$[email protected]..
    > is it posible Loading and Editing xml data from flash
    without any
    > programing language using actionscript only?

Maybe you are looking for

  • How can i increase the ram size for my applet

    Hi all, I am trying to load my applet on a schlumberger simera 3 classic card. the applet runs fine on the simulator, but when i run the applet on the card , it crashes after 2 or 3 proactive commands. Is it because i could be out of memory or stack

  • Error - ORA-01843: NOT A VALID MONTH

    I get this Error when I execute a procedure which accepts input paramters to insert into a table. I tried using TO_DATE(Input_param,'MM/DD/YY') too but it still gives me the error. Plz. Help.

  • Automatic creation of PR from sales order (SO) for the materials compement

    Hi I would like to create un PR from a sales order , but only for the material component (defined on Tcod CS01) I already know how to create un automatic PR from SO By using the TAS post type But the problem is that this method create only a PR for t

  • How does the fault system work with AppleCare warranty extension?

    I'm an owner of an iPhone 4S on Telus Mobility in Canada and I have two year AppleCare warranty extension that is linked to my phone. I've had my iPhone for over a year now with no issues, so this question is meant for reference if and when I do need

  • SCCM 2012 R2 IP for Orchestrator 2012

    Hi, We have Orchestrator 2012 (7.0.1154.0) installed, and I would like to connect it to our SCCM 2012 R2 (5.0.7958.1303) installation with an integration pack. Does anyone know if I can connect a non-R2 Orchestrator to an R2 SCCM and if so, which IP