ArrayUtils::natural_language_join( array $array, bool $enclose_items_with_quotes = false )

Join a string with a natural language conjunction at the end.


Description Description


Parameters Parameters

$array

(Required) The array to join together with the natural language conjunction.

$enclose_items_with_quotes

(Optional) Whether each item in the array should be enclosed within quotation marks.

Default value: false


Top ↑

Return Return

(string) a string containing a list of items and a natural language conjuction.


Top ↑

Source Source

File: packages/woocommerce-blocks/src/Utils/ArrayUtils.php


			


Top ↑

User Contributed Notes User Contributed Notes

You must log in before being able to contribute a note or feedback.