');
+ //printInfoTextElement('end of collapse');
+
+ break;
+ default:
+ printErrorTextElement(sprintf(localize("error.content.data.part.unknown"), $elementNode["type"]));
+ break;
+ }
+}
+
?>
diff --git a/commons/strings.json b/commons/strings.json
index 430ba20..a8d5f15 100644
--- a/commons/strings.json
+++ b/commons/strings.json
@@ -106,8 +106,12 @@
"error.content.tags.alphanumeric": "One of the tags given in the \"tags\" URL parameter is not a valid alphanumeric string.",
"error.content.detect.type": "The type of requested content couldn't be determined.",
"error.content.id.alphanumeric": "The requested resource's ID isn't valid.",
- "error.content.data.not.exist": "The requested resource's doesn't have an associated item file.",
+ "error.content.data.not.exist": "The requested content doesn't have an internal item file.",
"error.content.data.no.title": "No title found !",
+ "error.content.data.no.tags": "No tags found !",
+ "error.content.data.no.parts": "No content parts were found for this content !",
+ "error.content.data.no.subpart": "No sub-element were found for this element !",
+ "error.content.data.part.unknown": "Unknown element: \"%s\" !",
"content.title.error": "Error",
"content.title.content": "Content",
@@ -118,6 +122,18 @@
"content.search.count.single": "result",
"content.search.count.multiple": "results",
+ "content.commons.version.current": "Current version",
+ "content.commons.version.previous.single": "Previous version",
+ "content.commons.version.previous.multiple": "Previous versions",
+ "content.commons.version.old.single": "Old version",
+ "content.commons.version.old.multiple": "Old versions",
+ "content.commons.cpu": "CPU Architecture",
+ "content.commons.cpu.x64": "x64",
+ "content.commons.cpu.x86": "x86",
+ "content.commons.lang": "Language",
+ "content.commons.download.single": "Download",
+ "content.commons.download.multiple": "Downloads",
+
"about.biography.title": "Who am I ?",
"about.philosophy.title": "Projects philosophy",
"about.skills.title": "Skills",
@@ -235,8 +251,12 @@
"error.content.tags.alphanumeric": "Un des tags donné dans le paramètre d'URL \"tags\" n'est pas une chaîne de texte alphanumérique valide.",
"error.content.detect.type": "Le type de contenu désiré n'as pas pu être détecté.",
"error.content.id.alphanumeric": "L'ID de la ressource demandée n'est pas valide.",
- "error.content.data.not.exist": "La ressource demandée n'a pas de fichier de données associé.",
+ "error.content.data.not.exist": "Le contenu demandée n'a pas de fichier de données interne associé.",
"error.content.data.no.title": "Aucun titre trouvé !",
+ "error.content.data.no.tags": "Aucun tag trouvé !",
+ "error.content.data.no.parts": "Aucun élément à présenter n'a été trouvé !",
+ "error.content.data.no.subpart": "Aucun sous-élément n'a été trouvé pour cet élément !",
+ "error.content.data.part.unknown": "Élément inconnu: \"%s\" !",
"content.title.error": "Erreur de contenu",
"content.title.content": "Content",
@@ -247,6 +267,18 @@
"content.search.count.single": "résultat",
"content.search.count.multiple": "résultats",
+ "content.commons.version.current": "Version actuelle",
+ "content.commons.version.previous.single": "Version précédente",
+ "content.commons.version.previous.multiple": "Versions précédentes",
+ "content.commons.version.old.single": "Ancienne version",
+ "content.commons.version.old.multiple": "Anciennes versions",
+ "content.commons.cpu": "Architecture de CPU",
+ "content.commons.cpu.x64": "x64",
+ "content.commons.cpu.x86": "x86",
+ "content.commons.lang": "Langue",
+ "content.commons.download.single": "Téléchargement",
+ "content.commons.download.multiple": "Téléchargements",
+
"about.biography.title": "Qui suis-je ?",
"about.philosophy.title": "Philosophie des projets",
"about.skills.title": "Compétences",
diff --git a/content/index.json b/content/index.json
index c369813..5a0aaa4 100644
--- a/content/index.json
+++ b/content/index.json
@@ -1,47 +1,47 @@
[
- {
- "id": "test01",
- "title": {
- "en": "Test article",
- "fr": "Article de test"
- },
- "preamble": {
- "en": "This is a test article, please ignore it",
- "fr": "Ceci est un article de test, veuillez l'ignorer."
- },
- "image": "/resources/Azias/imgs/angry-alchool-pussy.png",
- "tags": [
- "test", "programming", "purebasic"
- ]
- },
- {
- "id": "test02",
- "title": {
- "en": "Test article #2",
- "fr": "Article de test #2"
- },
- "preamble": {
- "en": "This is a test article, please ignore it",
- "fr": "Ceci est un article de test, veuillez l'ignorer."
- },
- "image": "test.jpg",
- "tags": [
- "test", "programming", "docker"
- ]
- },
{
"id": "lscom-cli",
"title": {
- "en": "PB-ListComPort - CLI COM port enumerator",
- "fr": "PB-ListComPort - Enumérateur de port COM pour invité de commande"
+ "en": "PB-ListComPort",
+ "fr": "PB-ListComPort"
},
"preamble": {
- "en": "A simple tool that can list COM ports with their name, friendly name and device name easily and cleanly. This tool is intended to replace the tedious task of having to use the mode command, and the Device Manager to find a newly plugged-in device that provides a COM port.",
+ "en": "A simple CLI tool that can list COM ports with their name, friendly name and device name easily and cleanly. This tool is intended to replace the tedious task of having to use the mode command, and the Device Manager to find a newly plugged-in device that provides a COM port.",
"fr": "..."
},
"image": "/resources/Azias/imgs/lscom-v2-text-01-bkgd-cli.png",
"tags": [
"application", "lscom", "purebasic", "windows"
]
+ },
+ {
+ "id": "youtube-auto-archiver",
+ "title": {
+ "en": "Youtube-Auto-Archiver",
+ "fr": "Youtube-Auto-Archiver"
+ },
+ "preamble": {
+ "en": "...",
+ "fr": "..."
+ },
+ "image": "/resources/Azias/imgs/placeholder.jpg",
+ "tags": [
+ "docker", "web", "python"
+ ]
+ },
+ {
+ "id": "excel-worksheet-password-remover",
+ "title": {
+ "en": "Excel-Worksheet-Password-Remover",
+ "fr": "Excel-Worksheet-Password-Remover"
+ },
+ "preamble": {
+ "en": "Small web page from which you can easily remove a password from an Excel worksheet without uploading any file, directly in your browser. It works by leaving the task of editing the XML files on an Excel document to your browser instead to keep everything local.",
+ "fr": "Petite application web qui permet de facilement retirer le mot de passe d'une feuille de calcul Excel depuis votre navigateur web sans avoir à uploader le fichier sur internet. Cette application laisse votre navigateur modifier les fichiers XML du fichier Excel afin de tout garder en local."
+ },
+ "image": "/resources/Azias/imgs/excel-password-remover.png",
+ "tags": [
+ "tool", "web"
+ ]
}
]
diff --git a/content/index.php b/content/index.php
index a43ccc3..36fb829 100644
--- a/content/index.php
+++ b/content/index.php
@@ -8,11 +8,8 @@ include_once 'content.php';
// Checking if an error occurred while loading data and parsing the URL.
$content_error_code = 200;
if($content_has_error) {
- if(is_null($requested_tags)) {
- // Failed to parse URL and detect a default category.
- header("HTTP/1.1 400 Bad Request");
- $content_error_code = 400;
- } elseif(is_null($filtered_content_index_data)) {
+ // TODO: Add condition for the lack of data for an item.
+ if(is_null($filtered_content_index_data)) {
// Failed to get a display type or to extract types.
header("HTTP/1.1 400 Bad Request");
$content_error_code = 400;
@@ -35,6 +32,7 @@ if($content_has_error) {
+
@@ -56,7 +54,15 @@ if($content_has_error) {
} elseif($requested_content_display_type == ContentDisplayType::SEARCH) {
echo(localize("content.title.content").'❱'.localize("content.title.search"));
} elseif($requested_content_display_type == ContentDisplayType::CONTENT) {
- echo(localize("content.title.content").'❱$TODO');
+ $_nav_title_text = '' . localize("error.content.data.no.title") . '';
+ if (array_key_exists("page", $requested_item_data["title"])) {
+ if (array_key_exists($user_language, $requested_item_data["title"]["page"])) {
+ $_nav_title_text = $requested_item_data["title"]["page"][$user_language];
+ } elseif (array_key_exists($default_language, $requested_item_data["title"]["page"])) {
+ $_nav_title_text = $requested_item_data["title"]["page"][$user_language];
+ }
+ }
+ echo(localize("content.title.content").'❱'.$_nav_title_text);
}
?>
@@ -74,6 +80,9 @@ if($content_has_error) {
endMainCard();
if($SHOW_CONTENT_DEBUG_CARD) {
+ // ################
+ // Debugging card
+ // ################
echo('