How applet transfers data over HTTP

hello,
I found out that you cannot you sockets in applets (cannot create a socken on the client side) so I want to know how to transfer data over HTTP. What class should I use or some short example would be of much help.

You can make connections back to the same server the applet came from. If you need to make connections directly to other servers, then you can sign the applet, which will lift the security restrictions (provided users accept your signature as trustworthy).

Similar Messages

  • Recently bought new macbook pro , transferred data over and thought microsoft office would work on new laptop. Icons are there , although don't have my key codes!! should i just buy new software package ?

    recently bought new macbook pro , transferred data over and thought microsoft office would work on new laptop. Icons are there , although requires key codes and I don't have my key codes anymore as dog chewed the packaging!! should i just buy new software package ?  I am told that this is a microsoft issue not a mac issue !! But all my other data on the old macbook pro transferred over even the icons for office for mac on the bottom app bar. only now I can't open any of my word or excel files without key code! I thought that there may have been something that could be done before having to bite the bullet and fork out for new software package.??

    If this is Office for Mac 2011 then it will work on your new computer. Reinstall it. If you don't have the key code call Microsoft's activation line to get a new key code. Explain that you lost the original key code and want to install Office on your new computer.

  • Sending audio data over http problem

    Hi Guys,
    We are trying to create a little servlet in Tomcat, which is capable to send audio files over http to an embedded media player. The definition of the player looks like:
    <OBJECT ID="Mp" CLASSID="CLSID:6BF52A52-394A-11d3-B153-00C04F79FAA6" TYPE="application/x-oleobject" WIDTH="0" HEIGHT="0">
    <PARAM name="uiMode" value="none">
    <PARAM NAME="ShowControls" VALUE="0">
    <PARAM NAME="AutoStart" VALUE="1">
    <PARAM NAME="ShowPositionControls" VALUE="0">
    <PARAM NAME="ShowStatusBar" VALUE="0">
    <PARAM NAME="ShowDisplay" VALUE="0">
    </OBJECT>
    <script language="javascript">document.Mp.URL = "here comes the url of the servlet with item ID";</script>
    The servlet reads the audio file and writes its content to the response with the following http header settings:
    getResponse().setContentType("audio/x-wav");
    getResponse().setHeader("Content-Transfer-Encoding", "binary");
    getResponse().setHeader("Pragma", "Public");
    getResponse().setHeader("Cache-Control", "must-revalidate, post-check=0, pre-check=0");
    getResponse().setHeader("Content-Disposition", "inline; filename=Media.wav");
    getResponse().setHeader("Content-Length", new Integer(MediaBytes.length).toString());
    getResponse().setHeader("Accept-Ranges", "bytes");
    So, everything works fine for wav files in Internet Explorer, but we are facing problems with Firefox, where it does not work. The embedded Media Player says that "Windows Media Player cannot play the file. One or more codecs required to play the file could not be found."
    But if we set the url to directly to the file on the server, everything works fine.
    We have analyzed the HTTP traffic in both situation, but we cannot understand how Internet Explorer/Firefox and Media Player works together:
    - how does Media Player know that the audio file is playable?
    - if the url points directly to the file, the HTTP headers does not contain any kind of information about the file type, only the extension is available; Media Player checks the file extenion in the url?
    - if the url points to the servlet, why Media Player in Firefox cannot determine the file type and throws error?
    Any help is greately appreciated!
    Thanks!
    Gabor

    If you haven't already, I would try breaking down the problem. First confirm you're getting serial data then confirm that netcat can send some data. Like this:
    xxd < /dev/tty.usbmodemfa121 | less
    nc -u 10.0.1.3 7000 <<< 'hello over there'

  • New iMAC - How to move data over from PC?

    Hi,
    Just bought the new iMac 27" to replace my PC. What is the best way to move all my music, videos, and apps to the new iMAC?
    I have music bought from iTunes and downloaded from CDs - also have apps and videos bought from iTunes....
    So far all I can figure is use memory sticks to move the data over and then try to place all the stuff in the correct folders so iTunes will see it. But there must be a better way.
    thanks
    Rob

    Thanks for the info. So the links says I can simply take all my music, video, and photo files and move them to the iMac via a memory stick.
    I guess it doesn't matter if I bought the files on iTunes or if I had them on the PC via a CD?
    I'll start with trying to figure out how to get all the music, video, and photo files over to the iMac and getting iTunes to recognize them (like the PC did).
    Second, I'll need to hook up my iPhone to the iMac and sync. Anything I need to know before I do something like that?
    thanks,
    Rob

  • [SOLVED] How To Read Data Over /dev/ttyUSB0

    So...I am using a serial device connected to a Keyspan Serial-to-USB adapter and plugged in to my computer's USB port. The device is constantly sending 115200 baud data over UART, with no parity, 8 data bits, 1 stop bit, no flow control, and no handshaking. I can read the data just fine on my Windows machine (once I install the Keyspan driver). On Arch64, I notice that when I plug it in, /dev/ttyUSB0 shows up so I believe that means the kernel is recognising the device and already has drivers to handle it. I would like to simply see the output of the device through my terminal emulator so I have written the following script....
    stty -F /dev/ttyUSB0 115200 cs8 -cstopb -parenb
    while true; do
    read LINE < /dev/ttyUSB0
    echo $LINE
    done
    When I run this script as root, however, I get no output. I have also tried appending "-icanon min 1 time 1" to the stty arguments list but also to no avail. Can anyone help? Thanks!!
    Last edited by tony5429 (2009-10-30 20:59:30)

    Thanks, all for the responses!
    perbh: I wasn't sure exactly how to implement your suggestion. If the cat line doesn't use the variable, "$LINE", how can "echo $LINE" work? I am probably missing something simple...
    Well, I have had a little success. The following script creates blank lines whenever data comes in through the usb device. Basically the device sends FFT data whenever it hears a sound which is greater than a certain threshold, so when I snap my fingers near it I see the FFT data show up in Terminal on Windows. Now, with the script below, if I snap my fingers my Linux machine outputs a bunch of blank lines so basically I just see my linux terminal emulator scrolling whenever I snap my fingers Does anyone have any ideas how to get the actual data on Linux? Thanks again!
    stty -F /dev/ttyUSB0 115200 cs8 -cstopb -parenb
    while true; do
    read -n 8 LINE < /dev/ttyUSB0
    echo $LINE
    done

  • Extremely slow performance transferring data over USB with Time Capsule

    I have the 2TB wireless Time Capsule. I have it setup as an extension to my current WiFi at home, since I already had a WLAN router. I have an external harddrive (500gig) that I connected to my Time Capsule because I wanted to transfer data from the Time Capsule to the external HD. The external HD is formatted with FAT32 file system, so read/write is no problem.
    When, using my MacBook Pro, I navigated to the Time Capsule and dragged files over to the connected USB harddrive (connected directly in the Time Capsule), the performance to transfer is extremely SLOW! It was slower than doing the transfer completely wirelessly (USB drive connected to laptop and transfer wirelessly from TC)!
    I do not understand this at all! It should be a simple transfer using the USB connection! When I do a transfer from my laptop directly to the USB harddrive, with it connected directly to the laptop, the transfers are super fast!
    What happened? Can someone please explain this or tell me what I need to do?
    Thank you!

    I am still confused here.
    My original question was regarding the use of my USB external harddrive. It was connected to the back of the TC. The TC was wirelessly speaking to my WLAN router. Using my laptop (also wirelessly speaking to WLAN router), I navigated to the TC and saw 2 listings - one for the data on the harddrive in the TC and one for the new external USB drive connected to the back of the TC. I wanted to transfer data from the harddrive in the TC to the USB external drive. Based on what I expected, I thought the transfer rate would merely be limited by the USB 2.0 interface that is being used by the external drive. However, I was definitely wrong! The transfer rate (shown by the estimate in time to transfer the data by my MacBook Pro) was doubled to 14 hrs.
    Originally, it was only 7 hrs when the USB external drive is connected directly to my laptop and I connect to the TC wirelessly. Weird!
    So why doesn't the TC simply transfer the data from its internal harddrive to the external USB drive directly without using any wireless technology?
    The second question I have is regarding the setup of the TC itself. I have a NetGear WLAN router and its an "n" router. So the speed is good. I have my TC currently downstairs from the WLAN router. Therefore the TC is setup as simply a wireless harddrive. It speaks through the WLAN router in order to be available to all my laptops in my house. My question is whether it should instead be directly connected to the WLAN router using an ethernet cable? Would this improve my overall transfer rates to/from the TC?
    Thanks so much.

  • How to post  xml over http

    Hi experts,,
    My idea is to post XMl file from client application to server.
    user.XMl file will be created then and there dynamically based on user entered data.
    For this i have a .java program in client application.
    And one important thing is My XMl file contain image in binary data,, which is in Base64Encoded format.
                      <?xml version="1.0" encoding="UTF-8"?>
                    <FileAttachment>
                                         <UserName>krish</userName>
                                         <password>rao</password>
                                        <image type="jpg">
                                                   <PictureData>
                                                    QAAAAIAGtaMS2/u6RnIAAAAIYAAAAKAAAAYm
                                                          l0bWFwLmJtcHPybWOAADMg1gBiVihm
                                                      ZJAAiwcA8RE+CIaB/6iAYj4AUEsBAhQAFAAAAAgAa1oxLb+7
                                                     pGcgAAAAhgAAAAoAAAAAAAAA
                                                      AAAgALaBAAAAAGJpdG1hcC5ibXBQSwUGAAAAAA
                                                    EAAQA4AAAASAAAAAAA
                                             </PictureData>
                                        </image>
                     </FileAttachment>My .xml like above.. i have to post it to server . Some thing like http://myserver:8080/Requesthandler.java which recive the xml and parse it and do some other things.
    And one thing is My server at some location and my client application at other location.
    Plz do me some help as early as possible

    Thak u
    but i am sitting in front of laptop but i cant find perfect code match to me.
    Give me link if possible,
    <Product>
      <SKU>99238</SKU>
      <Description>Super Gidgetidoo</Description>
      <Picture>
    Content-Description: File encoded with ENCODE64.EXE.
    Content-Disposition: attachment; filename="foo.zip"
    Content-Transfer-Encoding: BASE64
    Content-Type: application/octet-stream
    UEsDBBQAAAAIAGtaMS2/u6RnIAAAAIYAAAAKAAAAYm
    l0bWFwLmJtcHPybWOAADMg1gBiVihm
    ZJAAiwcA8RE+CIaB/6iAYj4AUEsBAhQAFAAAAAgAa1oxLb+7
    pGcgAAAAhgAAAAoAAAAAAAAA
    AAAgALaBAAAAAGJpdG1hcC5ibXBQSwUGAAAAAA
    EAAQA4AAAASAAAAAAA
      </Picture>
    </Product> If my xml like above and its created dynamically based on client input.
    I find some code to post above xml, But it post an XMl file in hard disk
    it uses output stream to post , ie read every byte in xml and write to out put stream.like below
    response.setContentType("text/xml");
          response.addHeader("Content-Disposition", "attachment; filename="
              + fileName);
          response.setContentLength((int) xml.length());
          FileInputStream input = new FileInputStream(xml);
          buf = new BufferedInputStream(input);
          int readBytes = 0;
          while ((readBytes = buf.read()) != -1)
            stream.write(readBytes);But i want to post xml file as it is , means whole xml document as an element
    let me help

  • How to read data over tcp/ip using labview

    Hi,
    I have a network enabled force transducer (6-axis load cell). I know its IP addr. and the data format it is sending the data out (7 32-bit DWORD, One status and 6 axis force data) . I have been playing around with the simple data client.vi example program. 
    When I executed the program using the devices IP addr. I used to get error 63: TCP/IP connection open. Then I ran the program using localhost in IP addr field, the program executes now indefinetly at one block only. I am attaching the screenshot for ref. 
    Thanks.
    Sasi.
    Attachments:
    TCP-IP.JPG ‏62 KB

    Hello,
    I'm wondering if you can create a rather simple VI that just tries to open and close a TCP connecting to your transducer. All you would need is a TCP Open and a TCP Close wired together with the proper IP address etc. Does this run? I did look to see if there was any NetFT information and I could not find anything. I feel that the problem lies in the communication protocol between your transducer. Another place to see if you can connect to it would be to try hyperterminal. You can access this in Windows XP by clicking Start»All Programs»Accessories»Communications»HypeTermina. Using this, you can try and connect to your instrument with TCP/IP outside of LabVIEW. You might also want to get in contact with the manufacturer to verify that third-party software can indeed communicate with it. There may be a specific set of instructions that need to be sent to the transducer in order to initiate the connection and then read from it. These may be in the form of serial commands that would need to be sent over TCP. What is the make and model of your transducer?
    -Zach
    Certified LabVIEW Developer

  • High pitch screech when LAN is transfering data over network

    I found this strange.  But whenever data (large amounts) is sent through my puter over the network, the LAN chip or whatever makes a high pitch sound.  What is with this?

    Firewall enabled and for example opening a torrent with more than 100 peers made the northbridge screech and  crashed the network after five minutes. Disabling the firewall helped a bit, removed the screeching atleast, but it's still lagging behind my old AT7-MAX2(VIA KT400) onboard LAN in 'performance'.

  • How to manipulate data over two tables in same database.

    hi, i am not a profficient java programmer, i was trying to copy filtered data from one table to another table.
    i was trying to use
    public static Connection getConnection() throws Exception {
         Driver d = (Driver)Class.forName
             ("sun.jdbc.odbc.JdbcOdbcDriver").newInstance();
         Connection c = DriverManager.getConnection
             ("jdbc:odbc:Driver={Microsoft Access Driver (*.mdb)};DBQ=stuff.mdb");
         return c;
    and then
        theConn = myConnection.getConnection();
          ResultSet rs;
          Statement stmt;
          String sql;
          stmt = theConn.createStatement();
          sql =  "SELECT * FROM shisab, myhisab WHERE shisab.Who_Bought ='ron'";
               rs = stmt.executeQuery(sql);
               while (rs.next()) {
                System.out.println("date:"+rs.getString("shisab.Date"));                 
          rs.close();--------------------------------------
    it does not show anything! in the output! i tried many things but i thing it is not supporting my multiple table syntax , i.e.: table1,table2 in teh from clause.
    please help!
    i just need to filter stuff from the shisab table and write the filtered data into
    the myhisab table.

    Your problem isn't in the Java code, it's your SQL code...
    Your statement, as submitted, is an improperly formed multi-table select, where you never joined the second table. That won't work.
    You need to look into the INSERT INTO statement. The exact syntax of your statement will depend on whether or not both tables contain the exact same column names, etc. A generic example based on what you have might look like:
    INSERT INTO myhisab SELECT * FROM shisab WHERE Who_Bought = 'ron'HTH

  • How to configure SSL in tomcat and transfer data through HTTPS.

    Hi all,
    I hav an urgent requirement for transfering data through HTTPS.But hav no idea how to achieve that,using SSL.
    For that i have to configure tomcat.What and all i hav to do
    download and which and all files i hav to alter for configuring the tomcat.
    seeking for ur help,
    thank you

    Multi-posted.
    http://forum.java.sun.com/thread.jspa?threadID=591116&messageID=3079266#3079266
    http://forum.java.sun.com/thread.jspa?threadID=591062&messageID=3078566#3078566
    http://forum.java.sun.com/thread.jspa?threadID=590987&messageID=3077736#3077736

  • Post XML over HTTPS

    We are trying to do the following. Can anyone help by providing any pointers as how to do it.
    1. A java client will be posting XML over http(s) to the Tomcat server.
    2. The Tomcat server has to do the following:
    - Validate the user credentails and verify that it is an valid user on IDM
    - Do some DB operations and return back a response XML
    We are trying to do this by having the Java client post XML over http to a jsp hosted on the Tomcat server
    How do i retrieve the XML data from the HTTP post (from the HTTP body) ?
    Thanks

    try the below example to read data over https,
    import java.net.*;
    import java.io.*;
    import javax.net.ssl.*;
    public class SSLSocketClient {
    public static void main(String[] args) throws Exception {
         String url="https://secure.com";
              try {
                   SSLSocketFactory factory = (SSLSocketFactory)SSLSocketFactory.getDefault();
                SSLSocket socket = (SSLSocket)factory.createSocket(url, 443);
                socket.startHandshake();
                /* read response */
                BufferedReader in = new BufferedReader(new InputStreamReader(socket.getInputStream()));
                String inputLine;
                while ((inputLine = in.readLine()) != null)
                    System.out.println(inputLine);
                in.close();
                socket.close();
            } catch (Exception e) {
                e.printStackTrace();
    }

  • Accessing avi through URL over http

    Dear Oracle experts,
    I am experimenting with Oracle9i interMedia, and have created a simple table:
    CREATE TABLE TVID(n NUMBER, vid ORDSYS.ORDVIDEO);
    INSERT INTO TVID VALUES(1, ORDSYS.ORDVideo.init());
    INSERT INTO TVID VALUES(2, ORDSYS.ORDVideo.init());
    commit;
    I have a java application wanting to access the avi-resources stored in the ORDVideo objects through an URL over http. Is this possible and if so, how can it be done?
    Thanks for your help!

    Just to be more clear on teh example. The example imports the data into the database.
    You imply you do not want to import the data in the database...
    So, you would simply do a obj.setproperties() without the obj.import().
    The Database will read the data over HTTP to set the properties, so it will be very slow as it may have to scan the entire file.
    Also, make sure the database HTTP proxy, if applicable, is set correctly.

  • File upload over HTTP into IFS

    The webui classes provide functionality to upload a file over HTTP as multipart/form-data. It takes care of splitting out the boundaries, and other form data, leaving just the file to store in IFS. My question is this:
    1. Since the webui classes are not a part of the API, are they supported for development purposes? (i.e, can I mimic the behavior of the webui in my application?) I suspect not.
    2. Why doesn't the IFS API provide the ability to handle multipart/form data over http? Even the webcommandapp example application assumes the file is already local to the webserver computer, which leads me to believe it's my responsibility to get it there over HTTP or FTP.

    I think the best way out for now is to use the Oreilly classes that are available at : http://www.servlets.com/resources/com.oreilly.servlet/
    to handle the multipart-form data;until Oracle provides this feature in a later release of the ADK

  • HOW TO CREATE DATA SOURCE FOR MAXDB

    hi,
    i am using hibernate in NetWeaver with maxdb.
    i have to give datasource name in hibernate.cfg.xml
    but i do't know how to create datasource for maxdb.
    please help me.
    Thanqqqqqqqq
    Guru

    The following link gives u how to create data source
    http://dev.mysql.com/doc/maxdb/en/84/1d733cefd63c38e10000000a114084/content.htm

Maybe you are looking for