This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$myposts = get_posts( $args ); //Array of posts | |
$index = 1; | |
$len = count($myposts); | |
foreach( $myposts as $post ): setup_postdata($post); | |
$post_id = $post->ID; | |
?> | |
<?php | |
if( $index%3 === 1): echo '<div class="row">'; //Open row for every 3-rd (change 3 to desired number in one row) | |
endif; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if ( $post = get_page_by_path( 'your-slug', OBJECT, 'your-post-type' ) ){ | |
$post_id = $post->ID; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// in contact form | |
<div class="btn upload-file-btn"> | |
[file file-967 class:fileuploadfield filetypes:.pdf|.txt|.jpg|.png|.gif|doc|.docx|.mp4|.3gp|.avi|.mov] | |
<input type="button" class="uploadbrowse-btn" value="Upload your file*"> | |
<!-- or use button instead --> | |
<!-- <button class="uploadbrowse-btn" value="Upload your file*">Upload your file*</button> --> | |
</div> | |
//css |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$args = array( 'post_type' => 'testimonials', 'posts_per_page' => 10 ); | |
$query = new WP_Query( $args ); | |
while ( $query->have_posts() ) : $query->the_post(); | |
?> | |
<h2> <?php echo the_title(); ?></h2> | |
<div class="content"> | |
<?php echo the_content(); ?> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
::-webkit-scrollbar { | |
width: 10px; | |
} | |
/* Track */ | |
::-webkit-scrollbar-track { | |
background: #f1f1f1; | |
} | |
/* Handle */ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div id="video-container"> | |
<!-- Video --> | |
<video id="video" width="640" height="365"> | |
<source src="videos/mikethefrog.webm" type="video/webm"> | |
<source src="videos/mikethefrog.ogv" type="video/ogv"> | |
<source src="videos/mikethefrog.mp4" type="video/mp4"> | |
<p> | |
Your browser doesn't support HTML5 video. | |
<a href="videos/mikethefrog.mp4">Download</a> the video instead. | |
</p> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
git fetch origin && git reset --hard origin/master && git clean -f -d |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
playsinline | |
autoplay |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ git remote rm origin | |
$ git remote add origin [email protected]:aplikacjainfo/proj1.git | |
$ git config master.remote origin | |
$ git config master.merge refs/heads/master |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$('p').html(function(i, html){ | |
return html.replace(/^[^a-zA-Z]*([a-zA-Z])/g, '<span class="first-letter">$1</span>'); | |
}) |