Tag: Pagely

  • Resize Pagely images with URL parameters & PressThumb

    Pagely doesn’t resize images that are the wrong dimensions (height / width) on the fly.

    (Though, if PressThumb is enabled, it will convert them to ‘next gen’ formats and reduce the file size of the image automatically).

    For example, if you upload an image to the WordPress admin and then later on register a new image size it won’t try to crop the image on the fly to match the new image size on the front end if you then call that image size in get_the_post_thumbnail() or similar (WordPress VIP, will do this however).

    My advice there would be to resize the image (or images) via the WP-CLI wp media regenerate command or similar.

    However if you just want to resize a particular image for a particular image and PressThumb is enabled you can do this by modifying the URL.

    From Pagely support:

    You would want to update the image URL to include the desired dimensions, yes. You can do so by appending -widthxheight after the file name but before the file extension.

    As an example, if you wanted to change the dimensions of https://example.com/wp-content/uploads/2021/10/example.jpg to 123 pixels wide by 456 pixels high then the URL you’d need to use for the image would be https://example.com/wp-content/uploads/2021/10/example-123×456.jpg. You can even combine that with optimized webp images by appending .webp to the URL as normal. For something like that, the URL would be https://example.com/wp-content/uploads/2021/10/example-123×456.jpg.webp


  • Disable image optimisation on Pagely

    PressThumb can be disabled by renaming the pagely-pressthumb.php plugin in the mu-plugins directory to pagely-pressthumb.php.off.

    Pressthumb optimization can be re-enabled by renaming the file back to its original name.


  • Google font not loading / broken after Pagely clone using a Mai Engine powered WordPress theme

    Not sure exactly where the fault lied, but the issue was the font was pointing to domain.com/dom12345/wp-content/fonts/ instead of domain.com/wp-content/fonts/.

    Running pagely-wp search-replace /dom12345/wp-content/fonts/ /wp-content/fonts/ was enough to solve it.


  • Add http basic auth to Pagely website

    http basic auth is handy when you want to add a username and password to stop anyone (including web crawlers) from accessing a website you’re working on, like a staging or development website.

    To add http basic auth in Pagely, go to to the Pagely Dashboard (atomic.pagely.com), go to Apps and choose the site you want to add http basic auth to.

    From there, choose the ARES tab and choose New Access Rule. Set the options you want – including the username and password – hit Save and then choose Deploy Changes.

    Anyone accessing the website in future will need to enter the username and password to proceed.

    Tip: if you’re on a Mac, you can save the username and password in Safari to save you having to re-enter it in future.


  • Run WP-CLI commands on Pagely without errors from PHP version

    I hit an issue on Pagely where I was running a WP-CLI command – via SSH – but I kept hitting a PHP fatal error.

    When I looked into the error it was because the site was running PHP 7.4, but WP-CLI on Pagely was running PHP 7.3 so my code was breaking on the command line.

    Turns out all you need to do is use pagely-wp instead of wp (thanks Kevin!) and the command will run at the correct version of PHP.

    So instead of:

    wp search-replace staging.website.com www.website.com
    

    Do:

    pagely-wp search-replace staging.website.com www.website.com
    

  • Convert .pfx SSL certificate to .cer

    From the command line, replacing the filename as necessary (you will need the password for the certificate, if one is assigned):

    $ openssl pkcs12 -in wildcard.filename.com_2022.pfx -out wildcard.filename.com_2022.cer -nodes

    If the above does not generate a certificate for you along with the private key, try adding the -legacy flag, like this:

    $ openssl pkcs12 -in wildcard.filename.com_2022.pfx -out wildcard.filename.com_2022.cer -nodes -legacy

    I needed to do this to convert a .pfx SSL certificate for use with Pagely.

    EDIT: If you’re doing this for Pagely and the original certificate is a .pfx, after converting it you will likely need to open the .cer file in TextEdit and grab the two different parts.

    One starting with -----BEGIN PRIVATE KEY----- and one starting with -----BEGIN CERTIFICATE----- and paste them in the appropriate fields after you select Add Certificate > Import Existing Private Key & Certificate options in the Pagely dashboard.


  • Stop WP Rocket infinite loop when purging cache on Pagely

    https://github.com/wp-media/wp-rocket/pull/3166/commits/1ad2f46de776eb1f41f5d621034bb1fb1784201a


  • Uptime monitoring on Pagely

    https://support.pagely.com/hc/en-us/articles/115002550591-24-7-Website-Uptime-Monitoring-and-Outreach-for-Your-Pagely-VPS


  • Difference between VBURST and VPS-1 Pagely plans

    VBURST uses AWS T3 processors (https://aws.amazon.com/ec2/instance-types/t3/), which aren’t as powerful as the VPS-1. Same amount of cores, but they throttle after a certain usage (cpu credits) which is tracked in your Atomic dashboard. If your sites are very cacheable and you’re not pushing a ton of traffic, it should work fine.
    You also don’t get live chat on those plans, but all the other services included: https://pagely.com/plans-pricing/wordpress-vps-hosting/#plandetail