Skip to content

Instantly share code, notes, and snippets.

View epexa's full-sized avatar

Erlan Sobakin epexa

  • Planet Earth
View GitHub Profile
.marquee {
width: 450px;
margin: 0 auto;
white-space: nowrap;
overflow: hidden;
box-sizing: border-box;
border: 1px dotted #800000;
}
.marquee span {
@epexa
epexa / add_text_images_dir.php
Created July 15, 2020 08:31
Adding text to all images from folder (directory) in PHP
<?php
/*
Adding text to all images from folder (directory) in PHP
Like this: https://addtext.com
And this API: https://cloudinary.com/documentation/image_transformations#adding_text_captions
LIBRARY: https://github.com/Intervention/image
@epexa
epexa / authentication_through_metamask_other_example.html
Last active October 2, 2019 19:18
Authentication through MetaMask other example
<!--
This example based on official documentation:
https://metamask.github.io/metamask-docs/API_Reference/Ethereum_Provider
Gist: https://gist.github.com/epexa/4ce11de71d1b40f8cb1d35567e993b53
Author example: @epexa
-->
<button id="auth">authentication through metamask</button>
<button id="sign" style="display: none">sign</button>
<h2 id="status"></h2>
@epexa
epexa / authentication_through_metamask_example.html
Last active October 2, 2019 19:19
Authentication through MetaMask example
<!--
This example based on official documentation:
https://metamask.github.io/metamask-docs/API_Reference/Ethereum_Provider
Gist: https://gist.github.com/epexa/9a939cf332041e18f375d35df1145c75
Author example: @epexa
-->
<button id="auth">authentication through metamask</button>
<button id="sign" style="display: none">sign</button>
<h2 id="status"></h2>
<div id="uppy"></div>
<button id="show-uppy-btn">Show Uppy</button>
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/uppy@1.0.2/dist/uppy.min.css">
<script src="https://cdn.jsdelivr.net/npm/uppy@1.0.2/dist/uppy.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@8.11.7/dist/sweetalert2.all.min.js"></script>
<script>
document.addEventListener('DOMContentLoaded', () => {
const uppy = Uppy.Core().use(Uppy.Dashboard, {
target: '#uppy',
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/uppy@1.0.2/dist/uppy.min.css">
<script src="https://cdn.jsdelivr.net/npm/uppy@1.0.2/dist/uppy.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@8.11.7/dist/sweetalert2.all.min.js"></script>
<script>
document.addEventListener('DOMContentLoaded', () => {
const uppy = Uppy.Core().use(Uppy.Dashboard);
Swal.fire({ toast: true });
@epexa
epexa / space.html
Created December 2, 2018 09:08
space.html
<!DOCTYPE html>
<html lang="ru">
<head>
<title>Как добраться до площадки Space</title>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap@4.1.3/dist/css/bootstrap.min.css">
</head>
<body>
<div class="container-fluid">
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap@4.1.3/dist/css/bootstrap.min.css">
<div class="modal" id="first-modal">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-body">
<p>First modal</p>
<button class="btn btn-success" onclick="$('#second-modal').modal('show');">Open second modal</button>
</div>
</div>
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap@4.1.3/dist/css/bootstrap.min.css">
<div class="modal" id="first-modal">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-body">
First modal
</div>
</div>
</div>
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap@4.1.3/dist/css/bootstrap.min.css">
<div class="modal" id="first-modal">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-body">
First modal
</div>
</div>
</div>