Skip to content

Instantly share code, notes, and snippets.

View fyapy's full-sized avatar
🏠
Working from home

Amir Abdullin fyapy

🏠
Working from home
View GitHub Profile
<?php echo get_permalink(); ?>
<?php
remove_action('wp_head', 'rsd_link');
remove_action('wp_head', 'wlwmanifest_link');
remove_action('wp_head', 'wp_generator');
show_admin_bar(false);
add_theme_support('post-thumbnails');
<?php echo get_cat_name('id');?>
<?php echo category_description('id'); ?>
<?php single_cat_title(); ?>
<?php echo get_post_meta($post->ID, 'name', true); ?>
$("#form").submit(function() {
$.ajax({
type: "POST",
url: "mail.php",
data: $(this).serialize()
}).done(function() {
$(this).find("input").val("");
alert("Спасибо за заявку! Скоро мы с вами свяжемся.");
$("#form").trigger("reset");
});
$(function(){
var a = new String;
a = $('.text_cont_inner').html();
var b = a.indexOf(' ');
if (b == -1) {
b = a.length;
}
$('.text_cont_inner').html('<span class="first_word">'+a.substring(0, b)+'</span>'+a.substring(b, a.length));
});
<?php wp_list_pages(array(
'title_li' => '',
'child_of' => $id,
'show_date' => 'modified',
'date_format' => $date_format
)); ?>
<?php bloginfo('name'); ?>
<?php bloginfo('description'); ?>
<?php wp_head(); ?>
<?php wp_footer(); ?>