Skip to content

Instantly share code, notes, and snippets.

View khannedy's full-sized avatar
👀
Orang Ganteng dan Intelek

Eko Kurniawan Khannedy khannedy

👀
Orang Ganteng dan Intelek
View GitHub Profile
@khannedy
khannedy / checkout.html
Last active December 5, 2024 14:28
Flashsale Template (for learning)
<!DOCTYPE html>
<html lang="id">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Pembayaran</title>
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.2/dist/css/bootstrap.min.css" rel="stylesheet">
<style>
body {
background-color: #f8f9fa;
@khannedy
khannedy / persistence.xml
Created April 12, 2023 13:56
Belajar Java Persistence API
<persistence xmlns="http://xmlns.jcp.org/xml/ns/persistence"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/persistence
http://xmlns.jcp.org/xml/ns/persistence/persistence_2_1.xsd"
version="2.1">
<persistence-unit name="BELAJAR">
<provider>org.hibernate.jpa.HibernatePersistenceProvider</provider>
FROM golang:1.18-alpine
ENV APP_PORT=8080
ENV MODE=local
RUN mkdir app
COPY main.go app
EXPOSE ${APP_PORT}
package main
import (
"fmt"
"net/http"
"os"
)
func main() {
port := os.Getenv("APP_PORT")
@khannedy
khannedy / main.go
Created April 26, 2022 03:04
Golang Web with Health Check
package main
import (
"fmt"
"net/http"
)
var counter = 0
func main() {
@khannedy
khannedy / main.go
Created April 25, 2022 03:29
Golang Web Hello World
package main
import (
"fmt"
"net/http"
)
func main() {
http.HandleFunc("/", HelloServer)
http.ListenAndServe(":8080", nil)
@khannedy
khannedy / main.go
Created April 24, 2022 22:37
Golang Web with Write File
package main
import (
"fmt"
"io/ioutil"
"net/http"
"os"
)
func main() {
@khannedy
khannedy / main.go
Created April 24, 2022 21:43
Simple Go-Lang Web with Port
package main
import (
"fmt"
"net/http"
"os"
)
func main() {
port := os.Getenv("APP_PORT")
@khannedy
khannedy / main.go
Created April 24, 2022 15:47
Go-Lang Hello World
package main
import (
"fmt"
"net/http"
)
func main() {
http.HandleFunc("/", HelloServer)
http.ListenAndServe(":8080", nil)
@khannedy
khannedy / template.blade.php
Created April 23, 2022 07:45
Laravel Login & Todolist
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Login Management</title>
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.1.3/dist/css/bootstrap.min.css" rel="stylesheet"
integrity="sha384-1BmE4kWBq78iYhFldvKuhfTAU6auU8tT94WrHftjDbrCEXSU1oBoqyl2QvZ6jIW3" crossorigin="anonymous">
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.1.3/dist/js/bootstrap.bundle.min.js"
integrity="sha384-ka7Sk0Gln4gmtz2MlQnikT1wXgYsOg+OMhuP+IlRH9sENBO0LRn5q+8nbTov4+1p"
crossorigin="anonymous"></script>