This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.io.DataOutputStream; | |
import java.net.ServerSocket; | |
public class Server { | |
public static void main(String[] args) throws Exception{ | |
new DataOutputStream(new ServerSocket(80).accept().getOutputStream()).writeBytes("Hello, world!"); | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8"?> | |
<!DOCTYPE web-app | |
PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.2//EN" | |
"http://java.sun.com/j2ee/dtds/web-app_2_2.dtd"> | |
<web-app> | |
<servlet> | |
<servlet-name>hej</servlet-name> | |
<servlet-class>ServletTest</servlet-class> | |
</servlet> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html><head> | |
<meta charset="utf-8"> | |
<link rel="stylesheet" href="//netdna.bootstrapcdn.com/bootstrap/3.1.1/css/bootstrap.min.css"> | |
<link href="//netdna.bootstrapcdn.com/font-awesome/4.0.3/css/font-awesome.css" rel="stylesheet"> | |
</head><body> | |
<div class="container"><a class="btn btn-success" href="http://ow.ly/uf5n0"><i class="fa fa-star fa-spin"></i></a></div> | |
</body></html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.io.DataOutputStream; | |
import java.net.ServerSocket; | |
import java.util.Date; | |
public class WebServerTest { | |
public static void main(String[] args) throws Exception{ | |
String newLine = "\n"; | |
System.out.println("Starting server..."); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.io.DataOutputStream; | |
import java.net.ServerSocket; | |
import java.util.Date; | |
public class WebServerTest { | |
public static void main(String[] args) throws Exception{ | |
System.out.println("Starting server..."); | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html><head> | |
<meta charset="utf-8"> | |
<link rel="stylesheet" href="//netdna.bootstrapcdn.com/bootstrap/3.1.1/css/bootstrap.min.css"> | |
<link href="//netdna.bootstrapcdn.com/font-awesome/4.0.3/css/font-awesome.css" rel="stylesheet"> | |
<script src="http://code.jquery.com/jquery-1.11.0.min.js"></script> | |
<script src="//netdna.bootstrapcdn.com/bootstrap/3.1.1/js/bootstrap.min.js"></script> | |
</head><body> | |
<div class="container"><span class="btn btn-success"><i class="fa fa-coffee"></i></span></div> | |
</body></html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html><head> | |
<meta charset="utf-8"> | |
<link rel="stylesheet" href="//netdna.bootstrapcdn.com/bootstrap/3.1.1/css/bootstrap.min.css"> | |
<link href="//netdna.bootstrapcdn.com/font-awesome/4.0.3/css/font-awesome.css" rel="stylesheet"> | |
<script src="http://code.jquery.com/jquery-1.11.0.min.js"></script> | |
<script src="//netdna.bootstrapcdn.com/bootstrap/3.1.1/js/bootstrap.min.js"></script> | |
<style> | |
body{background:url('mostar-bosnia.jpg');} | |
.container{margin-top:200px;text-align:center;} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<%@page import="java.sql.*" %> | |
<%@ page language="java" contentType="text/html; charset=utf-8" pageEncoding="utf-8"%> | |
<!DOCTYPE html> | |
<html><head> | |
<meta charset="utf-8"> | |
<link rel="stylesheet" href="//netdna.bootstrapcdn.com/bootstrap/3.1.1/css/bootstrap.min.css"> | |
<link href="//netdna.bootstrapcdn.com/font-awesome/4.0.3/css/font-awesome.css" rel="stylesheet"> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class Student { | |
public Integer id; | |
public String name; | |
public String surname; | |
public String icon; | |
public Student(Integer id, String name, String surname, String icon){ | |
this.id = id; | |
this.name = name; | |
this.surname = surname; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
INSERT INTO `student` VALUES (1,'Rachel','Morgan','wrench'); | |
INSERT INTO `student` VALUES (2,'Craig','Taylor','minus'); | |
INSERT INTO `student` VALUES (3,'Jean','King','legal'); | |
INSERT INTO `student` VALUES (4,'Jacqueline','Stewart','key'); | |
INSERT INTO `student` VALUES (5,'Jerry','Thompson','microphone-slash'); | |
INSERT INTO `student` VALUES (6,'Annie','Allen','leaf'); | |
INSERT INTO `student` VALUES (7,'Doris','Bailey','gift'); | |
INSERT INTO `student` VALUES (8,'Judith','Wood','calendar-o'); | |
INSERT INTO `student` VALUES (9,'Harry','Reed','flag-checkered'); | |
INSERT INTO `student` VALUES (10,'Sara','Edwards','flag'); |
OlderNewer