Zoom in and cut images in Twenty Seventeen header image

To Solve this issue better to use javascript library imageScale(); Different options available in this(fill, best-fill, best-fit, best-fit-down). You have to just include js file. then after using the following format for the image. <div class=”image-container”> <img class=”scale” data-scale=”best-fit-down” data-align=”center” src=”https://wordpress.stackexchange.com/questions/300845/img/example.jpg”> </div> Now add this JavaScript code to your page. $(function() { $(“img.scale”).imageScale(); }); The … Read more

WordPress hosted on AWS EC2

This type of question isn’t accepted on WordPress’s Stack Exchange. Please check the Accepted Topics. Below is some information for you. If the client’s WordPress site is running on an Amazon EC2 instance, then you don’t need to do anything. WordPress Core, Plugin, and Themes can be updated from the WordPress Admin Dashboard without having … Read more

Silly Problem Referencing a Post ID

I’m surprised, your site works as desired, if you really call the_post for the button. This function does not echo the post’s ID, it simply fetches the next post of the current query. If I understood you correctly (and I’m not so sure about that), you only want to get the current post’s ID so … Read more

How to prevent redirection from non-www to www or vice versa?

So how to prevent the redirection? On the front-end/public side of a WordPress site, that redirection is done by redirect_canonical() which is hooked on template_redirect, and if you really must disable that non-www to www or www to non-www redirection, you can try the following (add the code to your theme’s functions.php file): For disabling … Read more

Can’t Reach wp-admin

When moving / cloning a site to a new URL, just changing the wp-options option_value is not enough. The proper way of doing this is to use a wordpress site cloning plugin (lot’s of free good ones), such as Duplicator. Do a proper archive and install the site on AWS. It should take care of … Read more

How to put wordpress site behind AWS load balancer

When WordPress is behind https proxy (your load balancer) it doesn’t know that https is enabled. Proxy is working through https (443 port) but communication between proxy and WordPress is through http (80 port). For WordPress traffic is through http, that’s why you get redirect loop from https to http (by WordPress) and again from … Read more

tech