The essential news about content management systems and mobile technology. Powered by Perfect Publisher and XT Search for Algolia.
The News Site publishes posts to the following channels: Facebook, Instagram, Twitter, Telegram, Web Push, Tumblr, and Blogger.
The WordPress project team is continuously improving the Site Editor—your one-stop shop for editing and designing your site.
The latest batch of updates—Gutenberg 17.4 and 17.5—include a handful of small but powerful changes designed to improve both your WordPress experience and that of your site’s visitors.
Let’s take a look at what’s new.
When you’re in the zone making changes to the look and feel of your site, you sometimes hit a dead end or realize that the version you had three or four font and color tweaks ago was a bit better. The updated style revisions pane gives you a robust, detailed log of the design changes you’ve made and makes turning back the clock easier with a one-click restore option to take you back to that perfect design.
Newly added pagination and more granular details make this feature even more powerful.
You can access style revisions from the Site Editor by clicking the “Styles” icon on the top right of the page, and then clicking the “Revisions” clock icon.
It’s now much easier to manage your site and post-editing preferences, which have been combined and enhanced in the latest update. In addition to familiar settings, you’ll find new appearance and accessibility options, and an “allow right click” toggle which allows you to override stubborn browser defaults. You can access your preferences by heading to the three-dot menu at the top right of the editor and clicking “Preferences” at the bottom.
The Gallery Block’s always been a great way to show off a collection of photos or images. And now there’s a fun new setting to randomize the order in which those images appear every time the page or post is loaded by a new visitor.
You can turn this setting on with a toggle found at the bottom of the block settings pane:
Not everybody knows about the Site Editor’s List View, but it can make editing your site, posts, and pages significantly faster and easier. A new addition to the List View makes editing even more convenient: just right-click any item in the list to open up the settings menu for the selected block.
Even small changes can make a big difference to your workflow, and your site visitor’s overall experience.
We’d love to hear what you think about the new features when you’ve had a chance to take them for a test drive!
Read more https://wordpress.com/blog/2024/02/20/site-editor-updates/
Laravel Wallet is designed for reliable and flexible transactions and handles the complex part of storing transactions in the database for precise calculations. It provides an intuitive API that is easy to use and straightforward to understand.
Once you have followed the setup instructions, you can set up
the user model with the HasBalance
trait:
namespace App\Models;
use Illuminate\Database\Eloquent\Model;
use O21\LaravelWallet\Contracts\Payable;
use O21\LaravelWallet\Models\Concerns\HasBalance;
class User extends Model implements Payable
{
use HasBalance;
}
Here are some possible commands you can use to work with a
balance on the model. In the following examples, the
$sender
and $recipient
implement the
Payable
interface via the HasBalance
trait:
// Transfer money between sender and recipient
transfer(100, 'USD')->from($sender)->to($recipient)->commit();
// Deposit money into a recipient's account
deposit(100, 'USD')->to($recipient)->overcharge()->commit();
// Charge a user
charge(100, 'USD')->from($sender)->commit();
This package has resulted from the author using it privately on projects, honing it, and now releasing it as open-source. It includes safeguards for balance accuracy and a sophisticated rollback mechanism designed to revert modifications.
To get started with this package, check out the Laravel Wallet documentation—this package is open source and available on GitHub. The documentation also includes a Withdrawal example to demonstrate best practices with this package.
The post Handle Money Transactions in Eloquent with Laravel Wallet appeared first on Laravel News.
Join the Laravel Newsletter to get all the latest Laravel articles like this directly in your inbox.
Read more https://laravel-news.com/wallet
Read more https://build.prestashop-project.org/news/2024/prestashop-8-1-4-maintenance-release/
Tempo is a new date package designed to be small and is the easiest way to work with dates in JavaScript and TypeScript:
Tempo is a new library in a proud tradition of JavaScript date and time libraries. Inspired by the likes of moment.js, day.js, and date-fns, Tempo is built from the ground up to be as small and easy to use as possible — including first-class support for timezone operations.
It includes a collection of utilities for working with
JavaScript’s native Date
object, such as
format
and parse
:
import { format, parse } from "@formkit/tempo"
const readable = format(new Date(), "full"); // Sunday, February 18, 2024
parse(readable, "full"); // Date: 2024-02-18T07:00:00.000Z
Tempo comes with a variety of format styles (i.e.,
full
in the previous example) and tokens for
formatting dates in any way you might need. You can also find a
large number of modifiers and timezone support:
import { addDay, tzDate } from "@formkit/tempo"
// Add 1 day
addDay("2013-03-15"); // 2013-03-16T07:00:00.000Z
// Produces the date for 12 noon Nov 18, 2013 in New York
tzDate("2013-11-18 12:00", "America/New_York")
Tempo looks impressive, offering much of what you'd need to work with dates and has excellent documentation around its functionality; you can get started by reading the docs at tempo.formkit.com. The source code is also available on GitHub at formkit/tempo.
The post Tempo: The Easiest Way to Work With Dates in JavaScript appeared first on Laravel News.
Join the Laravel Newsletter to get all the latest Laravel articles like this directly in your inbox.
Read more https://laravel-news.com/tempo-js-dates
Laracord is a micro-framework to build your next Discord bot
with Laravel alongside DiscordPHP. With this package, you can
create commands (!example
), slash commands
(/example
), events, and more. Your bot can respond to
these features using familiar Artisan console tools and everything
we love about Laravel.
The main features this package provides out of the box give you everything you need to be productive quickly:
Another neat feature is an optional HTTP server (reactphp/HTTP) with Laravel routing support to create webhooks or an API to interact with your bot. For example, your bot could accept an incoming GitHub webhook that you could then handle with your bot.
To get started with this package, check out the documentation at laracord.com. The source code is available on GitHub at laracord/laracord.
The post Create Elegant Discord Bots with Laracord appeared first on Laravel News.
Join the Laravel Newsletter to get all the latest Laravel articles like this directly in your inbox.
Read more https://laravel-news.com/laracord