Results 1 to 1 of 1
-
Getting the host from where the Applet was loaded
The code below shows how to get the host from where the applet was loaded:
Java Code:public class FromWhere extends Applet { public void init() { Label label = new Label(getCodeBase().toString()); add(label); // // you can check the value of getCodeBase() // to implements a simple copy protection // scheme. If it's not equals to your // URL then quit. // NOTE : This is not a very strong protection! // } }
Similar Threads
-
Looking Up the Address of a Host
By Java Tip in forum java.netReplies: 0Last Post: 04-07-2008, 08:11 PM -
Getting the host of the applet
By Java Tip in forum Java TipReplies: 0Last Post: 03-10-2008, 02:56 PM -
Getting host name/address
By Java Tip in forum Java TipReplies: 0Last Post: 11-19-2007, 04:34 PM -
How to get the type of the loaded JDBC driver.
By shankar in forum JDBCReplies: 1Last Post: 08-08-2007, 02:42 PM -
newbie: the app is loaded but i can't see it
By tamayo in forum New To JavaReplies: 1Last Post: 07-21-2007, 08:14 AM


LinkBack URL
About LinkBacks
Reply With Quote
Bookmarks