This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$objectManager = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance('TYPO3\CMS\Extbase\Object\ObjectManager'); | |
$metadata = $objectManager->get('TYPO3\CMS\Core\Resource\Index\MetaDataRepository'); | |
$metadata->update($fileUid, $metadataInput[mustBeAnArray]); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# get file information with FILES Object | |
lib.dbTest = FILES | |
lib.dbTest { | |
files = 12345 | |
renderObj = TEXT | |
renderObj { | |
stdWrap.data = file:current:size | |
stdWrap.wrap = <p>File size: <strong>|</strong></p> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- just add parseFuncTSPath with no value --> | |
<f:format.html parseFuncTSPath="">{cell}</f:format.html> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$content = $this->configurationManager->getContentObject()->data; | |
$this->view->assignMultiple(array( | |
'content' => $content | |
)); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# 1. Edit mysql config | |
sudo vi /etc/mysql/mysql.conf.d/mysqld.cnf | |
# Add to [mysql] section | |
sql-mode="ERROR_FOR_DIVISION_BY_ZERO,NO_ZERO_DATE,NO_ZERO_IN_DATE,NO_AUTO_CREATE_USER" | |
# Restart mysql | |
sudo systemctl restart mysql | |
# yiehaaa |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
AuthType Basic | |
AuthName "Display Name" | |
AuthUserFile /path/to/password/file/.htpasswd | |
Require valid-user | |
Order allow,deny | |
Allow from xx.xx.xx.xx | |
satisfy any |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
rsync -avzbe ssh [email protected]:/remote/directory/path /local/directory/path |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Don't hint these as folders | |
rewrite ^/(content|site|kirby)$ /error last; | |
# block content | |
rewrite ^/content/(.*).(txt|md|mdown)$ /error last; | |
# block all files in the site and kirby folder from being accessed directly | |
rewrite ^/(site|kirby)/(.*)$ /error last; | |
# removes trailing slashes (prevents SEO duplicate content issues) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
USAGE: | |
<a onclick="alert('Google Analytics wurde deaktiviert');" href="javascript:gaOptout()">Google Analytics deaktivieren</a> | |
The Script needs to be included in all pages. | |
<script type="text/javascript"> | |
// Set to the same value as the web property used on the site | |
var gaProperty = 'UA-{GA_ID}-x'; | |
// Disable tracking if the opt-out cookie exists. |