- Edit this files:
/var/cpanel/userdata/username/domain.tld
/var/cpanel/userdata/username/domain.tld_SSL
Change documentroot and scriptalias for cgi-bin
- (optional) Remove cache files:
UPDATE `core_config_data` | |
SET `value` = REPLACE(value, 'old-domain.com', 'new-domain.com') | |
WHERE `path` LIKE '%secure/base_url%' OR `path` = 'web/cookie/cookie_domain' | |
// with regex | |
UPDATE `subcategories` SET `name` = REGEXP_REPLACE(name,'^(.*)$','{"ro":"\\1","en":"\\1"}') |
<div ng-app="GoogleMapsMarkerDemo"> | |
<!-- Usage --> | |
<div ng-repeat="marker in ['marker1', 'marker2', 'marker3']"> | |
<google-marker label="$index | indexToAlphabet"></google-marker> | |
</div> | |
<!-- You can have this svg as a separate file --> | |
<script type="text/ng-template" id="google-marker-template"> | |
<svg version="1.1" width="27px" height="43px" viewBox="0 0 27 43" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"> |
/var/cpanel/userdata/username/domain.tld
/var/cpanel/userdata/username/domain.tld_SSL
Change documentroot and scriptalias for cgi-bin
<script> | |
function disableBadInlineCode() { | |
$('style:contains("display: none!important")').each(function (i) { this.disabled = true; }); | |
}; | |
document.addEventListener('DOMContentLoaded', disableBadInlineCode, false); | |
setInterval(disableBadInlineCode, 1000); | |
</script> |
#!/bin/sh | |
# | |
# /etc/init.d/swoole-prod | |
# | |
# Example of init script for UNIX daemon | |
# | |
# chkconfig: 2345 20 80 | |
# description: Example of UNIX daemon | |
### BEGIN INIT INFO |
// ==UserScript== | |
// @name YouTube InstantView customization | |
// @namespace http://tampermonkey.net/ | |
// @version 0.1 | |
// @description try to take over the world! | |
// @author Andrei Telteu | |
// @match https://www.youtube.com/* | |
// @grant none | |
// ==/UserScript== |
<?php | |
// install composer require phpseclib/phpseclib:~2.0 | |
// https://github.com/phpseclib/phpseclib | |
$rsa = new \phpseclib\Crypt\RSA(); | |
$rsa->setPassword($password); | |
$rsa->setPrivateKeyFormat(\phpseclib\Crypt\RSA::PUBLIC_FORMAT_OPENSSH); | |
$rsa->setPublicKeyFormat(\phpseclib\Crypt\RSA::PUBLIC_FORMAT_OPENSSH); | |
$rsa->setComment('[email protected]'); | |
$keys = $rsa->createKey(4096); |
If you are developing with the wordpress theme starter kit roots/sage, and you want to specify a custom ssl certificate for the dev proxy when you run yarn start
, add the ssl certs this way:
Open \wp-content\themes\your-sage-theme\resources\assets\build\webpack.config.watch.js
Add the advanced.browserSync config after delay:
new BrowserSyncPlugin({
target,
open: config.open,
<?php | |
namespace App\Http\Controllers; | |
use Illuminate\Http\Request; | |
use GuzzleHttp\Client; | |
class ProxyController extends Controller | |
{ | |
Create a new file called temps
in a folder that is included in PATH (example sudo nano /usr/local/bin/temps
)
#!/bin/bash
# Purpose: Display the ARM CPU and GPU temperature of Raspberry Pi 2/3
# Author: Vivek Gite <www.cyberciti.biz> under GPL v2.x+
# source: https://www.cyberciti.biz/faq/linux-find-out-raspberry-pi-gpu-and-arm-cpu-temperature-command/
# modified by: Andrei Telteu https://gist.github.com/AndreiTelteu/11dae86616b48578a8e8649802414aaa
# -------------------------------------------------------
cpu=$(</sys/class/thermal/thermal_zone0/temp)
hdd=/dev/sda # lsblk -d to see all