Results 1 to 3 of 3
  1. #1
    alvalv is offline Member
    Join Date
    Sep 2012
    Posts
    9
    Rep Power
    0

    Default java applet connecting to web page

    I have an applet that can show several messages, one at a time. The messages are all written in a class file.

    I want:

    - that the messages be written in a txt file in the server.
    - each time the applet need to show a message, it call the server and asks for the message.
    - the ".txt" file could not be downloaded in the internet browser.

    The aim is preventing the user download all the messages with one single click ( Save as .. )

    Because the question involves more than one technology ( java, php, apache, javascript ? ) its not easy to find the answer.

    I dont expect a detailed answer, just the guidelines. Thanks in advance.

  2. #2
    Norm's Avatar
    Norm is offline Moderator
    Join Date
    Jun 2008
    Location
    SW Missouri
    Posts
    17,305
    Rep Power
    25

    Default Re: java applet connecting to web page

    Moved to Applets section.

    Is is OK for the applet to read the full contents of the text file with one request?
    What code do you have on the server that the applet can communicate with?
    If the applet uses HTTP GET to read the text file, if someone got the name of the file, they could download it into the browser.

    You could encode/encrypt the text file to make it harder for anyone that downloads it to read it.
    If you don't understand my response, don't ignore it, ask a question.

  3. #3
    alvalv is offline Member
    Join Date
    Sep 2012
    Posts
    9
    Rep Power
    0

    Default Re: java applet connecting to web page

    Is is OK for the applet to read the full contents of the text file with one request?
    It does not mind, although it would be better download one line ( one message ) per request.
    What code do you have on the server that the applet can communicate with?
    PHP and SQL. An I hardly know what they are about.
    If the applet uses HTTP GET to read the text file, if someone got the name of the file, they could download it into the browser.
    If anyone could guess the name of the file, he deserves hacking my web page.


    So, I will explore the GET command.
    Thanks for your quick reply.

Similar Threads

  1. connecting Ms-access database with java applet
    By balaKannan in forum New To Java
    Replies: 1
    Last Post: 12-23-2010, 12:16 PM
  2. Replies: 2
    Last Post: 04-26-2009, 06:36 AM
  3. Connecting to DB from Applet
    By ibanez270dx in forum New To Java
    Replies: 1
    Last Post: 11-13-2007, 11:51 PM
  4. redirect page within a java applet
    By paul in forum Java Applets
    Replies: 1
    Last Post: 08-07-2007, 05:11 AM

Posting Permissions

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