diff --git a/administrator/components/com_banners/tmpl/banners/blankstate.php b/administrator/components/com_banners/tmpl/banners/blankstate.php index c8dd6f81726d6..6a8f33247cac3 100644 --- a/administrator/components/com_banners/tmpl/banners/blankstate.php +++ b/administrator/components/com_banners/tmpl/banners/blankstate.php @@ -9,26 +9,19 @@ defined('_JEXEC') or die; -use Joomla\CMS\Language\Text; -use Joomla\CMS\Router\Route; +use Joomla\CMS\Factory; +use Joomla\CMS\Layout\LayoutHelper; -?> -
+echo LayoutHelper::render('joomla.content.blankstate', $displayData); diff --git a/administrator/components/com_contact/tmpl/contacts/blankstate.php b/administrator/components/com_contact/tmpl/contacts/blankstate.php index 62679fc98412a..1f35907dc41a5 100644 --- a/administrator/components/com_contact/tmpl/contacts/blankstate.php +++ b/administrator/components/com_contact/tmpl/contacts/blankstate.php @@ -9,26 +9,19 @@ defined('_JEXEC') or die; -use Joomla\CMS\Language\Text; -use Joomla\CMS\Router\Route; +use Joomla\CMS\Factory; +use Joomla\CMS\Layout\LayoutHelper; -?> - +echo LayoutHelper::render('joomla.content.blankstate', $displayData); diff --git a/administrator/components/com_content/tmpl/articles/blankstate.php b/administrator/components/com_content/tmpl/articles/blankstate.php index 8a7d56081b1b6..7f366be01bc9d 100644 --- a/administrator/components/com_content/tmpl/articles/blankstate.php +++ b/administrator/components/com_content/tmpl/articles/blankstate.php @@ -9,26 +9,19 @@ defined('_JEXEC') or die; -use Joomla\CMS\Language\Text; -use Joomla\CMS\Router\Route; +use Joomla\CMS\Factory; +use Joomla\CMS\Layout\LayoutHelper; -?> - +echo LayoutHelper::render('joomla.content.blankstate', $displayData); diff --git a/administrator/components/com_content/tmpl/featured/blankstate.php b/administrator/components/com_content/tmpl/featured/blankstate.php index e6fbad1ecb029..27d0804dd3a1e 100644 --- a/administrator/components/com_content/tmpl/featured/blankstate.php +++ b/administrator/components/com_content/tmpl/featured/blankstate.php @@ -9,4 +9,19 @@ defined('_JEXEC') or die; -require __DIR__ . '/../articles/blankstate.php'; +use Joomla\CMS\Factory; +use Joomla\CMS\Layout\LayoutHelper; + +$displayData = array( + 'textPrefix' => 'COM_CONTENT', + 'formURL' => 'index.php?option=com_content&view=featured', + 'helpURL' => 'https://docs.joomla.org/Special:MyLanguage/Adding_a_new_article', +); +$user = Factory::getUser(); + +if ($user->authorise('core.create', 'com_content') || count($user->getAuthorisedCategories('com_content', 'core.create')) > 0) +{ + $displayData['createURL'] = 'index.php?option=com_content&task=article.add'; +} + +echo LayoutHelper::render('joomla.content.blankstate', $displayData); diff --git a/administrator/components/com_messages/tmpl/messages/blankstate.php b/administrator/components/com_messages/tmpl/messages/blankstate.php index eb86cf342cb8e..bf99cfe4ee4db 100644 --- a/administrator/components/com_messages/tmpl/messages/blankstate.php +++ b/administrator/components/com_messages/tmpl/messages/blankstate.php @@ -9,26 +9,18 @@ defined('_JEXEC') or die; -use Joomla\CMS\Language\Text; -use Joomla\CMS\Router\Route; +use Joomla\CMS\Factory; +use Joomla\CMS\Layout\LayoutHelper; -?> - +echo LayoutHelper::render('joomla.content.blankstate', $displayData); diff --git a/administrator/components/com_newsfeeds/tmpl/newsfeeds/blankstate.php b/administrator/components/com_newsfeeds/tmpl/newsfeeds/blankstate.php index cf3413dd7d816..0ea6b62f8d49d 100644 --- a/administrator/components/com_newsfeeds/tmpl/newsfeeds/blankstate.php +++ b/administrator/components/com_newsfeeds/tmpl/newsfeeds/blankstate.php @@ -9,26 +9,19 @@ defined('_JEXEC') or die; -use Joomla\CMS\Language\Text; -use Joomla\CMS\Router\Route; +use Joomla\CMS\Factory; +use Joomla\CMS\Layout\LayoutHelper; -?> - +echo LayoutHelper::render('joomla.content.blankstate', $displayData); diff --git a/administrator/components/com_privacy/tmpl/consents/blankstate.php b/administrator/components/com_privacy/tmpl/consents/blankstate.php index e2e432401f4b0..1d1a8cbc4d72c 100644 --- a/administrator/components/com_privacy/tmpl/consents/blankstate.php +++ b/administrator/components/com_privacy/tmpl/consents/blankstate.php @@ -9,18 +9,12 @@ defined('_JEXEC') or die; -use Joomla\CMS\Language\Text; +use Joomla\CMS\Layout\LayoutHelper; -?> - +$displayData = array( + 'textPrefix' => 'COM_PRIVACY_CONSENTS', + 'formURL' => 'index.php?option=com_privacy&view=consents', + 'helpURL' => 'https://docs.joomla.org/Special:MyLanguage/Help40:Privacy:_Consents', +); + +echo LayoutHelper::render('joomla.content.blankstate', $displayData); diff --git a/administrator/components/com_privacy/tmpl/requests/blankstate.php b/administrator/components/com_privacy/tmpl/requests/blankstate.php index efc58f58fcfee..8eff92f624301 100644 --- a/administrator/components/com_privacy/tmpl/requests/blankstate.php +++ b/administrator/components/com_privacy/tmpl/requests/blankstate.php @@ -9,26 +9,18 @@ defined('_JEXEC') or die; -use Joomla\CMS\Language\Text; -use Joomla\CMS\Router\Route; +use Joomla\CMS\Factory; +use Joomla\CMS\Layout\LayoutHelper; -?> - +echo LayoutHelper::render('joomla.content.blankstate', $displayData); diff --git a/administrator/components/com_users/tmpl/notes/blankstate.php b/administrator/components/com_users/tmpl/notes/blankstate.php index f261496748188..9793cb50b3da4 100644 --- a/administrator/components/com_users/tmpl/notes/blankstate.php +++ b/administrator/components/com_users/tmpl/notes/blankstate.php @@ -9,26 +9,18 @@ defined('_JEXEC') or die; -use Joomla\CMS\Language\Text; -use Joomla\CMS\Router\Route; +use Joomla\CMS\Factory; +use Joomla\CMS\Layout\LayoutHelper; -?> - +echo LayoutHelper::render('joomla.content.blankstate', $displayData); diff --git a/administrator/language/en-GB/com_banners.ini b/administrator/language/en-GB/com_banners.ini index 0d39eea8fe4cb..0f3d6b3972b63 100644 --- a/administrator/language/en-GB/com_banners.ini +++ b/administrator/language/en-GB/com_banners.ini @@ -35,8 +35,7 @@ COM_BANNERS_BATCH_TIP="If a category is selected for move/copy, any actions sele COM_BANNERS_BEGIN_HINT="Begin date (yyyy-mm-dd)" COM_BANNERS_BEGIN_LABEL="Begin Date" COM_BANNERS_BLANKSTATE_BUTTON_ADD="Add your first banner" -COM_BANNERS_BLANKSTATE_BUTTON_LEARNMORE="Learn more" -COM_BANNERS_BLANKSTATE_CONTACT="Banners are blocks of content containing advertising information and a record of the number of times the banner has been displayed is kept. You can use this component to create and manage your banners." +COM_BANNERS_BLANKSTATE_CONTENT="Banners are blocks of content containing advertising information and a record of the number of times the banner has been displayed is kept. You can use this component to create and manage your banners." COM_BANNERS_BLANKSTATE_TITLE="No Banners have been created yet." COM_BANNERS_CANCEL="Cancel" COM_BANNERS_CLICK="Click" diff --git a/administrator/language/en-GB/com_contact.ini b/administrator/language/en-GB/com_contact.ini index 75edce07cc3ce..3672f73b180a3 100644 --- a/administrator/language/en-GB/com_contact.ini +++ b/administrator/language/en-GB/com_contact.ini @@ -8,8 +8,7 @@ COM_CONTACT_BASIC_OPTIONS_FIELDSET_LABEL="Contact Display Options" COM_CONTACT_BATCH_OPTIONS="Batch process the selected contacts" COM_CONTACT_BATCH_TIP="If a category is selected for move/copy, any actions selected will be applied to the copied or moved contacts. Otherwise, all actions are applied to the selected contacts." COM_CONTACT_BLANKSTATE_BUTTON_ADD="Add your first contact" -COM_CONTACT_BLANKSTATE_BUTTON_LEARNMORE="Learn more" -COM_CONTACT_BLANKSTATE_CONTACT="Contacts can be as simple as a contact form or as complex as a staff directory. You can use this component to create and manage your contacts." +COM_CONTACT_BLANKSTATE_CONTENT="Contacts can be as simple as a contact form or as complex as a staff directory. You can use this component to create and manage your contacts." COM_CONTACT_BLANKSTATE_TITLE="No Contacts have been created yet." COM_CONTACT_CATEGORIES_VIEW_DEFAULT_DESC="Shows a list of contact categories within a category." COM_CONTACT_CATEGORY_VIEW_DEFAULT_DESC="This view lists the contacts in a category." diff --git a/administrator/language/en-GB/com_content.ini b/administrator/language/en-GB/com_content.ini index e1c95b9053571..6510930970117 100644 --- a/administrator/language/en-GB/com_content.ini +++ b/administrator/language/en-GB/com_content.ini @@ -13,7 +13,6 @@ COM_CONTENT_ATTRIBS_FIELDSET_LABEL="Options" COM_CONTENT_BATCH_OPTIONS="Batch process the selected articles" COM_CONTENT_BATCH_TIP="If a category is selected for move/copy, any actions selected will be applied to the copied or moved articles. Otherwise, all actions are applied to the selected articles." COM_CONTENT_BLANKSTATE_BUTTON_ADD="Add your first article" -COM_CONTENT_BLANKSTATE_BUTTON_LEARNMORE="Learn more" COM_CONTENT_BLANKSTATE_CONTENT="Articles are the main content on most Joomla sites. You can use the Joomla Article Editor to create and manage your content." COM_CONTENT_BLANKSTATE_TITLE="No Articles have been created yet." COM_CONTENT_CHANGE_STAGE="Change stage" diff --git a/administrator/language/en-GB/com_messages.ini b/administrator/language/en-GB/com_messages.ini index 21d095a722dc9..192081540cf9d 100644 --- a/administrator/language/en-GB/com_messages.ini +++ b/administrator/language/en-GB/com_messages.ini @@ -5,10 +5,9 @@ COM_MESSAGES="Messaging" COM_MESSAGES_ADD="New Private Message" -COM_MESSAGES_BLANKSTATE_TITLE="There are no messages for you in your inbox." -COM_MESSAGES_BLANKSTATE_REQUESTS="Send messages to other administrators on your site and read their replies." COM_MESSAGES_BLANKSTATE_BUTTON_ADD="Send a message" -COM_MESSAGES_BLANKSTATE_BUTTON_LEARNMORE="Learn more" +COM_MESSAGES_BLANKSTATE_CONTENT="Send messages to other administrators on your site and read their replies." +COM_MESSAGES_BLANKSTATE_TITLE="There are no messages for you in your inbox." COM_MESSAGES_CONFIG_SAVED="Configuration saved." COM_MESSAGES_CONFIGURATION="Messages: Options" COM_MESSAGES_ERR_INVALID_USER="Invalid user" diff --git a/administrator/language/en-GB/com_newsfeeds.ini b/administrator/language/en-GB/com_newsfeeds.ini index 32359da94af0b..787bece3fd1d6 100644 --- a/administrator/language/en-GB/com_newsfeeds.ini +++ b/administrator/language/en-GB/com_newsfeeds.ini @@ -7,8 +7,7 @@ COM_NEWSFEEDS="News Feeds" COM_NEWSFEEDS_BATCH_OPTIONS="Batch process the selected news feeds" COM_NEWSFEEDS_BATCH_TIP="If a category is selected for move/copy, any actions selected will be applied to the copied or moved news feeds. Otherwise, all actions are applied to the selected news feeds." COM_NEWSFEEDS_BLANKSTATE_BUTTON_ADD="Add your first news feed" -COM_NEWSFEEDS_BLANKSTATE_BUTTON_LEARNMORE="Learn more" -COM_NEWSFEEDS_BLANKSTATE_NEWSFEEDS="Adding News Feeds to your sites is a way of integrating content from other web sites." +COM_NEWSFEEDS_BLANKSTATE_CONTENT="Adding News Feeds to your sites is a way of integrating content from other web sites." COM_NEWSFEEDS_BLANKSTATE_TITLE="No News Feeds have been created yet." COM_NEWSFEEDS_CACHE_TIME_HEADING="Cache Time" COM_NEWSFEEDS_CACHE_TIME_HEADING_ASC="Cache Time ascending" diff --git a/administrator/language/en-GB/com_privacy.ini b/administrator/language/en-GB/com_privacy.ini index 5bc0d4983e48a..670ce6d20e2bd 100644 --- a/administrator/language/en-GB/com_privacy.ini +++ b/administrator/language/en-GB/com_privacy.ini @@ -19,9 +19,8 @@ COM_PRIVACY_ACTION_LOG_REMOVE="User {username} remov COM_PRIVACY_ACTION_LOG_REMOVE_BLOCKED="User {username} attempted to remove the data for request #{id} however this action was blocked" COM_PRIVACY_ACTION_VIEW="View Request" COM_PRIVACY_BADGE_URGENT_REQUEST="Urgent" -COM_PRIVACY_BLANKSTATE_BUTTON_LEARNMORE="Learn more" COM_PRIVACY_CONFIGURATION="Privacy: Options" -COM_PRIVACY_CONSENTS_BLANKSTATE_CONSENTS="This screen displays all Privacy: Consents that have been given. You can also invalidate a consent here." +COM_PRIVACY_CONSENTS_BLANKSTATE_CONTENT="This screen displays all Privacy: Consents that have been given. You can also invalidate a consent here." COM_PRIVACY_CONSENTS_BLANKSTATE_TITLE="No Consents have been given yet." COM_PRIVACY_CONSENTS_FILTER_STATE="State of Consents" COM_PRIVACY_CONSENTS_FILTER_SUBJECT="Subject" @@ -135,7 +134,7 @@ COM_PRIVACY_OPTION_LABEL="Options" COM_PRIVACY_POSTINSTALL_BODY="With the introduction of GDPR for EU citizens and similar regulations elsewhere in the world it may be necessary for you to request consent before storing any Personal Information of a user.
Joomla 3.9 introduces new capabilities to assist you in creating site privacy policies and collecting user consent. In addition a workflow is available to help you manage user information requests such as requests for removing their personal data from your site.
For further information on this new feature read the Privacy documentation.
" COM_PRIVACY_POSTINSTALL_TITLE="Increased Management Of Users Privacy" COM_PRIVACY_REQUESTS_BLANKSTATE_BUTTON_ADD="Add your first request" -COM_PRIVACY_REQUESTS_BLANKSTATE_REQUESTS="This screen displays all Privacy: Information Requests that have been received and their status. You can also create a new request here." +COM_PRIVACY_REQUESTS_BLANKSTATE_CONTENT="This screen displays all Privacy: Information Requests that have been received and their status. You can also create a new request here." COM_PRIVACY_REQUESTS_BLANKSTATE_TITLE="No Information Requests have been submitted yet." COM_PRIVACY_REQUEST_COMPLETED="The request has been completed." COM_PRIVACY_REQUEST_FORM_EDIT="Edit Request" diff --git a/administrator/language/en-GB/com_users.ini b/administrator/language/en-GB/com_users.ini index 63da66df1333e..2851a4809b11b 100644 --- a/administrator/language/en-GB/com_users.ini +++ b/administrator/language/en-GB/com_users.ini @@ -230,10 +230,9 @@ COM_USERS_NEW_NOTE="New Note" COM_USERS_NOTE_FORM_EDIT="Edit Note" COM_USERS_NOTE_FORM_NEW="New Note" COM_USERS_NOTES="User Notes: New/Edit" -COM_USERS_NOTES_BLANKSTATE_TITLE="No User Notes have been created yet." -COM_USERS_NOTES_BLANKSTATE_REQUESTS="User Notes can be used to store a range of information about each user on your site." COM_USERS_NOTES_BLANKSTATE_BUTTON_ADD="Add your first note" -COM_USERS_NOTES_BLANKSTATE_BUTTON_LEARNMORE="Learn more" +COM_USERS_NOTES_BLANKSTATE_CONTENT="User Notes can be used to store a range of information about each user on your site." +COM_USERS_NOTES_BLANKSTATE_TITLE="No User Notes have been created yet." COM_USERS_NOTES_FOR_USER="Notes for user %s (ID #%d)" COM_USERS_NOTES_N_ITEMS_ARCHIVED="%d User Notes archived." COM_USERS_NOTES_N_ITEMS_ARCHIVED_1="User Note archived." diff --git a/administrator/language/en-GB/joomla.ini b/administrator/language/en-GB/joomla.ini index 224ee0c254d59..52a4a3fb6250e 100644 --- a/administrator/language/en-GB/joomla.ini +++ b/administrator/language/en-GB/joomla.ini @@ -474,6 +474,7 @@ JGLOBAL_ITEM_FEATURE="Feature Item" JGLOBAL_ITEM_UNFEATURE="Unfeature Item" JGLOBAL_KEEP_TYPING="Keep typing ..." JGLOBAL_LANGUAGE_VERSION_NOT_PLATFORM="Language pack does not match this Joomla! version. Some strings may be missing and will be displayed in English." +JGLOBAL_LEARN_MORE="Learn more" JGLOBAL_LEAST_HITS="Least Hits" JGLOBAL_LEFT="Left" JGLOBAL_LINK_AUTHOR_LABEL="Link to Author's Contact Page" diff --git a/layouts/joomla/content/blankstate.php b/layouts/joomla/content/blankstate.php new file mode 100644 index 0000000000000..bb4fedb4cf74f --- /dev/null +++ b/layouts/joomla/content/blankstate.php @@ -0,0 +1,52 @@ + + * @license GNU General Public License version 2 or later; see LICENSE.txt + */ + +defined('_JEXEC') or die; + +use Joomla\CMS\Factory; +use Joomla\CMS\Language\Text; +use Joomla\CMS\Router\Route; + +$textPrefix = $displayData['textPrefix'] ?? ''; + +if (!$textPrefix) +{ + $textPrefix = strtoupper(Factory::getApplication()->input->get('option')); +} + +$formURL = $displayData['formURL'] ?? ''; +$createURL = $displayData['createURL'] ?? ''; +$helpURL = $displayData['helpURL'] ?? ''; +?> + +