Skip to content

Instantly share code, notes, and snippets.

View sarvar's full-sized avatar

Sarvar sarvar

  • Uzbekistan, Tashkent
View GitHub Profile
@sarvar
sarvar / index.html
Created October 17, 2019 06:38
Equal img height
<div class="section-item__photo">
<img .../ >
</div>
@sarvar
sarvar / index.html
Created October 3, 2019 06:01
add class on click and remove from others
<ul>
<li><a id="about-link" class="" href="#">ABOUT</a></li>
<li><a id="events-link" href="#">EVENTS</a></li>
<li><a id="reviews-link" href="#">REVIEWS</a></li>
<li><a id="contact-link" href="#">CONTACT</a></li>
</ul>
@sarvar
sarvar / gulpfile.js
Created September 12, 2019 12:59
The Simplest Ways to Handle HTML Includes
var fileinclude = require('gulp-file-include'),
gulp = require('gulp');
gulp.task('fileinclude', function() {
gulp.src(['index.html'])
.pipe(fileinclude({
prefix: '@@',
basepath: '@file'
}))
.pipe(gulp.dest('./'));
@sarvar
sarvar / index.html
Created August 22, 2019 02:17
CSS Circle background in percentages
<div class="circle"><span>Lorem ipsum</span></div>
@sarvar
sarvar / npm.txt
Created August 16, 2019 09:42
UNABLE_TO_VERIFY_LEAF_SIGNATURE
npm config set strict-ssl false
@sarvar
sarvar / loop-custom.php
Created June 24, 2019 21:15
WordPress - Custom Post Type Loop
<?php
$loop = new WP_Query( array(
'post_type' => 'Property',
'posts_per_page' => -1
)
);
?>
<?php while ( $loop->have_posts() ) : $loop->the_post(); ?>
@sarvar
sarvar / style.css
Created May 27, 2019 12:12
Only bottom box-shadow
box-shadow: 0 5px 15px -4px rgba(0,0,0,.16)
@sarvar
sarvar / index.html
Created May 16, 2019 10:34
Flexbox Sticky Footer
<body class="d-flex flex-column">
<div id="page-content">
<div class="container text-center">
<div class="row justify-content-center">
<div class="col-md-7">
<h1 class="font-weight-light mt-4 text-white">Sticky Footer using Flexbox</h1>
<p class="lead text-white-50">Use just two Bootstrap 4 utility classes and three custom CSS rules and you will have a flexbox enabled sticky footer for your website!</p>
</div>
</div>
</div>
@sarvar
sarvar / filezilla.txt
Created May 3, 2019 05:36
Filezilla under proxy
Go to the Generic proxy tab in the settings, select HTTP/1.1 and enter the proxy details. The proxy you use must support HTTP/1.1 and the CONNECT method to work with FileZilla.
@sarvar
sarvar / htaccess
Created April 26, 2019 02:38
301 редирект с одного домена на другой
RewriteEngine on
RewriteCond %{HTTP_HOST} ^www\.old-site\.ru$ [NC]
RewriteRule ^(.*)$ https://new-site.ru/$1 [L,R=301]
RewriteCond %{HTTP_HOST} ^old-site\.ru$ [NC]
RewriteRule ^(.*)$ https://new-site.ru/$1 [L,R=301]