Test Task - joomla-projects/Joomla-Academy-Onboarding GitHub Wiki

🧪 Joomla Plugin Task: Auto Meta Description and Keywords

📋 Task Overview

Your objective is to develop a custom Joomla content plugin that automatically enhances article metadata. This plugin should ensure every article has appropriate meta description and meta keywords fields filled, based on the article’s content.

🎯 Task Requirements

1. Meta Description Handling

Check if the Joomla article has a meta description set.

If it does not, extract either:

  • The article's intro text (if available), or
  • The first paragraph of the full article content.

Save this extracted text as the article’s meta description.

2. Meta Keywords Generation

Check if the Joomla article has meta keywords set.

If it does not:

  1. perform a word frequency analysis over the entire article content.
  2. Identify the most frequently occurring words.

Save these words as comma-separated values in the meta keywords field.

⚙️ Plugin Trigger

Use the appropriate Joomla plugin lifecycle events to hook into article saving operations.

✅ Completion Checklist

  • Plugin installs correctly via the Joomla Plugin Manager.
  • Meta description is set when absent, using article content.
  • Meta keywords are generated dynamically and stored properly.
  • Code is well-organised, commented, and adheres to Joomla coding standards.

[!TIP] Thinking around the issue and making good choices for improvements will be rewarded