One of the most important steps a webmaster need to do to improve his site’s speed is to find out what are the files that takes a long time to loads. Most of the time, those resources are big files (images, css, js files…). A simple audit can help you identify then remove or resize those files to improve your site speed.
Finding big files is quite simple nowadays with the help of your browsers. Modern browsers all support this feature so you can perform this audit on any browser that you prefer. In this post, I’m going to perform the task on Chrome.
Disable minify, caching plugins on your site
This step if very important. Minify, caching plugins (such as W3 Total Cache, WP Super Cache…) usually combines file together to reduce the number of requests. While those tools are nice in helping your site load faster, they hide the actual requests made by individual files.
Open your site in a browser tab
Next, open your site in a new tab. You can open a page, a post on your site if your goal is to inspect that single page/post.
Inspect the large files
Now, right click anywhere on the browser window and select inspect. In some browsers, this option is named inspect elements and it appears nearly at the bottom of the context menu.
You should see a new window appears. On that window, locate the Network tab:
Then, finally, reload your page.
You can then see a list of requests that your browser made to your site’s server. When your site finishes loading, click on the Size tab to sort the size of the request in order. It is best to sort the size in decreasing order since you can identify the requests that cost most at the top:
As you can see from my image, the top request cost 789KB, which is very large. It is an image. So, I will consider replacing this one with a smaller image or I can make its size smaller.
Next on the list, you can see that the file epo.min.js is 350KB. It’s a javascript file. When you click on that file, you’ll see its full path:
From the file path, I can tell that it is a plugin (since it’s in wp-content/plugins folder) and its name could be WooCommerce TM Extra Product Options.
You can search for that in your plugins list and see if that plugin is vital to your site. If it isn’t, you should consider deactivating it to save your site from loading a big file.
You can continue this process to the end of the list. Normally, I don’t inspect all items but some resources that have significant size. Something that is over 50KB is worth inspecting (images are exception, I usually start inspecting images when their size exceed 200kb).
Conclusion
Now you know a quite useful technique to find the large files that cause your site to load slowly. It’s time to start working on your site to improve its performance.
Google fonts is a great way to enrich your web typography. There are thousands of fonts available for free. If you have been using new WordPress themes or plugin, you may see that many of them let you pick fonts from Google repository and add to your site. However, you don’t have to use a theme or a plugin to get Google fonts. In this post, I’m showing you the easiest way to install Google fonts in WordPress. You’ll be surprised at how quick it is.
Select a font in Google fonts
The first step, obviously is to select a font form google fonts. Let’s head to https://fonts.google.com/ and pick the fonts you prefer:
As you can see, there are many fonts available. Simply click on the orange plus icon to add it to your list of select fonts.
As you can see, I have added three fonts to my selection. The plus signs were turned to minus so you can remove those fonts in case you need it.
A black box appears at the bottom right of the screen showing the information of the fonts that were added. If I click on that box, there will be a bigger window slide up contains some useful information as well as the installation instructions:
There is one important thing to notice here. There is an orange box says “Load time: Moderate”. This isn’t a good sign because it tells us if we add all these fonts, it will negatively impact our page load time significantly (Adding more fonts, even just one will slow down your site).
Try to remove the fonts you don’t really need. Normally, I select at most two fonts. Let me remove one font so I can get load time: fast.
Before installing the fonts to our site, let’s click on the customize tab.
Here, you can see a list of font-weight and style that you can add. I currently have the regular font weight for both fonts. Adding more styles let you pick more variations for your fonts. However, similar to font family, adding more font styles adds time to site load time. So, you should be very frugal when picking more styles.
How to install Google fonts in WordPress
Let’s head back to the embed tab and grab the installation info:
First, you need to switch to the @import tab. Installing the fonts using the snippets in the standard tab takes more time and require a bit of coding skill (though not much).
Let’s copy the code in first box but excluding <style> and </style>.
Where to put this code? You may ask. Well, let’s go to our site’s dashboard and go to Apperance->Customize-> Additional CSS and paste the code there:
Now, for the second part, let’s copy it. However, before you can paste it, you need to know where do you want to use those fonts. For example, in my case, you want to use Raleway for the whole site, you need to write this in the Additional CSS box:
body { font-family: 'Raleway', sans-serif; }
If you want to use Raleway for body text and Montserrat for the headings, you can place the rules like this:
These rules will work in most case (if your theme adhere to WordPress theme structure standards). However, you can easily use the inspector tool on your browser to find the CSS selectors to apply the fonts.
Conclusion
Now you know how to install Google fonts in WordPress. However, while it is easy to install those pretty fonts, it is also easy to add many fonts and make your site load slowly. It is best to select one or two fonts and strive for the load time: fast for the best results.
There are a lot of times you find your dashboard is flooded with tons of notifications, mostly from plugins and themes.
In rare cases, those notifications are useful. Most of the time, they are outright annoying. Some notifications even appear after you click on the close icons right next to them.
So, you wonder, is there any way to hide these notifications for good? If possible, without using a plugin?
Well, that’s the reason I’m writing this. I’m going to show you the easiest way to hide WordPress dashboard notifications without using any plugin.
Are you ready? Let’s get started.
Hide WordPress Dashboard Notification in less than 1 minute
With this method, you need to write some code. Don’t worry, you are not actually writing any code but to copy and paste some code I have here.
There you go. Now you can hide WordPress dashboard notifications without using any plugin. Let me know what you think and if you have suggestions, leave a comment below.
Creating contact form is super easy in WordPress. Do a simple search and you can find tons of plugins available with 4.5+ star rating. You think that why do you need another tutorial, right? Well, for most people those plugins will work right out of the box and they can move on doing other important things. For some others, things are not so easy.
Maybe you have followed some tutorials, setup exactly as they said but still, the form doesn’t work. In other cases, you may want to add some tweaking to the look and feel of the form.
Whatever your reasons, my goal is to help you setup contact form for your website from scratch and make it work so you never miss an important message from your visitors.
Let’s get started.
Plugins to use
Before we begin, let’s have the following plugins ready:
The first step is to create a contact form with Contact form 7. You should have contact form 7 installed and activated for now.
If you look at your dashboard menu on the left, there should be an option called Contact:
Click on that option, you’ll see contact form 7 screen:
As you can see, there is already a form created for you. Go ahead and delete it as we are going to create a new form.
Click on the add new button at the top to add a new form.
As you can see, there are three main things we are going to do with Contact form 7:
Enter a form name (nearly the easiest thing)
Add, remove fields to your form (hardest)
Click on Save button to save your form (the easiest)
As the form name, you can enter anything you like. In case you need to have multiple contact form, the name should help you tell which for is which.
Now, let’s go ahead to configure the fields of our form.
Normally, a contact form should have the following fields:
Contact name
Contact email
Subject
Message
However, you can add more fields if you need to.
Contact form 7 support a variety of fields as you can see at the top of the form editor:
As you can see, you can even add radio, checkboxes and even quizzes to the contact form, which is very great.
To add any field to your form, first, put the cursor where you want to insert the field, then click on the field you want to insert.
For example, I want to insert a confirmation checkbox below the message box, I click on the space below that message box:
Then, click on acceptance button at the top:
Configure the field before adding to your form
A window will show up for me to configure the field:
There are a few things you need to pay attention to:
Name: this should be human readable and it should tell you what the field is about. If you are adding a telephone field (tel), then you should name it tel, phone…
Id and class: These fields are useful if you want to style them using CSS later. If you are happy with the default, leave them blank.
Condition: this option is specific to acceptance field only
Options: This option is specific to acceptance. In other fields, you will have the required checkbox to mark the field cannot be blank when submitting form.
Now, I have the form ready. I’m going to save it. After saving the form, there is a field appears:
This is the shortcode. You can think of shortcode as a placeholder for a, usually, much bigger text. In this case, it’s our form.
This is the code we put in the contact page to display the contact form. Thus, let’s go ahead and put this code in a page.
If you are using Gutenberg editor, you should add a shortcode element first before putting the shortcode:
In case you use the classic editor, you just paste the code in the page’s body.
Let’s publish the page and take a look at our form:
As you can see, the form looks great and it has all the fields as added in contact form 7 form builder.
Step 2: Configure SMTP server to ensure mail delivery
Nowadays, most hosting providers offer mail function out of the box for PHP (the programing language behind WordPress). As a result, many of you may not have any problem get the contact message delivered to your inbox. However, if you have built your contact form, tried to submit a message but still didn’t see anything in your inbox, it’s time to configure your SMTP server.
Don’t worry about the jargons, it is very simple to fix mail sending problem in WordPress as I made a tutorial here:
The tutorial is for WooCommerce but it works for WordPress too.
Step 3: Put your form in multiple columns
Now you should have the form up and running. When someone submit the form, you should get a message in your inbox. That’s great!
However, what if you want to put the form in multiple columns? No worries, I got you covered!
Here is the detailed tutorial on how to put contact form 7 in multiple columns.
Step 4: Add recaptcha v2 to your form to prevent spam
Spam is a serious problem that any site owner has to face today. When you put up a form, you open a door to your inbox for spammer. Thus, adding captcha to your form is a great way to keep your inbox clean.
If you are not logged in to your gmail account, login first and try visiting that page again. You’ll see a screen like this:
There are two recaptcha options at the time of this writing: v2 and v3. You should select v2, not v3 for this to work.
Make sure you add your domain at “add a domain, e.g. example”
Finally, click on Submit to finalize the process. As a result, you’ll see the keys available in the next screen:
Now, copy them to put in the integration screen on your blog and you are done.
Click on save changes to save the keys.
Now, there is one more thing you need to do. That is putting [recaptcha] tag to the contact form so the captcha will show up.
And when I view the form, sure enough, recaptcha box is there:
Conclusion
As you can see, setting up contact form on WordPress could be quite tricky. However, with the helps of plugins, it is much easier to create fully functional contact page. Hopefully the tutorial is helpful to you. If you need further assistance, don’t hesitate to drop me a message.
Contact form 7 is a great plugin to build contact form for WordPress. In contrast to its super powerful functions, the look at feel of this form builder has been very basic through the years.
One of the most needed feature is to layout the contact form in multiple columns. This feature is available in many form builders. However, we still haven’t seen any sign of it get added to contact form 7.
If you need to layout your form in multiple columns, don’t worry, I got your back.
I will show you how to layout contact form 7 fields in as many columns as you like (well, may not as many as you want but sufficient for all your needs).
Let’s get started.
Step 1: install plugin to enable grid system on your site
We are going to install a plugin which I’ve made a few minutes ago to enable multiple columns layout on your site. My plugin uses a CSS framework called skeleton CSS to let you layout elements on multiple columns.
You are not limited to use this for laying out contact form 7 elements. You can use this for many other things you need.
Install and activate it then you are done. There isn’t anything to configure with my plugin. Isn’t that great 😉
Step 2: Putting contact form 7 elements to columns
Before we actually begin putting contact form 7 elements, I would like to introduce you to our grid system.
There are three elements of our system:
Container (this is the outer most element)
Row (represents a row)
Column (represent a column)
If you now HTML/CSS, this diagram is not strange to you.
Now, let’s create a simple form in contact form 7.
I’m not going to show you how to create a form since it’s very easy to do so. You’d probably know how to do that already.
This is my form code:
I’ll take the shortcode and put on a contact page. This is what I have:
You can see that, everything is in one column.
What if I want to put the email field to the right of the name field?
It is super simple. I’m going to:
Add a container div that wrap the form
Add a row at the top and inside that row, add two columns
One column hosts the name field, the other hosts the email field
I add another row. Inside that row, add one column that spans the whole row.
Then, I put the rest of the form in that row
Here is the code:
The grid system is based on 12 columns layout. So, in the first row (.c7-row), you see that I have two columns, each spans six columns so they will occupy equal amount of space.
On the second row, I put everything in one column that span 12 columns. You can see that the class is twelve columns.
Now, save the form and let’s see the result:
Not surprisingly, we have the two fields: name and email laid out in a single row.
Conclusion
As you can see, it’s very simple to create a contact form 7 form that has multiple columns. Hope you now can create better contact form for your site.
If you have question, please ask. I’d love to hear your feedback.
Are you a dev? Checkout programming tutorials here: datmt.com
We use cookies on our website to give you the most relevant experience by remembering your preferences and repeat visits. By clicking “Accept”, you consent to the use of ALL the cookies.
This website uses cookies to improve your experience while you navigate through the website. Out of these, the cookies that are categorized as necessary are stored on your browser as they are essential for the working of basic functionalities of the website. We also use third-party cookies that help us analyze and understand how you use this website. These cookies will be stored in your browser only with your consent. You also have the option to opt-out of these cookies. But opting out of some of these cookies may affect your browsing experience.
Necessary cookies are absolutely essential for the website to function properly. These cookies ensure basic functionalities and security features of the website, anonymously.
Cookie
Duration
Description
cookielawinfo-checbox-analytics
11 months
This cookie is set by GDPR Cookie Consent plugin. The cookie is used to store the user consent for the cookies in the category "Analytics".
cookielawinfo-checbox-functional
11 months
The cookie is set by GDPR cookie consent to record the user consent for the cookies in the category "Functional".
cookielawinfo-checbox-others
11 months
This cookie is set by GDPR Cookie Consent plugin. The cookie is used to store the user consent for the cookies in the category "Other.
cookielawinfo-checkbox-necessary
11 months
This cookie is set by GDPR Cookie Consent plugin. The cookies is used to store the user consent for the cookies in the category "Necessary".
cookielawinfo-checkbox-performance
11 months
This cookie is set by GDPR Cookie Consent plugin. The cookie is used to store the user consent for the cookies in the category "Performance".
viewed_cookie_policy
11 months
The cookie is set by the GDPR Cookie Consent plugin and is used to store whether or not user has consented to the use of cookies. It does not store any personal data.
Functional cookies help to perform certain functionalities like sharing the content of the website on social media platforms, collect feedbacks, and other third-party features.
Performance cookies are used to understand and analyze the key performance indexes of the website which helps in delivering a better user experience for the visitors.
Analytical cookies are used to understand how visitors interact with the website. These cookies help provide information on metrics the number of visitors, bounce rate, traffic source, etc.
Advertisement cookies are used to provide visitors with relevant ads and marketing campaigns. These cookies track visitors across websites and collect information to provide customized ads.