{"id":3590,"date":"2025-10-05T00:00:00","date_gmt":"2025-10-04T22:00:00","guid":{"rendered":"https:\/\/tecnologia.euroinnova.com\/applets\/"},"modified":"2025-10-07T15:02:08","modified_gmt":"2025-10-07T13:02:08","slug":"applets","status":"publish","type":"post","link":"https:\/\/tecnologia.euroinnova.com\/en\/applets","title":{"rendered":"Applets"},"content":{"rendered":"<p class=\"text-align-justify\">A <strong>applet<\/strong> is a small program that runs inside another application, usually in a web browser, with the aim of providing interactive functionalities without the need for additional installation.<\/p>\n<p class=\"text-align-justify\">For years, Java applets were one of the most popular ways of adding dynamic content to web pages, such as <strong>animations, simulations and interactive tools<\/strong>.<\/p>\n<p class=\"text-align-justify\">Unlike traditional applications, which run independently on the operating system, applets depend on a specific execution environment. In the case of applets in Java, this environment is the <strong>Java Virtual Machine (JVM)<\/strong>, which allows code to run uniformly on different operating systems without modification.<\/p>\n<p class=\"text-align-justify\"><strong>How do applets work in Java?<\/strong><\/p>\n<p class=\"text-align-justify\">Applets written in Java follow a specific structure and run inside the browser, provided that the browser supports Java technology. Its <strong>LIFE CYCLE<\/strong> is made up of four fundamental stages:<\/p>\n<ul>\n<li>\n<p class=\"text-align-justify\"><strong>Charge<\/strong>: the browser downloads the .class file of the applet and loads it into memory.<\/p>\n<\/li>\n<li>\n<p class=\"text-align-justify\"><strong>Initialisation<\/strong> <strong>(init)<\/strong>: an initial configuration of the applet is executed before it is displayed on the screen.<\/p>\n<\/li>\n<li>\n<p class=\"text-align-justify\"><strong>Execution (start and paint)<\/strong>: applet processes are activated and their graphical content is drawn if necessary.<\/p>\n<\/li>\n<li>\n<p class=\"text-align-justify\"><strong>Termination (stop and destroy)<\/strong>when the user leaves the page, the applet stops its execution and frees resources.<\/p>\n<\/li>\n<\/ul>\n<p class=\"text-align-justify\">A <strong>example<\/strong> The basic Java applet would be as follows:<\/p>\n<p class=\"text-align-center\"><img fetchpriority=\"high\" decoding=\"async\" class=\"aligncenter wp-image-3981 size-full\" src=\"https:\/\/tecnologia.euroinnova.com\/wp-content\/uploads\/2025\/10\/codigo-applets-js.png\" alt=\"\" width=\"567\" height=\"166\" srcset=\"https:\/\/tecnologia.euroinnova.com\/wp-content\/uploads\/2025\/10\/codigo-applets-js.png 567w, https:\/\/tecnologia.euroinnova.com\/wp-content\/uploads\/2025\/10\/codigo-applets-js-300x88.png 300w\" sizes=\"(max-width: 567px) 100vw, 567px\" \/><\/p>\n<p class=\"text-align-justify\">To display it on a web page, it was used the <strong>tag in HTML<\/strong> as follows:<\/p>\n<p class=\"text-align-center\"><img decoding=\"async\" class=\"aligncenter wp-image-3987 size-full\" src=\"https:\/\/tecnologia.euroinnova.com\/wp-content\/uploads\/2025\/10\/codigo-applets-con-etiqueta.png\" alt=\"\" width=\"568\" height=\"33\" srcset=\"https:\/\/tecnologia.euroinnova.com\/wp-content\/uploads\/2025\/10\/codigo-applets-con-etiqueta.png 568w, https:\/\/tecnologia.euroinnova.com\/wp-content\/uploads\/2025\/10\/codigo-applets-con-etiqueta-300x17.png 300w\" sizes=\"(max-width: 568px) 100vw, 568px\" \/><\/p>\n<p class=\"text-align-justify\">When loading the page, the applet generated the message \u00abHello, this is a Java Applet!\u00bb inside the browser.<\/p>\n<p class=\"text-align-justify\"><strong>Functions and uses of applets<\/strong><\/p>\n<p class=\"text-align-justify\">Applets were used to <strong>multiple purposes<\/strong>, especially in interactive web applications. Some of its main features <strong>functions<\/strong> were:<\/p>\n<ul>\n<li>\n<p class=\"text-align-justify\"><strong>Advanced interactivity<\/strong>were used to create simulations, animated graphics and educational tools.<\/p>\n<\/li>\n<li>\n<p class=\"text-align-justify\"><strong>Connectivity with servers<\/strong>They could communicate with databases and process information in real time.<\/p>\n<\/li>\n<li>\n<p class=\"text-align-justify\"><strong>Local data processing<\/strong>The user's computer: they performed calculations on the user's computer, reducing the load on the server.<\/p>\n<\/li>\n<li>\n<p class=\"text-align-justify\"><strong>Cross-platform compatibility<\/strong>thanks to the Java Machine, applets could run on different operating systems without modification.<\/p>\n<\/li>\n<\/ul>\n<p class=\"text-align-justify\">Some <strong>examples of use<\/strong> of applets were:<\/p>\n<ol>\n<li>\n<p class=\"text-align-justify\">Scientific and financial calculators online.<\/p>\n<\/li>\n<li>\n<p class=\"text-align-justify\">Browser games with dynamic graphics.<\/p>\n<\/li>\n<li>\n<p class=\"text-align-justify\">Data visualisation applications and interactive graphics.<\/p>\n<\/li>\n<li>\n<p class=\"text-align-justify\">Mathematical and scientific simulations for education.<\/p>\n<\/li>\n<\/ol>\n<p class=\"text-align-justify\"><strong>The decline of applets in Java<\/strong><\/p>\n<p class=\"text-align-justify\">Despite their importance in web development, the use of applets in Java <strong>has decreased drastically<\/strong> over time for a number of reasons:<\/p>\n<ul>\n<li>\n<p class=\"text-align-justify\"><strong>Security problems<\/strong>Many vulnerabilities in the Java Machine allowed the execution of malicious code on users' systems.<\/p>\n<\/li>\n<li>\n<p class=\"text-align-justify\"><strong>Dependence on plugins<\/strong>Browsers required the installation of a Java plug-in to run applets, which created drawbacks in the user experience.<\/p>\n<\/li>\n<li>\n<p class=\"text-align-justify\"><strong>Technological advances<\/strong>The advent of technologies such as JavaScript, HTML5, WebGL and WebAssembly offered more secure and efficient alternatives for creating interactive content on the web.<\/p>\n<\/li>\n<\/ul>\n<p class=\"text-align-justify\">Because of these problems, the major browsers removed support for Java applets and <strong>Oracle discontinued the Java Plugin in 2019<\/strong>. Today, web developers use modern frameworks such as React, Angular and WebGL to achieve the same effects without compromising security.<\/p>\n<p class=\"text-align-justify\">In short, applets were an innovative solution at the time, allowing interactivity to be added to web pages in an efficient way. However, they were eventually replaced by more secure and flexible technologies.<\/p>\n<p class=\"text-align-justify\">Although they are no longer used on the web, their legacy is still present in the evolution of interactive development on the Internet.<\/p>","protected":false},"excerpt":{"rendered":"<p>Un applet es un peque\u00f1o programa que se ejecuta dentro de otra aplicaci\u00f3n, generalmente en un navegador web, con el [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"site-sidebar-layout":"default","site-content-layout":"","ast-site-content-layout":"default","site-content-style":"default","site-sidebar-style":"default","ast-global-header-display":"","ast-banner-title-visibility":"","ast-main-header-display":"","ast-hfb-above-header-display":"","ast-hfb-below-header-display":"","ast-hfb-mobile-header-display":"","site-post-title":"","ast-breadcrumbs-content":"","ast-featured-img":"","footer-sml-layout":"","ast-disable-related-posts":"","theme-transparent-header-meta":"","adv-header-id-meta":"","stick-header-meta":"","header-above-stick-meta":"","header-main-stick-meta":"","header-below-stick-meta":"","astra-migrate-meta-layouts":"default","ast-page-background-enabled":"default","ast-page-background-meta":{"desktop":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"ast-content-background-meta":{"desktop":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"footnotes":""},"categories":[25],"tags":[],"class_list":["post-3590","post","type-post","status-publish","format-standard","hentry","category-metaterminos"],"acf":[],"_links":{"self":[{"href":"https:\/\/tecnologia.euroinnova.com\/en\/wp-json\/wp\/v2\/posts\/3590","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/tecnologia.euroinnova.com\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/tecnologia.euroinnova.com\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/tecnologia.euroinnova.com\/en\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/tecnologia.euroinnova.com\/en\/wp-json\/wp\/v2\/comments?post=3590"}],"version-history":[{"count":0,"href":"https:\/\/tecnologia.euroinnova.com\/en\/wp-json\/wp\/v2\/posts\/3590\/revisions"}],"wp:attachment":[{"href":"https:\/\/tecnologia.euroinnova.com\/en\/wp-json\/wp\/v2\/media?parent=3590"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/tecnologia.euroinnova.com\/en\/wp-json\/wp\/v2\/categories?post=3590"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/tecnologia.euroinnova.com\/en\/wp-json\/wp\/v2\/tags?post=3590"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}