Skip to content

Instantly share code, notes, and snippets.

View Shakil-Shahadat's full-sized avatar
🏠
Working from home

Shakil Shahadat Shakil-Shahadat

🏠
Working from home
View GitHub Profile
@Shakil-Shahadat
Shakil-Shahadat / Bengali.tex
Last active December 30, 2022 00:52
ল্যাটেক্সে বাংলা ব্যবহারের উদাহরণ
\documentclass[a4paper,11pt]{article}
% Use Bengali
% Must use XeLaTeX or LuaLaTeX compiler
\usepackage{polyglossia}
\setmainlanguage{english}
\newfontfamily\englishfont{Segoe UI}
% \setmainfont{Noto Serif}
% \setsansfont{Noto Sans}
% \setmonofont{Noto Mono}
@Shakil-Shahadat
Shakil-Shahadat / index.php
Created June 29, 2022 10:17
Minimalist Bootstrap Tabs
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Repeated Tasks</title>
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.1.3/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-1BmE4kWBq78iYhFldvKuhfTAU6auU8tT94WrHftjDbrCEXSU1oBoqyl2QvZ6jIW3" crossorigin="anonymous">
</head>
<body>
@Shakil-Shahadat
Shakil-Shahadat / regex.js
Last active November 28, 2021 14:53
Regex in JavaScript
// Test the existance of a string
let myString = 'Hello, World!';
let myRegex = /Hello/;
let result = myRegex.test( myString );
console.log( result );
// Extract a part of a string
let myString = 'Hello, World!';
let myRegex = /Hello/;
let result = myString.match( myRegex );
@Shakil-Shahadat
Shakil-Shahadat / newPage.dart
Last active September 17, 2021 11:00
New Page in Dart
class newPage extends StatelessWidget {
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: AppBar(
title: Text(''),
centerTitle: true,
), // AppBar
body: SingleChildScrollView(
@Shakil-Shahadat
Shakil-Shahadat / sync a fork.txt
Last active April 22, 2021 20:49
Steps to sync a forked repository
// Check if original remote repository is already added or not
git remote -v
// Output
origin https://github.com/YOUR_NAME/REPO_NAME.git (fetch)
origin https://github.com/YOUR_NAME/REPO_NAME.git (pull)
upstream https://github.com/ORGINAL_USER/REPO_NAME.git (fetch)
upstream https://github.com/ORGINAL_USER/REPO_NAME.git (push)
// If it only shows origin, original remote repo is not added
// If not, add it
@Shakil-Shahadat
Shakil-Shahadat / .gitignore
Created February 28, 2021 23:04
.gitignore file for Tex files
*.aux
*.log
*.out
*.pdf
*.synctex.gz
*.toc
@Shakil-Shahadat
Shakil-Shahadat / composer.json
Last active November 3, 2023 15:16
[ Obsolete ] composer.json file to solve phpmyadmin compatibility problem with PHP 8
{
"name": "phpmyadmin/phpmyadmin",
"type": "project",
"description": "A web interface for MySQL and MariaDB",
"keywords": ["phpmyadmin","mysql","web"],
"homepage": "https://www.phpmyadmin.net/",
"support": {
"forum": "https://www.phpmyadmin.net/support/",
"issues": "https://github.com/phpmyadmin/phpmyadmin/issues",
"wiki": "https://wiki.phpmyadmin.net/",
@Shakil-Shahadat
Shakil-Shahadat / miscellaneous.php
Last active June 30, 2022 11:40
Miscellaneous PHP Codes
<?php
// Todays' date in the format 2022-01-12
echo date( 'Y-m-d' );
// Decode 'encodeURIComponent' encoded string
urldecode( );
// Sanitize $_POST array
foreach ( $_POST as $key => $value )
{
@Shakil-Shahadat
Shakil-Shahadat / Months.js
Created December 27, 2020 21:30
A list of Months in JS Array
months = [ 'January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December' ];
@Shakil-Shahadat
Shakil-Shahadat / index.html
Last active November 22, 2021 14:09
Floating box with animation. Demo: https://codepen.io/shakil/pen/BadEgwQ
<div class="info"></div>