Skip to content

Instantly share code, notes, and snippets.

@chriwo
chriwo / howto-release.txt
Last active May 29, 2017 07:40
How to create a version release
git fetch
git checkout -b release develop
--- Merge release into master branch
git checkout master
git pull origin master
git merge release
git push origin master
--- Merge release into develop branch
@chriwo
chriwo / index.html
Created May 23, 2017 06:09
Bootstrap 3.x column ordering
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css" integrity="sha384-BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u" crossorigin="anonymous">
</head>
@chriwo
chriwo / EmConfiguration.php
Last active January 20, 2017 19:46
Example to use the configuration options in extension manager
<?php
namespace VENDOR\YourExtKey\Domain\Model\Dto;
/**
* Class EmConfiguration
*
* @package TYPO3
* @subpackage tx_extkey
*/
class EmConfiguration
@chriwo
chriwo / FE.html
Created December 21, 2016 07:23
TCA SelectBox Value and output in FE with language file
...
<!--
jobTitle is the object property and equal with the TCA definition job_title
-->
<f:translate key="jobtitle.{jobItem.jobTitle}"/>
...
@chriwo
chriwo / ActionFrontendViewHelper
Created November 9, 2016 10:26
Uri action frontend viewhelper to generate FE links from BE, e.g. in a scheduler task
<?php
namespace ChriWo\Company\ViewHelpers\Uri;
/***************************************************************
*
* Copyright notice
*
* (c) 2016 Christian Wolfram <c.wolfram@chriwo.de>
*
* All rights reserved
@chriwo
chriwo / constants.txt
Last active August 14, 2016 18:44
Append categories to main menu
appendCategoryMenu {
# cat=appendCategoryMenu/navigation/10; type=string; label=complete string of navigation lib
menuLibary =
# cat=appendCategoryMenu/navigation/20; type=int+; label=UID of navigation point
menuPid =
# cat=appendCategoryMenu/navigation/30; type=int+; label=UID of category pages
defaultCategoryPid =
@chriwo
chriwo / FlexForm.xml
Last active August 7, 2016 14:16
Create simple timetable with gridelements
<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
<T3DataStructure>
<meta>
<langDisable>1</langDisable>
</meta>
<sheets>
<sDEF>
<ROOT>
<TCEforms>
<sheetTitle>Allgemein</sheetTitle>
@chriwo
chriwo / db_delete_records.php
Last active August 7, 2016 11:56
Deletes all records in the database that are marked as deleted.
<?php
/****************************************************
* db_delete_records.php
* Author: Christian Wolfram <c.wolfram@chriwo.de>
* Date: 12-11-2014
*
* Deletes all records in the database that
* are marked as deleted.
*
* Run from root directory of your TYPO3
@chriwo
chriwo / TCA_FAL.php
Last active November 16, 2015 12:46
Create a new FAL element in TCA. To use it, change the current field name "new_fal_image" and the table name "YOUR TABLE NAME", so that TYPO3 find your image
'columns' => array(
'new_fal_image' => array(
'exclude' => 1,
'l10n_mode' => 'mergeIfNotBlank',
'label' => 'FAL image label',
'config' => \TYPO3\CMS\Core\Utility\ExtensionManagementUtility::getFileFieldTCAConfig(
'media',
array(
'appearance' => array(
'showPossibleLocalizationRecords' => 1,
@chriwo
chriwo / realurl_conf.php
Last active June 29, 2018 07:12
RealUrl Multidomain setup with configuration for tx_news. You could copy & paste the code, but it's important to change line 4 and line 133. Replace the domain name and the PAGE_UID. In line 133 it's needed to replace the PAGE_UID with the page number of the detail news page.
<?php
$domainConfiguration = [
'www.first-domain.com' => PAGE_UID,
//'www.second-domain.com' => PAGE_UID,
//'www.third-domain.com' => PAGE_UID
];
$txRealUrlConfiguration = [
'init' => [