Skip to content

Instantly share code, notes, and snippets.

@Itachicz11
Itachicz11 / myjs.js
Created June 22, 2012 15:46
Here is myjs.js file
if($('#iph_check').next().attr('checked')){
$('#iph_check').iphoneSwitch("on",
function() {
if($('#iph_check').next().attr('checked')){
//then checked attribute exist so modify it!
$('#iph_check').next().prop('checked', !$checkbox[0].checked);
}else{
$('#iph_check').next().attr('checked', true);
@Itachicz11
Itachicz11 / jquery.iphone-switch
Created June 22, 2012 15:44
Here is my jquery.iphone-switch file
/************************************************
* jQuery iphoneSwitch plugin *
* *
* Author: Daniel LaBare *
* Date: 2/4/2008 *
************************************************/
jQuery.fn.iphoneSwitch = function(start_state, switched_on_callback, switched_off_callback, options) {
var state = start_state == 'on' ? start_state : 'off';
@Itachicz11
Itachicz11 / smof.js
Created May 2, 2012 17:55
On the bottom of this document is initialize of ibutton
/**
* SMOF js
*
* contains the core functionalities to be used
* inside SMOF
*/
jQuery.noConflict();
/** Fire up jQuery - let's dance!
@Itachicz11
Itachicz11 / jquery.ibutton.css
Created May 2, 2012 17:53
Here is my jquery.ibutton.css enque
/**
* Create Options page
*
* @uses wp_enqueue_style()
*
* @since 1.0.0
*/
function of_style_only(){
wp_enqueue_style('admin-style', ADMIN_DIR . 'assets/css/admin-style.css');
wp_enqueue_style('color-picker', ADMIN_DIR . 'assets/css/colorpicker.css');
@Itachicz11
Itachicz11 / functions.interface.php
Created May 2, 2012 17:49
Here I enque ibutton jquery (last enque in column)
/**
* Create Options page
*
* @uses add_action()
* @uses wp_enqueue_script()
*
* @since 1.0.0
*/
function of_load_only()
@Itachicz11
Itachicz11 / function.php
Created May 1, 2012 15:30
This is my function.php
<?php
/*----------------------- Remowe admin bar --------------------------*/
show_admin_bar( false );
/*----------------------- Include shortcodes --------------------------*/
add_filter('the_content', 'do_shortcode');
@Itachicz11
Itachicz11 / other.js
Created April 29, 2012 21:17
That's how i call my accordions
$(function() {
$('.accordion').collapse()
});
@Itachicz11
Itachicz11 / index.html
Created April 29, 2012 17:34
html output
<div class="accordion" id="accordion2">
<div class="accordion-group">
<div class="accordion-heading">
<a class="accordion-toggle" data-toggle="collapse" data-parent="#accordion2" href="#collapseOne">
Collapsible Group Item #1
</a>
</div>
<div id="collapseOne" class="accordion-body in collapse" style="height: auto; ">
<div class="accordion-inner">
Anim pariatur cliche reprehenderit, enim eiusmod high life accusamus terry richardson ad squid. 3 wolf moon officia aute, non cupidatat skateboard dolor brunch. Food truck quinoa nesciunt laborum eiusmod. Brunch 3 wolf moon tempor, sunt aliqua put a bird on it squid single-origin coffee nulla assumenda shoreditch et. Nihil anim keffiyeh helvetica, craft beer labore wes anderson cred nesciunt sapiente ea proident. Ad vegan excepteur butcher vice lomo. Leggings occaecat craft beer farm-to-table, raw denim aesthetic synth nesciunt you
@Itachicz11
Itachicz11 / accordion.js
Created April 29, 2012 17:33
accordion.js
/* =============================================================
* bootstrap-collapse.js v2.0.3
* http://twitter.github.com/bootstrap/javascript.html#collapse
* =============================================================
* Copyright 2012 Twitter, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
@Itachicz11
Itachicz11 / wordprses menu html output
Created April 14, 2012 12:58
This is HTML output of my wp menu
<div id="mine_menu" class="span12">
<div class="menu-hlavni-menu-container">
<ul id="menu-hlavni-menu" class="menu">
<li id="menu-item-83" class="menu-item menu-item-type-post_type menu-item-object-page current-menu-item page_item page-item-77 current_page_item menu-item-83"><a href="http://localhost/Vectoryl/">Home</a></li>
<li id="menu-item-134" class="menu-item menu-item-type-post_type menu-item-object-page current-menu-ancestor current_page_ancestor menu-item-134"><a href="http://localhost/Vectoryl/?page_id=132">Blog</a>
<ul class="sub-menu" style="display: block; ">
<li id="menu-item-72" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-72"><a href="http://localhost/Vectoryl/?page_id=70">Blog three columns</a></li>