Skip to content

Instantly share code, notes, and snippets.

@dimobelov
dimobelov / content.php
Created July 14, 2018 13:46
Pagination in Bludit 3 admin->views
<?php
echo Bootstrap::pageTitle(array('title'=>$L->g('Content'), 'icon'=>'cog'));
function table($status) {
global $Url;
global $Language;
global $published;
global $drafts;
global $scheduled;
@dimobelov
dimobelov / mod_pagespeed .htaccess
Created July 13, 2018 10:21 — forked from solancer/mod_pagespeed .htaccess
mod_pagespeed .htaccess configuration
<IfModule mod_expires.c>
ExpiresActive On
ExpiresByType image/jpg "access 1 year"
ExpiresByType image/jpeg "access 1 year"
ExpiresByType image/gif "access 1 year"
ExpiresByType image/png "access 1 year"
ExpiresByType text/css "access 1 month"
ExpiresByType text/html "access 1 month"
ExpiresByType application/pdf "access 1 month"
ExpiresByType text/x-javascript "access 1 month"
@dimobelov
dimobelov / nginxproxy.md
Created June 21, 2018 05:30 — forked from soheilhy/nginxproxy.md
How to proxy web apps using nginx?

Virtual Hosts on nginx (CSC309)

When hosting our web applications, we often have one public IP address (i.e., an IP address visible to the outside world) using which we want to host multiple web apps. For example, one may wants to host three different web apps respectively for example1.com, example2.com, and example1.com/images on the same machine using a single IP address.

How can we do that? Well, the good news is Internet browsers

add_action( 'wp_enqueue_scripts', 'dequeue_woocommerce_styles_scripts', 99 );
function dequeue_woocommerce_styles_scripts() {
if ( function_exists( 'is_woocommerce' ) ) {
if ( ! is_woocommerce() && ! is_cart() && ! is_checkout() ) {
# Styles
wp_dequeue_style( 'woocommerce-general' );
wp_dequeue_style( 'woocommerce-layout' );
wp_dequeue_style( 'woocommerce-smallscreen' );
wp_dequeue_style( 'woocommerce_frontend_styles' );
@dimobelov
dimobelov / GoogleAnalyticsApi.cs
Created April 6, 2018 20:10 — forked from 0liver/GoogleAnalyticsApi.cs
C# wrapper around the Google Analytics Measurement Protocol API
/* based on the docs at: https://developers.google.com/analytics/devguides/collection/protocol/v1/devguide */
/*
* LICENSE: MIT
* AUTOHR: [email protected]
*/
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
A. Create Installation DVD ISO Via Dism:
1. Extract Win 10 Enterprise version of the mirror sources folder install.wim to D drive temp directory
2. In the temp directory to create WimMount folder, and execute the following command to mount the wim file
Dism /Mount-Wim /WimFile:D:\temp\install.wim /Index:1 /MountDir:D:\temp\WimMount
3. Show the current version
Dism /Image:D:\temp\WimMount /Get-CurrentEdition
4. Show current version
Dism /Image:D:\temp\WimMount /Get-TargetEditions
/*!
* Bootstrap Reboot v4.0.0-beta.2 (https://getbootstrap.com)
* Copyright 2011-2017 The Bootstrap Authors
* Copyright 2011-2017 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
* Forked from Normalize.css, licensed MIT (https://github.com/necolas/normalize.css/blob/master/LICENSE.md)
*/
*,
*::before,
*::after {
public static string[] BulgarianWords =
{
"а",
"автентичен",
"аз",
"ако",
"ала",
"бе",
"без",
"беше",
@dimobelov
dimobelov / allow_svg_in_wordpress_tincymce.txt
Created August 28, 2017 11:41
Function & Filter to Allow Inline SVG in WordPress TinyMCE Editor.
function allow_svg_in_tinymce( $init ) {
// NOTE: This doesn't take into account any security concerns regarding SVG.
// It doesn't remove potential vulnerable elements, etc. It just allows
// SVG, as is, assuming that the uploader is trusted. However, it would
// be easy to remove elements such as script if desired. Just remove from
// the array.
$svgElemList = array(
'a',
@dimobelov
dimobelov / Facebook-xoxo-Congrats.md
Created August 17, 2017 10:35 — forked from ozh/Facebook-xoxo-Congrats.md
Facebook Congrats & Kisses animations

Hearts & kisses :

  • xo
  • xoxo
  • xoxoxo
  • Besos y abrazos
  • bisou
  • bisous
  • baci
  • 꽁냥꽁냥