Skip to content

Instantly share code, notes, and snippets.

View mohitsadaria's full-sized avatar
🎯
Focusing

Mohit Sadaria mohitsadaria

🎯
Focusing
  • Dhyana Studio
  • Rajkot, India
View GitHub Profile
@mohitsadaria
mohitsadaria / .htaccess
Created March 13, 2024 04:23 — forked from seoagentur-hamburg/.htaccess
UPDATE 2022/10: Perfect .htaccess file for highspeed and security. You can use it for every WordPress-Website without problems. Highspeed and Security - testet on hundreds of Websites. If you are using a WordPress Multisite, change the last part of this file.
########################################################################
# OPTIMAL .htaccess FILE FOR SPEED AND SECURITY @Version 2.0.6 - 10/2022
# ----------------------------------------------------------------------
# @Author: Andreas Hecht
# @Author URI: https://seoagentur-hamburg.com
# License: GNU General Public License v2 or later
# License URI: http://www.gnu.org/licenses/gpl-2.0.html
########################################################################
@mohitsadaria
mohitsadaria / ffmpeg-web-video-guide.md
Created August 3, 2021 07:10 — forked from jaydenseric/ffmpeg-web-video-guide.md
A quick guide to using FFmpeg to create cross-device web videos.

Video conversion with FFmpeg

Install

On mac:

  1. Download the latest release.
  2. Extract the binary and place it in /usr/local/bin.

Command basics

Facebook:
http://www.facebook.com/sharer.php?u=[post-url]
Twitter:
https://twitter.com/share?url=[post-url]&text=[post-title]&via=[via]&hashtags=[hashtags]
Google+:
https://plus.google.com/share?url=[post-url]
Pinterest:
https://pinterest.com/pin/create/bookmarklet/?media=[post-img]&url=[post-url]&is_video=[is_video]&description=[post-title]
LinkedIn:
http://www.linkedin.com/shareArticle?url=[post-url]&title=[post-title]
@mohitsadaria
mohitsadaria / Online KMS Activator.cmd
Created June 17, 2020 07:28 — forked from bhandarisaurav/Online KMS Activator.cmd
Activate Windows & Office for 180 Days with online KMS Servers. This script does not install any files in your system and it clears all the leftovers including kms server name after the Activation. For Successful Activation, Internet Must be connected.
@echo off
::::::::::::::::::::::::::::
set "params=Problem_with_elevating_UAC_for_Administrator_Privileges"&if exist "%temp%\getadmin.vbs" del "%temp%\getadmin.vbs"
fsutil dirty query %systemdrive% >nul 2>&1 && goto :GotPrivileges
:: The following test is to avoid infinite looping if elevating UAC for Administrator Privileges failed
If "%1"=="%params%" (echo Elevating UAC for Administrator Privileges failed&echo Right click on the script and select 'Run as administrator'&echo Press any key to exit...&pause>nul 2>&1&exit)
cmd /u /c echo Set UAC = CreateObject^("Shell.Application"^) : UAC.ShellExecute "%~0", "%params%", "", "runas", 1 > "%temp%\getadmin.vbs"&cscript //nologo "%temp%\getadmin.vbs"&exit
:GotPrivileges
::::::::::::::::::::::::::::
color 1F
@mohitsadaria
mohitsadaria / GTWalsheimPro.md
Created April 21, 2020 15:41 — forked from mfd/GTWalsheimPro.css
GT Walsheim Pro

https://cdn.rawgit.com/mfd/7c7a915eb31474cc8c6a65066a4c4dc3/raw/f0f2fb94c21dea904812a53e0eb6cf0bc87f3754/GTWalsheimPro.css

<link rel="https://cdn.rawgit.com/mfd/7c7a915eb31474cc8c6a65066a4c4dc3/raw/f0f2fb94c21dea904812a53e0eb6cf0bc87f3754/GTWalsheimPro.css">

html, body, div, span, applet, object, iframe,
h1, h2, h3, h4, h5, h6, p, blockquote, pre,
a, abbr, acronym, address, big, cite, code,
del, dfn, em, img, ins, kbd, q, s, samp,
small, strike, strong, sub, sup, tt, var,
b, u, i, center,
dl, dt, dd, ol, ul, li,
fieldset, form, label, legend,
table, caption, tbody, tfoot, thead, tr, th, td,
article, aside, canvas, details, embed,
$ cd ~
$ sudo curl -sS https://getcomposer.org/installer | sudo php
$ sudo mv composer.phar /usr/local/bin/composer
$ sudo ln -s /usr/local/bin/composer /usr/bin/composer
then you can run
$ sudo composer install
@mohitsadaria
mohitsadaria / functions.php
Created June 30, 2016 16:12
WooCommerce - Remove or Hide product tabs
add_filter( 'woocommerce_product_tabs', 'woo_remove_product_tabs', 98 );
function woo_remove_product_tabs( $tabs ) {
unset( $tabs['description'] ); // Remove the description tab
unset( $tabs['reviews'] ); // Remove the reviews tab
unset( $tabs['additional_information'] ); // Remove the additional information tab
return $tabs;
@mohitsadaria
mohitsadaria / convert_ascii.php
Created April 18, 2016 05:55 — forked from jaywilliams/convert_ascii.php
This simple function will remove any non-ASCII character. Feel free to fork and extend!
<?php
/**
* Remove any non-ASCII characters and convert known non-ASCII characters
* to their ASCII equivalents, if possible.
*
* @param string $string
* @return string $string
* @author Jay Williams <myd3.com>
* @license MIT License
* @link http://gist.github.com/119517