Tag Archives: database

7 Ways to Improve Your Site Speed in WordPress

The post 7 Ways to Improve Your Site Speed in WordPress appeared first on HostGator Blog . For the past several years, Google has been emphasizing site speed as a ranking factor in their algorithms. Given that, it’s amazing to see the number of under-optimized WordPress sites that exist. People spend so much time on “SEO” and content generation, and they forget to do the one thing that will increase the ranking of all their pages. Well, it’s never too late to get started. Here are seven ways to improve your site speed in WordPress. These will make Google sit up and take notice! These are listed in order of importance. Method 1: Use a Datacenter Closest to Your Clients The location of your server plays a big role in your site speed. For example, if your clients are based in the US, then HostGator is an ideal web host, since we have two data centers in the country – one in Texas, and one in Utah. You can view the speed with which your site is fetched by the Googlebot in your search console. Ideally, this should be just a few hundred milliseconds. When I switched my server to a local host, you can see how fast my site fetch speed went down: So don’t ignore this aspect of site speed. It’s crucial! Method 2: Implement Dynamic Caching WordPress generates its pages afresh each time a visitor comes to your site. This is quite a costly process and puts a strain on your database as well as your CPU. In addition, page generation takes time, so there’s a small delay for each visitor. The solution to this is dynamic caching. What is Dynamic Caching? The idea behind dynamic caching is to save a copy of the generated page and serve that copy to the next visitor. This way, each page is generated just once instead of over and over again. Not only is this faster, it reduces the resource load on your server, which means other parts of your site will work faster. It also means that your site can handle many, many more visitors! How to Implement Dynamic Caching on HostGator Dynamic caching can be implemented either with a 3rd party plugin or on the server. Having it enabled on the server is much faster. Not many web hosts allow this, but HostGator offers server caching on their WordPress plans as shown here on the product page: So if you use managed WordPress hosting with HostGator, just turn on the feature and you’re good to go! Here’s a complete review of HostGator WordPress , including all the special features! But even if you don’t have WordPress optimized hosting, you can implement dynamic caching with a plugin. I personally recommend WP Super Cache, which is an extremely popular WordPress plugin, is easy to use, and will get the job done without hassles. Method 3: Use a CDN A CDN is a “Content Distribution Network”. Apart from dynamic pages, there are lots of things on your site that never change. Images, Javascript, and CSS. Well… almost never change. Because of this, it’s best to deliver these resources from a server closest to your client. A CDN looks at the IP address of your visitor and chooses to send static content from a server closest to that location. Which means that people on opposite ends of the earth will receive the content equally fast. It’s really quite a magical technology. As before if you have WordPress hosting with HostGator, a CDN is available by default. But even without such a plan, you can use Cloudflare as your CDN. Despite it being free, I think Cloudflare is one of the best CDNs on the market. HostGator has a tie-up with Cloudflare, which allows for easy integration. You can even do cool stuff like changing your nameservers for faster access. But that’s beyond the scope of this tutorial. Method 4: Deferring or Asyncing JavaScript This one can be a bit tricky. Almost all websites use JavaScript. It’s an essential part of the web, but this adds to the page load time. The key is to wait until the page has fully loaded and is visible before loading JavaScript. It’s easier said than done, and each website works differently. Which is why we need a plugin. The one I recommend is Autoptimize . It’s open source and is almost universally recommended by WordPress gurus. After downloading and installing the plugin on WordPress, you can click the button to aggregate and asynchronously load JavaScript as shown here: The plugin has many options. Make sure to test them all so that your website’s features work properly. Stuff like resizing tables etc are all enabled by Javascript. Method 5: Inlining and Deferring CSS The CSS counterpart to method 4, this refers to delaying the loading of CSS files until the page has downloaded and displayed. However, there’s a catch. If we delay the loading of CSS, our page will look horrible and unstyled, since the CSS files are missing! The solution is called “Inlining” above-the-fold CSS. What this means is that you need to isolate the CSS rules that apply to all visible elements when your page first loads. And then paste those rules directly into every page so that they’re loaded instantly. Once your page has rendered, you can then load the CSS files at your leisure. So how do we do this? Get the Critical CSS This is pretty hard to do manually. So we’re lucky that automatic online tools exist to do it for us! For example, here’s an online tool from SiteLocity that’s quite popular. Simply type in your URL, and it’ll generate the critical above-the-fold CSS for you. Copy the rules that it gives you and use it in the next step. Insert the CSS Inline In method 4, we used the tool “Autoptimize”. Just like before, there is a section in the main settings area to enter your critical CSS as shown here: As shown above, paste the CSS into the box and save your changes. Now when you load your page, all the important CSS will be downloaded immediately, but the external files will be served later when the page has fully loaded. This makes your site blazing fast! Method 6: Lazy Load your Images Images constitute the bulk of a web page’s size. And not surprising, since a single image can be hundreds of MB. So it’s important to only load those images when necessary. “Lazy Loading” is the practice of downloading images only when the user has scrolled far enough to view them. Otherwise, if you have an image way down the article, and the user leaves the page before that, it’s wasted bandwidth both for you as well as the visitor. And it means your site slowed down unnecessarily. Lazy loading is yet another feature that’s difficult to implement manually. Luckily for us, WordPress themselves have released a plugin called Jetpack . I highly recommend using it, since it has a ton of useful features that you can play around with, and lazy loading of images is one of them as shown here: It’s just a single setting! Enable it and you’re done. Now when you visit your page, the images won’t be downloaded until you’re far enough down to see them. In which case, they’ll appear by magic as your user scrolls. Neat right? Method 7: Removing Unnecessary Emoji Code I didn’t notice this myself until I combed through my HTML code. WordPress adds a whole lot of junk useless emoji code to every page in order to render smiley faces and emojis. It’s a useful feature, but it’s a lot of wasted code, and it’s loaded every single time. Luckily, the Autoptimize plugin that we saw earlier has a way to remove them in the “Extra” tab as shown here: Click this option, save your changes, and you’re done! No more emoji code. The idea is to keep your WordPress installation neat and clean, without any unnecessary junk. These seven methods outlined here are a mix of server level and page level optimizations. Together, they should put your site on a fast track to higher rankings, and better experiences for your visitors. Find the post on the HostGator Blog Continue reading

Posted in HostGator, Hosting, VodaHost | Tagged , , , , , , , , , | Comments Off on 7 Ways to Improve Your Site Speed in WordPress

How to Secure a Website from Hackers [10 Step Guide]

The post How to Secure a Website from Hackers [10 Step Guide] appeared first on HostGator Blog . As a website owner, is there anything more terrifying than the thought of seeing all of your work altered or entirely wiped out by a nefarious hacker? We see data breaches and hacks in the news all the time. And you may think, why would someone come after my small business website? But hacks don’t just happen to the big guys. One report found that small businesses were the victims of 43% of all data breaches.  You’ve worked hard on your website (and your brand) – so it’s important to take the time to protect it with these basic hacker protection tips. 5 Easy Steps to Secure Your Website from Hackers You may have worried when starting this post that it would be full of technical jargon that your average website owner would find baffling. Some of our tips further down do get technical, and you may want to bring in your developer for those. But there are a few things you can do on your own first that don’t involve that much technical know-how.  Step #1: Install security plugins. If you built your website with a content management system (CMS) , you can enhance your website security with plugins that actively prevent website hacking attempts. Each of the main CMS options have security plugins available, many of them for free. Security plugins for WordPress: iThemes Security  Bulletproof Security  Sucuri Wordfence fail2Ban Security options for Magento: Amasty Watchlog Pro MageFence Security extensions for Joomla: JHackGuard jomDefender RSFirewall Antivirus Website Protection These options address the security vulnerabilities that are inherent in each platform, foiling additional types of hacking attempts that could threaten your website. In addition, all websites – whether you’re running a CMS-managed site or HTML pages – can benefit from considering SiteLock .  SiteLock goes above and beyond simply closing site security loopholes by providing daily monitoring for everything from malware detection to vulnerability identification to active virus scanning and more. If your business relies on its website, SiteLock is definitely an investment worth considering. Note: Our Managed WordPress hosting plan has SiteLock built in, along with other features to help secure your site. Step #2: Use HTTPS As a consumer, you may already know to always look for the green lock image and https in your browser bar any time you provide sensitive information to a website. Those five little letters are an important shorthand for hacker security: they signal that it’s safe to provide financial information on that particular webpage. An SSL certificate is important because it secures the transfer of information – such as credit cards, personal data, and contact information – between your website and the server. While an SSL certificate has always been essential for ecommerce websites, having one has recently become important for all websites. In July 2018,  Google Chrome released a security update that alerts website visitors if your website doesn’t have an SSL certificate installed. That makes visitors more likely to bounce, even if your website doesn’t collect sensitive information.  Search engines are taking website security more seriously than ever because they want users to have a positive and safe experience browsing the web. Taking the commitment to security further, a search engine may rank your website lower in search results if you don’t have an SSL certificate. What does that mean for you? If you want people to trust your brand, you need to invest in an SSL certificate . The cost of an SSL certificate is minimal, but the extra level of encryption it offers to your customers goes a long way to making your website more secure and trustworthy. At HostGator, we also take website security seriously, but most importantly, we want to make it easy for you to be secure. All HostGator web hosting packages come with a free SSL certificate. The SSL certificate will be automatically applied to your account, but you do need to take a few steps to install the free SSL certificate on your website.  Step #3: Keep your website platform and software up-to-date Using a CMS with various useful plugins and extensions offers a lot of benefits, but it also brings risk. The leading cause of website infections is vulnerabilities in a content management system’s extensible components.  Because many of these tools are created as open-source software programs, their code is easily accessible – to both good-intentioned developers as well as malicious hackers. Hackers can pore over this code, looking for security vulnerabilities that allow them to take control of your website by exploiting any platform or script weaknesses. To protect your website from being hacked, always make sure your content management system, plugins, apps, and any scripts you’ve installed are up-to-date.  If you’re running a website built on WordPress, you can check whether you’re up to date quickly when logging into your WordPress dashboard. Look for the update icon in the top left corner next to your site name. Click the number to access your WordPress Updates. Step #4: Make sure your passwords are secure This one seems simple, but it’s so important. It’s tempting to go with a password you know will always be easy for you to remember. That’s why the #1 most common password is still 123456. You have to do better than that – a lot better than that to prevent login attempts from hackers and other outsiders. Make the effort to figure out a truly secure password (or use HostGator’s password generator).  Make it long. Use a mix of special characters, numbers, and letters. And steer clear of potentially easy-to-guess keywords like your birthday or kid’s name. If a hacker somehow gains access to other information about you, they’ll know to guess those first. Holding yourself to a high standard for password security is step one. You also need to make sure everyone who has access to your website has similarly strong passwords. One weak password within your team can make your website susceptible to a data breach , so set expectations with everyone who has access. Institute requirements for all website users in terms of length and types of characters. If your employees want to use easy passwords for their less secure accounts, that’s their business. But when it comes to your website, it’s your business (literally) and you can hold them to a higher standard.  Step #5: Invest in automatic backups. Even if you do everything else on this list, you still face some risk. The worst-case scenario of a website hack is to lose everything because you forgot to back your website up. The best way to protect yourself is to make sure you always have a recent backup. While a data breach will be stressful no matter what, when you have a current backup, recovering is much easier. You can make a habit out of manually backing your website up daily or weekly. But if there’s even the slightest chance you’ll forget, invest in automatic backups . It’s a cheap way to buy peace of mind.  5 Advanced Steps to Secure Your Website from Hackers All of the above steps are relatively painless, even for website owners with minimal technical experience. This second half of the list gets a little more complicated, and you may want to call a developer or IT consultant to help you out.  Step #6: Take precautions when accepting file uploads through your site. When anyone has the option to upload something to your website, they could abuse the privilege by loading a malicious file, overwriting one of the existing files important to your website, or uploading a file so large it brings your whole website down.  If possible, simply don’t accept any file uploads through your website. Many small business websites can get by without offering the option of file uploads at all. If that describes you, you can skip everything else in this step.   But eliminating file uploads isn’t an option for all websites. Some types of businesses, like accountants or healthcare providers, need to give customers a way to securely provide documents.  If you need to allow file uploads, take a few steps to make sure you protect yourself: Create a whitelist of allowed file extensions. By specifying which types of files you’ll accept, you keep suspicious file types out. Use file type verification. Hackers try to sneakily get around whitelist filters by renaming documents with a different extension than the document type actually is, or adding dots or spaces to the filename.  Set a maximum file size. Avoid distributed denial of service (DDoS) attacks by rejecting any files over a certain size.  Scan files for malware. Use antivirus software to check all files before opening. Automatically rename files upon upload. Hackers won’t be able to re-access their file if it has a different name when they go looking for it.  Keep the upload folder outside of the webroot. This keeps hackers from being able to access your website through the file they upload. These steps can remove most of the vulnerabilities inherent in allowing file uploads to your website.  Step #7: Use parameterized queries SQL injections are one of the most common website hacks many sites fall victim to. SQL injections can come into play if you have a web form or URL parameter that allows outside users to supply information. If you leave the parameters of the field too open, someone could insert code into them that allows access to your database. It’s important to protect your site from this because of the amount of sensitive customer information that can be held in your database. There are a number of steps you can take to protect your website from SQL injection hacks; one of the most important and easiest to implement is the use of parameterized queries. Using parameterized queries ensures your code has specific enough parameters so that there’s no room for a hacker to mess with them. Step #8: Use CSP Cross-site scripting (XSS) attacks are another common threat site owners have to be on the lookout for. Hackers find a way to slip malicious JavaScript code onto your pages, which can then infect the device of any website visitors exposed to the code. Part of the fight to protect your site from XSS attacks is similar to the parameterized queries for SQL injections. Make sure any code you use on your website for functions or fields that allow input are as explicit as possible in what’s allowed, so you’re not leaving room for anything to slip in. Content Security Policy (CSP) is another handy tool that can help protect your site from XSS. CSP allows you to specify which domains a browser should consider valid sources of executable scripts when on your page. The browser will then know not to pay attention to any malicious script or malware that might infect your site visitor’s computer. Using CSP involves adding the proper HTTP header to your webpage that provides a string of directives that tells the browser which domains are ok and any exceptions to the rule.  You can find details on crafting CSP headers for your website here . Step #9: Lock down your directory and file permissions All websites can be boiled down to a series of files and folders that are stored on your web hosting account.  Besides containing all of the scripts and data needed to make your website work, each of these files and folders is assigned a set of permissions that controls who can read, write, and execute any given file or folder, relative to the user they are or the group to which they belong. On the Linux operating system, permissions are viewable as a three-digit code where each digit is an integer between 0-7. The first digit represents permissions for the owner of the file, the second for anyone assigned to the group that owns the file, and the third for everyone else.  The assignations work as follows: 4 equals Read 2 equals Write 1 equals Execute 0 equals no permissions for that user As an example, take the permission code “644.”  In this case, a “6” (or “4+2”) in the first position gives the file’s owner the ability to read and write the file.  The “4” in the second and third positions means that both group users and internet users at large can read the file only – protecting the file from unexpected manipulations. So, a file with “777” (or 4+2+1 / 4+2+1 / 4+2+1) permissions is readable, write-able, and executable by the user, the group, and everyone else in the world. As you might expect, a file that is assigned a permission code that gives anyone on the web the ability to write and execute it is much less secure than one which has been locked down in order to reserve all rights for the owner alone.  Of course, there are valid reasons to open up access to other groups of users (anonymous FTP upload, as one example), but these instances must be carefully considered in order to avoid creating a website security risk. For this reason, a good rule of thumb is to set your permissions as follows: Folders and directories = 755 Individual files = 644 To set your file permissions, log in to your cPanel’s File Manager or connect to your server via FTP.  Once inside, you’ll see a list of your existing file permissions (as in the following example generated using the Filezilla FTP program): The final column in this example displays the folder and file permissions currently assigned to the website’s content.  To change these permissions in Filezilla, simply right click the folder or file in question and select the “File permissions” option.  Doing so will launch a screen that allows you to assign different permissions using a series of checkboxes: Although your web host’s or FTP program’s backend might look slightly different, the basic process for changing permissions remains the same. Our support portal has solutions for how to modify your folder and file permissions . #10 Keep your error messages simple (but still helpful).  Detailed error messages can be helpful internally to help you identify what’s going wrong so you know how to fix it. But when those error messages are displayed to outside visitors, they can reveal sensitive information that tells a potential hacker exactly where your website’s vulnerabilities are.  Be very careful what information you provide in an error message, so you’re not providing information that helps a bad actor hack you. Keep your error messages simple enough that they don’t inadvertently reveal too much. But avoid ambiguity as well , so your visitors can still learn enough information from the error message to know what to do next.  Protecting Your Website from Hackers Securing your site and learning how to protect against hackers is a big part of keeping your site healthy and safe in the long run! Don’t procrastinate taking these important steps.  At HostGator, we have created a set of custom mod security rules to aid in the protection of your website. If you’re looking for a new hosting provider, you can click here to sign up for a great deal. For new accounts, we’ll even transfer you for free! After you’ve created an account, you just need to fill out the form here . Don’t worry about getting tripped up in the process. HostGator has world-class support available around the clock! Our customer support specialists are available 24/7/365 via email ticket, chat, or phone. We can help you get secure! Find the post on the HostGator Blog Continue reading

Posted in HostGator, Hosting, php, VodaHost | Tagged , , , , , , , , , | Comments Off on How to Secure a Website from Hackers [10 Step Guide]

premierehost.net main website is down ?

is it only me or premierehost.net main website is down ? it’s shows ” Critical Error Could not connect to the database. ” [url]https://i…. | Read the rest of http://www.webhostingtalk.com/showthread.php?t=1763288&goto=newpost Continue reading

Posted in HostGator, Hosting, php, VodaHost | Tagged , , , , , , , , , , | Comments Off on premierehost.net main website is down ?

Shared Hosting SSD With Plesk Panel Starting from $1.50

A. Shared Hosting : Bronze : SSD Storage = 1GB Traffic = 1000GB Panel = Plesk Panel Subdomain : Unlimited MySQL Database : Unlimited … | Read the rest of http://www.webhostingtalk.com/showthread.php?t=1746052&goto=newpost Continue reading

Posted in HostGator, Hosting, mysql, php, VodaHost | Tagged , , , , , , , , , , | Comments Off on Shared Hosting SSD With Plesk Panel Starting from $1.50

Mysqldumper fails @ import

Hi, I made a backup of my database with mysqldumper on my old server. now i tryed to import that backup again with mysqldumper on my new se… | Read the rest of http://www.webhostingtalk.com/showthread.php?t=1733966&goto=newpost Continue reading

Posted in HostGator, Hosting, mysql, php, VodaHost | Tagged , , , , , , , , | Comments Off on Mysqldumper fails @ import