Skip to content

Instantly share code, notes, and snippets.

View othreecodes's full-sized avatar
🌴
Working from home

Obi Uchenna David othreecodes

🌴
Working from home
View GitHub Profile
@othreecodes
othreecodes / click_me.html
Created March 13, 2024 10:01
Click Me Button Generated by MJML
<!doctype html>
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office">
<head>
<title>
</title>
<!--[if !mso]><!-->
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<!--<![endif]-->
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<?xml version="1.0" encoding="utf-8"?>
<androidx.coordinatorlayout.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context=".circles.discovercircle.DiscoverCircleSearchableActivity">
<com.google.android.material.appbar.AppBarLayout
android:layout_width="match_parent"
@othreecodes
othreecodes / EncodeBased64Binary.java
Created February 26, 2019 18:39 — forked from utsengar/EncodeBased64Binary.java
Encode a file to base64 binary in Java
import org.apache.commons.codec.binary.Base64;
private String encodeFileToBase64Binary(String fileName)
throws IOException {
File file = new File(fileName);
byte[] bytes = loadFile(file);
byte[] encoded = Base64.encodeBase64(bytes);
String encodedString = new String(encoded);
@othreecodes
othreecodes / rsa_encryption.java
Created February 26, 2019 18:35
how to encrypt & decrypt with RSA in Java
import java.security.KeyPair;
import java.security.KeyPairGenerator;
import java.security.NoSuchAlgorithmException;
import java.security.PrivateKey;
import java.security.PublicKey;
import javax.crypto.Cipher;
public class Sample {
@othreecodes
othreecodes / project-1.0.md
Last active June 15, 2017 16:52 — forked from biodunch/project-1.0.txt
Project 1.0 For Beginner Web Developer - Basic Gridding System with Bootstrap

Oh hey There Developers!

This project assumes you know the basics of designing with HTML (Hyper Text Marp-Up Language) and CSS (Cascading Styles Sheet), if you don't kindly checkout this url: https://www.w3schools.com/css/css_intro.asp and https://www.w3schools.com/html/default.asp for quick intro.

Now we are set!

PROJECT DESCRIPTION

The project is based on frontend design with Bootstrap. The link provided there is for a Sample Blog design with Bootstrap.

<%@ include file="/common/taglibs.jsp"%>
<div class="container-fluid">
<s:form id="" namespace="" action="" method="post">
<s:if test="id!=null">
<s:hidden name="id" value="%{id}" />
<s:if test="">
<s:hidden name="" value="%{}" />
</s:if>
@othreecodes
othreecodes / gist:f027a8a0b72578e5c04608e84366edfa
Created April 28, 2017 22:09 — forked from Atem18/gist:4696071
Tutorial to seting up a django website in production.

******************************************************************** Set up Django, Nginx and Gunicorn in a Virtualenv controled by Supervisor********************************************************************

Steps with explanations to set up a server using:

  • Virtualenv
  • Virtualenvwrapper
  • Django
  • Gunicorn
@othreecodes
othreecodes / Paystack Ticket Verification
Created February 20, 2017 13:09
Verify Paystack transaction
<?php
$key = $_GET['key'];
$ticket = $_GET['ticket'];//37-xxxxxxxxxxxxx
//$url = 'https://api.paystack.co/transaction/verify/'. rawurlencode($reference);
$url = 'https://api.paystack.co/transaction/verify/'. $ticket;