Skip to content

Instantly share code, notes, and snippets.

View sorenmalling's full-sized avatar

Søren Malling sorenmalling

View GitHub Profile
@tolleiv
tolleiv / .gitconfig
Last active December 15, 2015 08:19
My .gitconfig
[user]
name = Tolleiv Nietsch
email = tolleiv.nietsch@typo3.org
[alias]
st = status
ci = commit
br = branch
co = checkout
df = diff
lg = log -p
anonymous
anonymous / Cache
Created January 22, 2014 10:31
Cache
/**
* @var \TYPO3\Flow\Cache\Frontend\StringFrontend
*/
protected $cache;
/**
* @param \TYPO3\Flow\Cache\CacheManager $cacheManager
*/
public function injectCache(\TYPO3\Flow\Cache\CacheManager $cacheManager) {
$this->cache = $cacheManager->getCache('YOUR_CACHE_IDENTIFIER');
@xperseguers
xperseguers / controller.php
Last active April 4, 2023 07:56
Upload files in TYPO3 from Frontend
/**
* Upload files.
*
* @return void
*/
public function uploadAction() {
$overwriteExistingFiles = TRUE;
$data = array();
$namespace = key($_FILES);
@bwaidelich
bwaidelich / Menu.html
Last active April 13, 2017 12:28
A DTO that can be used to create simple menus in a TYPO3 Flow application
<ul class="nav">
<f:for each="{menu.menuItems}" as="menuItem">
<f:render section="menuItem" arguments="{menuItem: menuItem}" />
</f:for>
</ul>
<f:section name="menuItem">
<f:if condition="{menuItem.header}">
<f:then>
<li class="nav-header">{menuItem.label}</li>
@smichaelsen
smichaelsen / ObjectStorageService.php
Created December 10, 2015 15:16
ObjectStorageService that groups your objects by property (PHP 5.5 required)
<?php
namespace Smichaelsen\Gist\Service;
use TYPO3\CMS\Extbase\Persistence\ObjectStorage;
use TYPO3\CMS\Extbase\Reflection\ObjectAccess;
class ObjectStorageService
{
/**
@helhum
helhum / install.sh
Last active January 10, 2023 15:38
Unattended TYPO3 7LTS installation (including introduction package)
composer create-project typo3/cms-base-distribution='^7.6.0' my-test-typo3 --no-interaction
cd my-test-typo3/
composer require helhum/typo3-console
# This will only work with PHP < 7 as realurl need PHP 5.x
composer require typo3-ter/introduction
cp web/typo3conf/ext/typo3_console/Scripts/typo3cms .
cp web/typo3conf/ext/bootstrap_package/Configuration/Apache/.htaccess web/
chmod +x typo3cms
./typo3cms install:setup --non-interactive --database-user-name="root" --database-user-password="root" --database-host-name="localhost" --database-port="3306" --database-name="t3_my_test" --admin-user-name="admin" --admin-password="password" --site-name="Auto Install"
./typo3cms database:updateschema '*.*'
@NeoBlack
NeoBlack / TYPO3-Upgrade
Created February 26, 2016 09:43
TYPO3 Upgrade from 4.5.x to 6.2.x
01) Update to latest 4.5 version
02) DB-Compare via install tool
03) Update extensions to 6.2 compatible version
04) deinstall unused extensions
05) delete deinstalled extensions
06) Repair failures reported bei EXT:smoothmigration
07) Update sys_refindex [1]
08) Update TYPO3 core to 6.2 (maybe restart webserver, APC?)
09) Run Upgrade Wizard from install tool
10) DB-Compare via install tool