If you want to learn how to secure your blog posts, and pages so nobody can copy it or even select the text, then follow along the instructions given below and you’ll be able to secure all your blog posts at once.
[Read more…] about How to Secure Your Content – in Blogger and WordPressWP Basics
How to Embed a YouTube Video in WordPress Blog
If you ever want to embed a YouTube video within your blog post, just follow along with this blog post.
It’s an easy thing to do and just takes less than a minute to accomplish!
Related: How to embed code snippet using GitHub Gist ( opens in a new tab )
Steps to embed a YouTube video
- Go to the video that you want to embed.
- Click on the ‘Share’ button
- Select ‘Embed’ and copy the HTML code that’s given there
- Now get back to your blog/website and just paste the code (in your HTML view/Raw view – not directly where you write the blog post because we don’t want to have any formatting done to the code.
- Important: now this step is vital for your video to show up without any issues. After pasting the iframe code, between the two <iframe> tags, type something (I usually type “video” – without the quotes, of course). This is important or the video might not show up sometimes.
That’s all. This is how you embed a YouTube video within your blog post!
If you want to customize how your video preview looks, you can do so here:
Please leave your comment or questions related to this in the comments section below.
How To Embed Code Snippet Using Github Gist Within Blog Posts
Have you ever wanted to embed a code snippet in your blog?
Yes, we have the <code> tag within the WordPress visual editor but if you notice a lot of the bloggers, developers use Github gist to do that.
Related: How to embed YouTube videos ( opens in a new tab )
Here’s a sample from Brian Gardner from StudioPress/Copyblogger using the Github gist:
It’s quite simple.
- Just go to https://gist.github.com
- Input the code and click on ‘create secret gist‘ – this way search engines wouldn’t index your code and only people with the URL will have access to it.
- Share using the ‘Embed’ code option – copy the embed code and paste it within your WordPress code editor (the Text tab, not the Visual tab).
- You can also download this code sample as a zip file.
Below given are some screenshots for your reference.
Next time you want to share your code on your blog, try the Github Gist.
How to Add Scroll to Top Button to Any Theme
Let’s say we are hungry and want to eat something badly!
Recommended reading: Get Pat’s Theme!
We have two options:
- Buy all groceries, ingredients, gas and cook our meal.
- Order food from a restaurant and eat.
Though the first option is more healthy and more satisfactory compared to the second, the latter one is pretty quick to satiate our hunger.
In this guide post, we will focus on the second option to add a scroll to top button in a WordPress theme.
Note: This plugin has been tested on a Genesis child theme as well. It works perfectly fine!
For this purpose, we will download and use a plugin called WPFront Scroll Top. A free plugin!
After having experimented with a lot of plugins that promised to do this job, I finally found the WPFront Scroll Top plugin. This not only did the job, it was also easy to customize the look and functionality.
And for those who are looking for option # 1 to cook their own meal, here you go:
How To Add A Menu Link To Show Random Posts In WordPress
Our online behavior is random, just like the events in our lives sometimes.
We will be reading one thing and then next thing we see is we move on to something else totally different in context – thanks to all the distracting plethora of information available online.
The fact is, it is not the problem with the internet, but that’s the way how our mind works too. Similarly, I wanted to show you how to add a menu item to a WordPress blog and make it go to any of your blog posts…in a random fashion.
In WordPress, there is a cool way to show random posts with a click of a button.
There is a neat plugin created by the creator of WordPress, Matt Mullenweg called Random Redirect. This can be accomplished by adding codes to your theme too, but if you prefer a neat to-the-job plugin, then Random Redirect is the way to go.
Step 1: Download the plugin from here. Install and activate it.
Step 2: Add a menu item with whatever name you want. E.g. ‘Random’, ‘Surprise me’, ‘I am curious’, etc. from the Appearances > Menus
Step 3: Add the link as yourdomainname.com/?random=
(replace the yourdomainname with your actual domain name)
That’s all you have to do to add a menu item to show random posts from your WordPress site.
In case you want to accomplish this without using any plugin, then there is a wonderful post written by Syed Balkhi and his team at wpbeginner.com.