Merge branch 'master' into patch-1

This commit is contained in:
Ali Demirtas 2018-09-18 00:28:52 +03:00 committed by GitHub
commit d2716a0bde
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
43 changed files with 208 additions and 176 deletions

View File

@ -9,9 +9,10 @@ function updateBludit() {
if( ($site->currentBuild() < BLUDIT_BUILD) || isset($_GET['update']) ) {
Log::set('UPDATE SYSTEM - Starting.');
// Updates only for version less than Bludit v3.0 rc-3
if ($site->currentBuild()<'20180910') {
@mkdir(PATH_WORKSPACES, DIR_PERMISSIONS, true);
$plugins = array('pluginRSS', 'pluginSitemap', 'pluginTimeMachineX', 'pluginBackup');
$plugins = array('simple-stats', 'pluginRSS', 'pluginSitemap', 'pluginTimeMachineX', 'pluginBackup');
foreach ($plugins as $plugin) {
if (pluginActivated($plugin)) {
Log::set('UPDATE SYSTEM - Re-enable plugin: '.$plugin);
@ -19,6 +20,7 @@ function updateBludit() {
activatePlugin($plugin);
}
}
}
// Set the current build number
$site->set(array('currentBuild'=>BLUDIT_BUILD));

View File

@ -687,116 +687,6 @@ class Pages extends dbJSON {
return $newKey;
}
public function rescanClimode()
{
Log::set('CLI MODE'.LOG_SEP.'Starting re-scan on pages directory.');
$pageList = array();
// Search for pages
$directories = Filesystem::listDirectories(PATH_PAGES, $regex='*', $sortByDate=false);
foreach($directories as $directory) {
if( Sanitize::pathFile($directory.DS.FILENAME) ) {
$pageKey = basename($directory);
$pageList[$pageKey] = true;
// Search for children pages
$subDirectories = Filesystem::listDirectories(PATH_PAGES.$pageKey.DS, $regex='*', $sortByDate=false);
foreach($subDirectories as $subDirectory) {
if( Sanitize::pathFile($subDirectory.DS.FILENAME) ) {
$subPageKey = basename($subDirectory);
$subPageKey = $pageKey.'/'.$subPageKey;
$pageList[$subPageKey] = true;
}
}
}
}
Log::set('CLI MODE'.LOG_SEP.'Updating pages...');
$keys = array_keys($pageList);
foreach($keys as $pageKey) {
// Checksum
$checksum = md5_file(PATH_PAGES.$pageKey.DS.FILENAME);
// New page
if( !isset($this->db[$pageKey]) ) {
$this->verifyFieldsClimode($pageKey, true);
}
// Update page
elseif($this->db[$pageKey]['md5file']!=$checksum) {
$this->verifyFieldsClimode($pageKey, false);
}
}
Log::set('CLI MODE'.LOG_SEP.'Removing pages...');
foreach( array_diff_key($this->db, $pageList) as $pageKey=>$data ) {
Log::set('CLI MODE'.LOG_SEP.'Removing page from database, key: '.$pageKey);
unset( $this->db[$pageKey] );
}
$this->save();
}
private function verifyFieldsClimode($key, $insert=true)
{
$page = new Page($key);
$db = $page->getDB();
// Content from file
$db['content'] = $db['contentRaw'];
// Parent
$db['parent'] = '';
$db['slug'] = $key;
$explodeKey = explode('/', $key);
if(isset($explodeKey[1])) {
$db['parent'] = $explodeKey[0];
$db['slug'] = $explodeKey[1];
}
// Date
if( !isset($db['date']) ) {
$db['date'] = Date::current(DB_DATE_FORMAT);
}
// Status
if( !isset($db['type']) ) {
$db['type'] = CLI_STATUS;
}
// Owner username
if( !isset($db['username']) ) {
$db['username'] = CLI_USERNAME;
}
// New page or update page
if($insert) {
Log::set('CLI MODE'.LOG_SEP.'New page found, key:'.$key);
return $this->add($db, $climode=true);
} else {
Log::set('CLI MODE'.LOG_SEP.'Different checksum, updating page, key:'.$key);
return $this->edit($db, $climode=true);
}
}
private function stylingFieldsForFile($field, $value)
{
// Support for Markdown files, good approach for Github
if (FILENAME==='index.md') {
if ($field==='title') {
return '#Title: '.$value;
} elseif ($field==='content') {
return '---'.PHP_EOL.$value;
} else {
return '<!-- '.Text::firstCharUp($field).': '.$value.' -->';
}
}
// Legacy style of Bludit with index.txt
if ($field==='content') {
return 'Content:'.PHP_EOL.$value;
}
return Text::firstCharUp($field).': '.$value;
}
// Returns an Array, array('tagSlug'=>'tagName')
// (string) $tags, tag list separated by comma.
public function generateTags($tags)

View File

@ -352,5 +352,8 @@
"the-content-is-saved-as-a-draft-to-publish-it": "The content is saved as a draft. To publish it click on the button <b>Publish<\/b> or if you still working on it click on <b>Save as draft<\/b>.",
"site": "Site",
"first": "First",
"last": "Last"
"last": "Last",
"there-are-no-pages-at-this-moment": "There are no pages at this moment.",
"there-are-no-static-pages-at-this-moment": "There are no static pages at this moment.",
"there-are-no-draft-pages-at-this-moment": "There are no draft pages at this moment."
}

View File

@ -352,5 +352,8 @@
"the-content-is-saved-as-a-draft-to-publish-it": "The content is saved as a draft. To publish it click on the button <b>Publish<\/b> or if you still working on it click on <b>Save as draft<\/b>.",
"site": "Site",
"first": "First",
"last": "Last"
"last": "Last",
"there-are-no-pages-at-this-moment": "There are no pages at this moment.",
"there-are-no-static-pages-at-this-moment": "There are no static pages at this moment.",
"there-are-no-draft-pages-at-this-moment": "There are no draft pages at this moment."
}

View File

@ -353,5 +353,8 @@
"the-content-is-saved-as-a-draft-to-publish-it": "The content is saved as a draft. To publish it click on the button <b>Publish<\/b> or if you still working on it click on <b>Save as draft<\/b>.",
"site": "Site",
"first": "First",
"last": "Last"
"last": "Last",
"there-are-no-pages-at-this-moment": "There are no pages at this moment.",
"there-are-no-static-pages-at-this-moment": "There are no static pages at this moment.",
"there-are-no-draft-pages-at-this-moment": "There are no draft pages at this moment."
}

View File

@ -353,5 +353,8 @@
"the-content-is-saved-as-a-draft-to-publish-it": "Der Inhalt ist als Entwurf gespeichert. Um ihn zu veröffentlichen, klicke <b>Veröffentlichen<\/b>, wenn du ihn du weiter daran arbeiten möchtest, klicke <b>Als Entwurf speichern<\/b>.",
"site": "Website",
"first": "First",
"last": "Last"
"last": "Last",
"there-are-no-pages-at-this-moment": "Es gibt keine Seiten.",
"there-are-no-static-pages-at-this-moment": "Es gibt keine statischen Inhalte.",
"there-are-no-draft-pages-at-this-moment": "Es gibt keine Entwürfe."
}

View File

@ -353,5 +353,8 @@
"the-content-is-saved-as-a-draft-to-publish-it": "Der Inhalt ist als Entwurf gespeichert. Um ihn zu veröffentlichen, klicke <b>Veröffentlichen<\/b>, wenn du ihn du weiter daran arbeiten möchtest, klicke <b>Als Entwurf speichern<\/b>.",
"site": "Website",
"first": "First",
"last": "Last"
"last": "Last",
"there-are-no-pages-at-this-moment": "Es gibt keine Seiten.",
"there-are-no-static-pages-at-this-moment": "Es gibt keine statischen Inhalte.",
"there-are-no-draft-pages-at-this-moment": "Es gibt keine Entwürfe."
}

View File

@ -353,5 +353,8 @@
"the-content-is-saved-as-a-draft-to-publish-it": "The content is saved as a draft. To publish it click on the button <b>Publish<\/b> or if you still working on it click on <b>Save as draft<\/b>.",
"site": "Site",
"first": "First",
"last": "Last"
"last": "Last",
"there-are-no-pages-at-this-moment": "There are no pages at this moment.",
"there-are-no-static-pages-at-this-moment": "There are no static pages at this moment.",
"there-are-no-draft-pages-at-this-moment": "There are no draft pages at this moment."
}

View File

@ -281,10 +281,10 @@
"minute": "minuto",
"example-page-1-slug": "crea-tu-propio-contenido",
"example-page-1-title": "Crea tu propio contenido",
"example-page-1-content": "Comience a escribir su propio contenido o edite el actual para adaptarlo a sus necesidades. Para crear, editar o eliminar contenido debe iniciar sesión en el <a href=\".\/admin\/\">panel de administración<\/a> con el nombre de usuario <code>admin</code> y la contraseña que configuró en el proceso de instalación.",
"example-page-1-content": "Comience a escribir su propio contenido o edite el actual para adaptarlo a sus necesidades. Para crear, editar o eliminar contenido debe iniciar sesión en el <a href=\".\/admin\/\">panel de administración<\/a> con el nombre de usuario <code>admin<\/code> y la contraseña que configuró en el proceso de instalación.",
"example-page-2-slug": "set-up-your-new-site",
"example-page-2-title": "Configure su nuevo sitio",
"example-page-2-content": "Actualice la configuración de su sitio desde el <a href=\".\/admin\/\">panel de administración<\/a>, puede cambiar el título, la descripción y las redes sociales desde <a href=\"./admin/settings-general\">Configuracion > General</a>.",
"example-page-2-content": "Actualice la configuración de su sitio desde el <a href=\".\/admin\/\">panel de administración<\/a>, puede cambiar el título, la descripción y las redes sociales desde <a href=\".\/admin\/settings-general\">Configuracion > General<\/a>.",
"example-page-3-slug": "follow-bludit",
"example-page-3-title": "Sigue Bludit",
"example-page-3-content": "Seguinos en las redes sociales <a href=\"https:\/\/www.facebook.com\/bluditcms\/\" target=\"_blank\">Facebook<\/a>, <a href=\"https:\/\/www.twitter.com\/bludit\" target=\"_blank\">Twitter<\/a> y <a href=\"https:\/\/plus.google.com\/+Bluditcms\" target=\"_blank\">Google Plus<\/a> para estar informado de las ultimas noticias, nuevos plugins, nuevos temas, y las ultimas versiones. También podes seguir nuestro <a href=\"https:\/\/blog.bludit.com\" target=\"_blank\">Blog<\/a>.",
@ -347,10 +347,13 @@
"access-denied": "Acceso denegado",
"choose-images-to-upload": "Elige imágenes para subir",
"insert": "Insertar",
"upload": "Upload",
"autosave": "Autosave",
"the-content-is-saved-as-a-draft-to-publish-it": "The content is saved as a draft. To publish it click on the button <b>Publish<\/b> or if you still working on it click on <b>Save as draft<\/b>.",
"site": "Site",
"first": "First",
"last": "Last"
"upload": "Subir",
"autosave": "Autoguardado",
"the-content-is-saved-as-a-draft-to-publish-it": "El contenido se guarda como borrador. Para publicarlo haz clic en el botón <b>Publicar<> o si sigues trabajando en él haz clic en <b>Guardar como borrador<\/b>",
"site": "Sitio",
"first": "Primero",
"last": "Último",
"there-are-no-pages-at-this-moment": "No hay páginas en este momento.",
"there-are-no-static-pages-at-this-moment": "No hay páginas estáticas en este momento.",
"there-are-no-draft-pages-at-this-moment": "No hay páginas borrador en este momento."
}

View File

@ -352,5 +352,8 @@
"the-content-is-saved-as-a-draft-to-publish-it": "The content is saved as a draft. To publish it click on the button <b>Publish<\/b> or if you still working on it click on <b>Save as draft<\/b>.",
"site": "Site",
"first": "First",
"last": "Last"
"last": "Last",
"there-are-no-pages-at-this-moment": "There are no pages at this moment.",
"there-are-no-static-pages-at-this-moment": "There are no static pages at this moment.",
"there-are-no-draft-pages-at-this-moment": "There are no draft pages at this moment."
}

View File

@ -352,5 +352,8 @@
"the-content-is-saved-as-a-draft-to-publish-it": "The content is saved as a draft. To publish it click on the button <b>Publish<\/b> or if you still working on it click on <b>Save as draft<\/b>.",
"site": "Site",
"first": "First",
"last": "Last"
"last": "Last",
"there-are-no-pages-at-this-moment": "There are no pages at this moment.",
"there-are-no-static-pages-at-this-moment": "There are no static pages at this moment.",
"there-are-no-draft-pages-at-this-moment": "There are no draft pages at this moment."
}

View File

@ -353,5 +353,8 @@
"the-content-is-saved-as-a-draft-to-publish-it": "The content is saved as a draft. To publish it click on the button <b>Publish<\/b> or if you still working on it click on <b>Save as draft<\/b>.",
"site": "Site",
"first": "First",
"last": "Last"
"last": "Last",
"there-are-no-pages-at-this-moment": "There are no pages at this moment.",
"there-are-no-static-pages-at-this-moment": "There are no static pages at this moment.",
"there-are-no-draft-pages-at-this-moment": "There are no draft pages at this moment."
}

View File

@ -353,5 +353,8 @@
"the-content-is-saved-as-a-draft-to-publish-it": "The content is saved as a draft. To publish it click on the button <b>Publish<\/b> or if you still working on it click on <b>Save as draft<\/b>.",
"site": "Site",
"first": "First",
"last": "Last"
"last": "Last",
"there-are-no-pages-at-this-moment": "There are no pages at this moment.",
"there-are-no-static-pages-at-this-moment": "There are no static pages at this moment.",
"there-are-no-draft-pages-at-this-moment": "There are no draft pages at this moment."
}

View File

@ -353,5 +353,8 @@
"the-content-is-saved-as-a-draft-to-publish-it": "The content is saved as a draft. To publish it click on the button <b>Publish<\/b> or if you still working on it click on <b>Save as draft<\/b>.",
"site": "Site",
"first": "First",
"last": "Last"
"last": "Last",
"there-are-no-pages-at-this-moment": "There are no pages at this moment.",
"there-are-no-static-pages-at-this-moment": "There are no static pages at this moment.",
"there-are-no-draft-pages-at-this-moment": "There are no draft pages at this moment."
}

View File

@ -352,5 +352,8 @@
"the-content-is-saved-as-a-draft-to-publish-it": "The content is saved as a draft. To publish it click on the button <b>Publish<\/b> or if you still working on it click on <b>Save as draft<\/b>.",
"site": "Site",
"first": "First",
"last": "Last"
"last": "Last",
"there-are-no-pages-at-this-moment": "There are no pages at this moment.",
"there-are-no-static-pages-at-this-moment": "There are no static pages at this moment.",
"there-are-no-draft-pages-at-this-moment": "There are no draft pages at this moment."
}

View File

@ -352,5 +352,8 @@
"the-content-is-saved-as-a-draft-to-publish-it": "The content is saved as a draft. To publish it click on the button <b>Publish<\/b> or if you still working on it click on <b>Save as draft<\/b>.",
"site": "Site",
"first": "First",
"last": "Last"
"last": "Last",
"there-are-no-pages-at-this-moment": "There are no pages at this moment.",
"there-are-no-static-pages-at-this-moment": "There are no static pages at this moment.",
"there-are-no-draft-pages-at-this-moment": "There are no draft pages at this moment."
}

View File

@ -353,5 +353,8 @@
"the-content-is-saved-as-a-draft-to-publish-it": "The content is saved as a draft. To publish it click on the button <b>Publish<\/b> or if you still working on it click on <b>Save as draft<\/b>.",
"site": "Site",
"first": "First",
"last": "Last"
"last": "Last",
"there-are-no-pages-at-this-moment": "There are no pages at this moment.",
"there-are-no-static-pages-at-this-moment": "There are no static pages at this moment.",
"there-are-no-draft-pages-at-this-moment": "There are no draft pages at this moment."
}

View File

@ -352,5 +352,8 @@
"the-content-is-saved-as-a-draft-to-publish-it": "The content is saved as a draft. To publish it click on the button <b>Publish<\/b> or if you still working on it click on <b>Save as draft<\/b>.",
"site": "Site",
"first": "First",
"last": "Last"
"last": "Last",
"there-are-no-pages-at-this-moment": "There are no pages at this moment.",
"there-are-no-static-pages-at-this-moment": "There are no static pages at this moment.",
"there-are-no-draft-pages-at-this-moment": "There are no draft pages at this moment."
}

View File

@ -352,5 +352,8 @@
"the-content-is-saved-as-a-draft-to-publish-it": "The content is saved as a draft. To publish it click on the button <b>Publish<\/b> or if you still working on it click on <b>Save as draft<\/b>.",
"site": "Site",
"first": "First",
"last": "Last"
"last": "Last",
"there-are-no-pages-at-this-moment": "There are no pages at this moment.",
"there-are-no-static-pages-at-this-moment": "There are no static pages at this moment.",
"there-are-no-draft-pages-at-this-moment": "There are no draft pages at this moment."
}

View File

@ -353,5 +353,8 @@
"the-content-is-saved-as-a-draft-to-publish-it": "The content is saved as a draft. To publish it click on the button <b>Publish<\/b> or if you still working on it click on <b>Save as draft<\/b>.",
"site": "Site",
"first": "First",
"last": "Last"
"last": "Last",
"there-are-no-pages-at-this-moment": "There are no pages at this moment.",
"there-are-no-static-pages-at-this-moment": "There are no static pages at this moment.",
"there-are-no-draft-pages-at-this-moment": "There are no draft pages at this moment."
}

View File

@ -353,5 +353,8 @@
"the-content-is-saved-as-a-draft-to-publish-it": "The content is saved as a draft. To publish it click on the button <b>Publish<\/b> or if you still working on it click on <b>Save as draft<\/b>.",
"site": "Site",
"first": "First",
"last": "Last"
"last": "Last",
"there-are-no-pages-at-this-moment": "There are no pages at this moment.",
"there-are-no-static-pages-at-this-moment": "There are no static pages at this moment.",
"there-are-no-draft-pages-at-this-moment": "There are no draft pages at this moment."
}

View File

@ -353,5 +353,8 @@
"the-content-is-saved-as-a-draft-to-publish-it": "The content is saved as a draft. To publish it click on the button <b>Publish<\/b> or if you still working on it click on <b>Save as draft<\/b>.",
"site": "Site",
"first": "First",
"last": "Last"
"last": "Last",
"there-are-no-pages-at-this-moment": "There are no pages at this moment.",
"there-are-no-static-pages-at-this-moment": "There are no static pages at this moment.",
"there-are-no-draft-pages-at-this-moment": "There are no draft pages at this moment."
}

View File

@ -349,5 +349,8 @@
"the-content-is-saved-as-a-draft-to-publish-it": "The content is saved as a draft. To publish it click on the button <b>Publish<\/b> or if you still working on it click on <b>Save as draft<\/b>.",
"site": "Site",
"first": "First",
"last": "Last"
"last": "Last",
"there-are-no-pages-at-this-moment": "There are no pages at this moment.",
"there-are-no-static-pages-at-this-moment": "There are no static pages at this moment.",
"there-are-no-draft-pages-at-this-moment": "There are no draft pages at this moment."
}

View File

@ -353,5 +353,8 @@
"the-content-is-saved-as-a-draft-to-publish-it": "Содержимое сохранено как черновик. Для публикации нажимте на кнопку <b>Опубликовать<\/b> или вы можете продолжить редактирование нажав на <b>Сохранить как черновик<\/b>.",
"site": "Сайт",
"first": "Первый",
"last": "Последний"
"last": "Последний",
"there-are-no-pages-at-this-moment": "There are no pages at this moment.",
"there-are-no-static-pages-at-this-moment": "There are no static pages at this moment.",
"there-are-no-draft-pages-at-this-moment": "There are no draft pages at this moment."
}

View File

@ -351,5 +351,8 @@
"the-content-is-saved-as-a-draft-to-publish-it": "İçerik taslak olarak kaydedilir. Yayınlamak için <b>Yayınla<\/b> seçeneğine tıklayın ya da hala üzerinde çalışıyorsanız <b>Taslak olarak kaydet<\/b> seçeneğini seçin.",
"site": "Site",
"first": "İlk",
"last": "Son"
"last": "Son",
"there-are-no-pages-at-this-moment": "Şu anda hiç sayfa yok.",
"there-are-no-static-pages-at-this-moment": "Şu anda hiç sabit sayfa yok.",
"there-are-no-draft-pages-at-this-moment": "Şu anda taslak sayfa yok."
}

View File

@ -353,5 +353,8 @@
"the-content-is-saved-as-a-draft-to-publish-it": "Контент збережено як чернетку. Для публікації натисніть на кнопку <b>Опублікувати<\/b> або якщо ви все ще працюєте над ним, натисніть на <b>Зберегти як чернетку<\/b>.",
"site": "Сайт",
"first": "Перший",
"last": "Останній"
"last": "Останній",
"there-are-no-pages-at-this-moment": "There are no pages at this moment.",
"there-are-no-static-pages-at-this-moment": "There are no static pages at this moment.",
"there-are-no-draft-pages-at-this-moment": "There are no draft pages at this moment."
}

View File

@ -352,5 +352,8 @@
"the-content-is-saved-as-a-draft-to-publish-it": "The content is saved as a draft. To publish it click on the button <b>Publish<\/b> or if you still working on it click on <b>Save as draft<\/b>.",
"site": "Site",
"first": "First",
"last": "Last"
"last": "Last",
"there-are-no-pages-at-this-moment": "There are no pages at this moment.",
"there-are-no-static-pages-at-this-moment": "There are no static pages at this moment.",
"there-are-no-draft-pages-at-this-moment": "There are no draft pages at this moment."
}

View File

@ -352,5 +352,8 @@
"the-content-is-saved-as-a-draft-to-publish-it": "The content is saved as a draft. To publish it click on the button <b>Publish<\/b> or if you still working on it click on <b>Save as draft<\/b>.",
"site": "Site",
"first": "First",
"last": "Last"
"last": "Last",
"there-are-no-pages-at-this-moment": "There are no pages at this moment.",
"there-are-no-static-pages-at-this-moment": "There are no static pages at this moment.",
"there-are-no-draft-pages-at-this-moment": "There are no draft pages at this moment."
}

View File

@ -352,5 +352,8 @@
"the-content-is-saved-as-a-draft-to-publish-it": "The content is saved as a draft. To publish it click on the button <b>Publish<\/b> or if you still working on it click on <b>Save as draft<\/b>.",
"site": "Site",
"first": "First",
"last": "Last"
"last": "Last",
"there-are-no-pages-at-this-moment": "There are no pages at this moment.",
"there-are-no-static-pages-at-this-moment": "There are no static pages at this moment.",
"there-are-no-draft-pages-at-this-moment": "There are no draft pages at this moment."
}

View File

@ -2,11 +2,11 @@
"plugin-data":
{
"name": "Backup",
"description": "Einfach Backups erstellen und wiederherstellen."
"description": "Einfach Backups erstellen und wieder einspielen."
},
"create-backup": "Backup erstellen",
"download": "Backup herunterladen",
"restore-backup": "Backup wiederherstellen",
"delete-backup": "Backup löschen",
"there-are-no-backups-for-the-moment": "Derzeit bibt es keine Backups."
"there-are-no-backups-for-the-moment": "Es gibt keine Backups."
}

View File

@ -2,11 +2,11 @@
"plugin-data":
{
"name": "Backup",
"description": "Einfach Backups erstellen und wiederherstellen."
"description": "Einfach Backups erstellen und wieder einspielen."
},
"create-backup": "Backup erstellen",
"download": "Backup herunterladen",
"restore-backup": "Backup wiederherstellen",
"delete-backup": "Backup löschen",
"there-are-no-backups-for-the-moment": "Derzeit gibt es keine Backups."
"there-are-no-backups-for-the-moment": "Es gibt keine Backups."
}

View File

@ -2,11 +2,11 @@
"plugin-data":
{
"name": "Yedekleme",
"description": "Yedek almak için en kolay yol."
"description": "Yedek oluşturmak için en kolay yol."
},
"create-backup": "Yedek Al",
"create-backup": "Yedek oluştur",
"download": "İndir",
"restore-backup": "Geri Yükle",
"delete-backup": "Delete Backup",
"there-are-no-backups-for-the-moment": "There are no backups for the moment"
"restore-backup": "Geri yükle",
"delete-backup": "Yedeklemeyi sil",
"there-are-no-backups-for-the-moment": "Şu an için yedek yok"
}

View File

@ -1,7 +1,7 @@
{
"plugin-data":
{
"name": "HTML Code",
"name": "HTML-Code",
"description": "HTML-, JavaScript- oder CSS-Code in den Header-Bereich des Themes oder über oder unter den Inhaltsbereich des Themes einfügen."
},
"insert-code-in-the-theme-inside-the-tag-head": "Code in den Bereich &#60;head&#62; &#60;/head&#62; des Themes einfügen.",

View File

@ -1,7 +1,7 @@
{
"plugin-data":
{
"name": "HTML Code",
"name": "HTML-Code",
"description": "HTML-, JavaScript- oder CSS-Code in den Header-Bereich des Themes oder über oder unter den Inhaltsbereich des Themes einfügen."
},
"insert-code-in-the-theme-inside-the-tag-head": "Code in den Bereich &#60;head&#62; &#60;/head&#62; des Themes einfügen.",

View File

@ -10,7 +10,7 @@ class pluginRemoteContent extends Plugin {
// Key and value for the database of the plugin
$this->dbFields = array(
'webhook'=>$randomWebhook,
'source'=>'https://github.com/bludit/remote-content-example/archive/master.zip'
'source'=>''
);
}
@ -48,7 +48,7 @@ class pluginRemoteContent extends Plugin {
$webhook = $this->getValue('webhook');
if ($this->webhook($webhook)) {
// Download files
//$this->downloadFiles();
$this->downloadFiles();
// Delete the current content
$this->deleteContent();

View File

@ -0,0 +1,7 @@
{
"plugin-data":
{
"name": "Robots",
"description": "Plugin für die Verwendung von Robots-Meta-Tags zur Suchmaschinenoptimierung (SEO) unter "Einstellungen" bei der Erstellung oder Bearbeitung von Seiten.
}
}

View File

@ -0,0 +1,7 @@
{
"plugin-data":
{
"name": "Robots",
"description": "Plugin für die Verwendung von Robots-Meta-Tags zur Suchmaschinenoptimierung (SEO) unter "Einstellungen" bei der Erstellung oder Bearbeitung von Seiten.
}
}

View File

@ -2,14 +2,34 @@
class pluginRobots extends Plugin {
public function init()
{
$this->dbFields = array(
'robotstxt'=>'User-agent: *'.PHP_EOL.'Allow: /'
);
}
public function form()
{
$html = '<div class="alert alert-primary" role="alert">';
$html .= $this->description();
$html .= '</div>';
$html .= '<div>';
$html .= '<label>'.DOMAIN.'/robots.txt</label>';
$html .= '<textarea name="robotstxt" id="jsrobotstxt">'.$this->getValue('robotstxt').'</textarea>';
$html .= '</div>';
return $html;
}
public function siteHead()
{
global $WHERE_AM_I;
global $page;
$html = PHP_EOL.'<!-- Robots plugin -->'.PHP_EOL;
if ($WHERE_AM_I=='page') {
global $page;
$robots = array();
if ($page->noindex()) {
@ -33,4 +53,14 @@ class pluginRobots extends Plugin {
return $html;
}
public function beforeAll()
{
$webhook = 'robots.txt';
if ($this->webhook($webhook)) {
header('Content-type: text/plain');
echo $this->getValue('robotstxt');
exit(0);
}
}
}

View File

@ -1,6 +1,6 @@
{
"plugin-data": {
"name": "Static Pages",
"name": "Statische Seiten",
"description": "Menü der statischen Seiten."
},
"home-link": "Hauptseite",

View File

@ -1,6 +1,6 @@
{
"plugin-data": {
"name": "Static Pages",
"name": "Statische Seiten",
"description": "Menü der statischen Seiten."
},
"home-link": "Hauptseite",

View File

@ -0,0 +1,7 @@
{
"theme-data":
{
"name": "Alternative",
"description": "Web siteleri veya bloglar için basit ve zarif bir tema. Sosyal medya ve sabit sayfalarla kenar çubuğu."
}
}

View File

@ -0,0 +1,7 @@
{
"theme-data":
{
"name": "Blog X",
"description": "Blog yazarları için tema, sağ kenar çubuğu ile birlikte. Okuma süresi, kenar çubuğunda sosyal simgeler ve sabit sayfalar."
}
}

View File

@ -521,7 +521,8 @@ function install($adminPassword, $timezone)
PATH_PLUGINS_DATABASES.'robots'.DS.'db.php',
$dataHead.json_encode(
array(
'position'=>1
'position'=>1,
'robotstxt'=>'User-agent: *'.PHP_EOL.'Allow: /'
),
JSON_PRETTY_PRINT),
LOCK_EX