Skip to content

Instantly share code, notes, and snippets.

View keks55's full-sized avatar

keks55

View GitHub Profile
@keks55
keks55 / tint2confrc
Created September 17, 2017 08:50
Tint2 - confrc
#---------------------------------------------
# TINT2CONF CONFIG FILE
default_theme = /root/.config/tint2/default.tint2rc
cmd_property = /usr/bin/env python /usr/bin/tintwizard.py
width = 500
height = 350
@keks55
keks55 / default.tint2rc
Created September 17, 2017 08:55
Tint2 - default
# Tint2 config file
# Generated by tintwizard (http://code.google.com/p/tintwizard/)
# For information on manually configuring tint2 see http://code.google.com/p/tint2/wiki/Configure
# Background definitions
# ID 1
rounded = 7
border_width = 2
background_color = #000000 60
border_color = #FFFFFF 16
@keks55
keks55 / session.php
Created September 24, 2017 13:55
Session for Wordpress plugin
// session value
function keksus_ae_session(){
global $option_name,$options;
if( $options['captcha_on'] == '1' ){
session_start();
if(headers_sent()){
$digits = $options['captcha_digits'];
$_SESSION['captcha'] = rand(pow(10, $digits-1), pow(10, $digits)-1);
$captcha = $_SESSION['captcha'];
return $captcha;
@keks55
keks55 / enqueue.php
Created October 3, 2017 08:56
Wordpress enqueue scripts
// Theme constants paths
define( 'TD', get_template_directory() );
define( 'INC', TD . '/inc' );
define( 'LANGS', TD . '/languages' );
define( 'TD_URI', get_template_directory_uri() );
define( 'JS', TD_URI . '/js' );
define( 'CSS', TD_URI . '/css' );
define( 'WIDGETS', INC . '/widgets' );
// Theme scripts
@keks55
keks55 / customizer.php
Created October 9, 2017 15:09
Customize wordpress example
function q_customize_register( $wp_customize ){
$wp_customize->add_section('themename_color_scheme', array(
'title' => __('q Shortcodes', 'themename'),
'description' => '',
'priority' => 100,
));
$wp_customize->add_setting('themename_theme_options[link_color]', array(
if ( wp_get_theme() == 'Colored' ) {
/*
// if theme active set default values
// default colors
// background colors
set_theme_mod( 'header_bg', '#beeb9f' );
set_theme_mod( 'header_search_bg', '#fff' );
set_theme_mod( 'header_submenu_bg', '#000' );
set_theme_mod( 'header_submenu_mobile_bg', '#252525' );
set_theme_mod( 'content_bg', '#fff8e3' );
@keks55
keks55 / tint2rc
Created December 8, 2017 08:41
home/alex/.config/tint2
# Tint2 config file
# Generated by tintwizard (http://code.google.com/p/tintwizard/)
# For information on manually configuring tint2 see http://code.google.com/p/tint2/wiki/Configure
# Background definitions
# ID 1
rounded = 7
border_width = 2
background_color = #000000 60
border_color = #FFFFFF 16
@keks55
keks55 / rc.xml
Created December 8, 2017 08:42
openbox config
<?xml version="1.0" encoding="UTF-8"?>
<!-- Do not edit this file, it will be overwritten on install.
Copy the file to $HOME/.config/openbox/ instead. -->
<openbox_config xmlns="http://openbox.org/3.4/rc" xmlns:xi="http://www.w3.org/2001/XInclude">
<resistance>
<strength>10</strength>
<screen_edge_strength>20</screen_edge_strength>
</resistance>
<focus>
<focusNew>yes</focusNew>
@keks55
keks55 / .bashrc
Created December 8, 2017 08:44
.bashrc
# ~/.bashrc: executed by bash(1) for non-login shells.
# Note: PS1 and umask are already set in /etc/profile. You should not
# need this unless you want different defaults for root.
# PS1='${debian_chroot:+($debian_chroot)}\h:\w\$ '
# umask 022
# You may uncomment the following lines if you want `ls' to be colorized:
# export LS_OPTIONS='--color=auto'
# eval "`dircolors`"
@keks55
keks55 / .bashrc
Created December 30, 2017 15:25
.bashrc
# ~/.bashrc: executed by bash(1) for non-login shells.
# Note: PS1 and umask are already set in /etc/profile. You should not
# need this unless you want different defaults for root.
# PS1='${debian_chroot:+($debian_chroot)}\h:\w\$ '
# umask 022
# You may uncomment the following lines if you want `ls' to be colorized:
# export LS_OPTIONS='--color=auto'
# eval "`dircolors`"