Skip to content

Instantly share code, notes, and snippets.

View MuhammadSaim's full-sized avatar
🤓
Learning Geek

Muhammad Saim MuhammadSaim

🤓
Learning Geek
View GitHub Profile
@MuhammadSaim
MuhammadSaim / My_Controller.php
Created July 30, 2021 05:21
Symfony Twig Templating Engine with Codeigniter 3
<?php
use Twig\Environment;
use Twig\Loader\FilesystemLoader;
use Twig\TwigFunction;
/**
* Create My_controller.php file in the application/core folder
* please change the subclass_prefix in application/config/config.php from MY to My
@MuhammadSaim
MuhammadSaim / cloudSettings
Created March 30, 2021 19:14
Visual Studio Code Settings Sync Gist
// Empty
@MuhammadSaim
MuhammadSaim / cloudSettings
Last active September 19, 2021 18:20
Visual Studio Code Settings Sync Gist
{"lastUpload":"2021-09-19T18:20:10.441Z","extensionVersion":"v3.4.3"}
@MuhammadSaim
MuhammadSaim / .htaccess
Created February 26, 2021 04:48
Deploy Laravel to Cpanel and redirect to public folder with .htaccess. Simple rename the server.php => index.php and create new file .htaccess in the root folder and this code in the .htaccess file.
Options -MultiViews -Indexes
RewriteEngine On
# Handle Authorization Header
@MuhammadSaim
MuhammadSaim / CountryTableSeader.php
Last active January 14, 2021 19:21
You wanna add countries in your laravel App just use this as a seeder
<?php
/**
* Country Table Seeder
* @required Laravel 7+
* @author Muhammad Saim
* Please make sure create a migration with these fields
*
* 1- iso
* 2- name
* 3- nicename
[
{
"id":"1",
"iso":"AF",
"name":"AFGHANISTAN",
"nicename":"Afghanistan",
"iso3":"AFG",
"numcode":"4",
"phonecode":"93"
},
$timezones = array(
'Pacific/Midway' => "(GMT-11:00) Midway Island",
'US/Samoa' => "(GMT-11:00) Samoa",
'US/Hawaii' => "(GMT-10:00) Hawaii",
'US/Alaska' => "(GMT-09:00) Alaska",
'US/Pacific' => "(GMT-08:00) Pacific Time (US &amp; Canada)",
'America/Tijuana' => "(GMT-08:00) Tijuana",
'US/Arizona' => "(GMT-07:00) Arizona",
'US/Mountain' => "(GMT-07:00) Mountain Time (US &amp; Canada)",
import java.util.*;
class User{
private String name;
private double amount;
public User(){
}
@MuhammadSaim
MuhammadSaim / rarreg.key
Last active December 5, 2024 11:32
Step 1: Create a file called rarreg.key Step 2: Paste into the file the raw content of this gist Step 3: Go to Winrar install directory (by default => c:\ProgramFiles\WinRAR\ ) Step 4: Paste the rarreg.key into WinRAR directory Step 5: Enjoy
RAR registration data
WinRAR
Unlimited Company License
UID=4b914fb772c8376bf571
6412212250f5711ad072cf351cfa39e2851192daf8a362681bbb1d
cd48da1d14d995f0bbf960fce6cb5ffde62890079861be57638717
7131ced835ed65cc743d9777f2ea71a8e32c7e593cf66794343565
b41bcf56929486b8bcdac33d50ecf773996052598f1f556defffbd
982fbe71e93df6b6346c37a3890f3c7edc65d7f5455470d13d1190
6e6fb824bcf25f155547b5fc41901ad58c0992f570be1cf5608ba9