Skip to content

Instantly share code, notes, and snippets.

View f4rr3ll1990's full-sized avatar

F4rr3LL f4rr3ll1990

View GitHub Profile
<!-- Вовод содержимоо поста по ID -->
<?php
$post_id = 55;
$post = get_post( $post_id );
$title = $post->post_title;
$content = $post->post_content;
$tv = get_post_meta( $post_id, 'link', true );
$short = get_the_excerpt();
$tags = wp_get_post_tags($post->ID);
$image = wp_get_attachment_image_src( get_post_thumbnail_id( $post_id ), 'single-post-thumbnail' );
(function($) {
$.fn.myParallax = function( options ) {
var settings = $.extend({
"speed" : "15"
}, options);
return this.each(function() {
var ths = $(this);
ths
.css({
"min-height" : "300px",
@f4rr3ll1990
f4rr3ll1990 / Media_queries
Created July 11, 2017 21:55
Медиа запросы
/* Large desktop */
@media (min-width: 1200px) { }
/* Portrait tablet to landscape and desktop */
@media (min-width: 768px) and (max-width: 979px) { }
/* Landscape phone to portrait tablet */
@media (max-width: 767px) { }
/* Landscape phones and down */
hr {
border: 0;
height: 1px;
background-image: linear-gradient(left , rgba(0, 0, 0, 0.1) 0%, rgba(0, 0, 0, 0.3) 50%, rgba(0, 0, 0, 0.1) 100%);
background-image: -o-linear-gradient(left , rgba(0, 0, 0, 0.1) 0%, rgba(0, 0, 0, 0.3) 50%, rgba(0, 0, 0, 0.1) 100%);
background-image: -moz-linear-gradient(left , rgba(0, 0, 0, 0.1) 0%, rgba(0, 0, 0, 0.3) 50%, rgba(0, 0, 0, 0.1) 100%);
background-image: -webkit-linear-gradient(left , rgba(0, 0, 0, 0.1) 0%, rgba(0, 0, 0, 0.3) 50%, rgba(0, 0, 0, 0.1) 100%);
background-image: -ms-linear-gradient(left , rgba(0, 0, 0, 0.1) 0%, rgba(0, 0, 0, 0.3) 50%, rgba(0, 0, 0, 0.1) 100%);
background-image: -webkit-gradient(
@f4rr3ll1990
f4rr3ll1990 / Media Queries
Last active May 21, 2018 22:30
My basic Interrupt point for adaptive layout
Basic Interrupt point for adaptive layout
/*========== Desktop First Method ==========*/
/* Large Devices, Wide Screens от 0 до 1199 пикселей md*/
@media only screen and (max-width : 1199px) {
}
@f4rr3ll1990
f4rr3ll1990 / DI.m3u
Created December 5, 2017 12:31 — forked from sim642/DI.m3u
Digitally Imported premium streams
#EXTM3U
#EXTINF:-1,Digitally Imported - Ambient
http://pub1.diforfree.org:8000/di_ambient_hi
#EXTINF:-1,Digitally Imported - Big Room House
http://pub1.diforfree.org:8000/di_bigroomhouse_hi
#EXTINF:-1,Digitally Imported - Breaks
http://pub1.diforfree.org:8000/di_breaks_hi
@f4rr3ll1990
f4rr3ll1990 / wp_query.php
Created February 13, 2018 03:27 — forked from akella/wp_query.php
wp query
<?php
$args = array(
'category_name' => 'news',
'posts_per_page' => 3
);
$my_query = new WP_Query( $args );
if ( $my_query->have_posts() ) {
@f4rr3ll1990
f4rr3ll1990 / add options.php
Created February 13, 2018 03:27 — forked from akella/add options.php
ACF Options
<?php
if( function_exists('acf_add_options_page') ) {
acf_add_options_page(array(
'page_title' => 'Theme General Settings',
'menu_title' => 'Website settings',
'menu_slug' => 'theme-general-settings',
'capability' => 'edit_posts',
'redirect' => false