Skip to content

Instantly share code, notes, and snippets.

View georgringer's full-sized avatar

Georg Ringer georgringer

View GitHub Profile
SELECT table_name AS Tables,
round(((data_length + index_length) / 1024 / 1024), 2) AS SizeInMB
FROM information_schema.TABLES
WHERE table_schema = "DBNAME" ORDER BY SizeInMB DESC;
@georgringer
georgringer / Command
Last active August 29, 2015 14:14
Command to migrate the import_id of tx_news_domain_model_news to the uid
<?php
namespace GeorgRinger\Theme\Command;
use TYPO3\CMS\Core\Utility\GeneralUtility;
class UpdateCommandController extends \TYPO3\CMS\Extbase\Mvc\Controller\CommandController {
/**
* Change all news ids to the old ones
<?php
namespace GeorgRinger\News\ViewHelpers;
/**
* This file is part of the TYPO3 CMS project.
*
* It is free software; you can redistribute it and/or modify it under
* the terms of the GNU General Public License, either version 2
* of the License, or any later version.
<?php
namespace BeechIt\NewsTtnewsimport\Service\Migrate;
use TYPO3\CMS\Core\Utility\ExtensionManagementUtility;
use TYPO3\CMS\Core\Utility\GeneralUtility;
class TtNewsPluginMigrate {
/** @var \TYPO3\CMS\Core\Log\Logger */
protected $logger;
@georgringer
georgringer / Gridelements Configuration
Last active August 7, 2020 09:07
TYPO3 Gridelements, configuration by files without any database involvement
# Page TSConfig:
tx_gridelements.setup {
# Identifier
2col {
title = 2 Spalten
config {
colCount = 2
rowCount = 1
rows {
1 {
@georgringer
georgringer / Configuration.ts
Created January 23, 2017 18:48
Persist a TYPO3 powermail form including a sys_file_reference
plugin.tx_powermail.settings.setup {
finishers {
89 {
class = GeorgRinger\Example\Hooks\Frontend\SaveFinisher
config {
# location in fileadmin
path = formuploads/
# pid to save
@georgringer
georgringer / News-List.html
Last active May 1, 2019 11:06
Example of an EXT:news templateLayout to support the SliderPro of bqworks
<html xmlns:f="http://typo3.org/ns/TYPO3/CMS/Fluid/ViewHelpers"
xmlns:n="http://typo3.org/ns/GeorgRinger/News/ViewHelpers"
data-namespace-typo3-fluid="true">
<f:layout name="General"/>
<!--
=====================
Templates/News/List.html
-->
<f:section name="content">
@georgringer
georgringer / html
Last active April 13, 2017 14:10
Render news with same tags, using VHS+news
{f:render(section:'tagIds',arguments:_all) -> f:spaceless() -> v:variable.set(name: 'tagIds')}
<f:if condition="{tagIds} != ''">
<h4>
<f:translate extensionName="theme" key="news.related-news"/>
</h4>
<f:cObject typoscriptObjectPath="lib.tx_news.relatedByTags" data="{pid:newsItem.pid,tags:tagIds,actualNewsUid:newsItem.uid}"/>
</f:if>
<f:section name="tagIds">
@georgringer
georgringer / sysext_dependencies.md
Created July 25, 2018 19:56
Dependenies (or suggestions) from one sysext to another one

about

  • Backend
  • Core

adminpanel

@georgringer
georgringer / ConfigurationReader.php
Last active November 23, 2018 11:54
XCLASS of EXT:realurl to avoid issues with FB parameter fbclid
<?php declare(strict_types=1);
// in your sitepackage Classes/Xclass/Realurl/ConfigurationReader.php
namespace Vendor\SitePackage\Xclass\Realurl;
class ConfigurationReader extends \DmitryDulepov\Realurl\Configuration\ConfigurationReader {
protected $defaultValues = array(
'cache/banUrlsRegExp' => '/tx_solr|tx_indexedsearch|tx_kesearch|(?:^|\?|&)q=/',