stopBefore(document, 'getElementById')
stopBefore('document.getElementById') // the same as the previous
stopBefore(Element.prototype, 'removeChild')
This file contains 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
## If the user has a browser with german language | |
## and visits the root page | |
## than redirect to the german default startpage: http://www.HOST.com/de/produkte.html | |
RewriteCond %{HTTP:Accept-Language} ^de.*$ [NC] | |
RewriteRule ^$ http://%{HTTP_HOST}/de/produkte.html [L,R=302] | |
## If the user has a browser with a non german language | |
## and visits the root page | |
## than redirect to the english default startpage: http://www.HOST.com/en/products.html | |
RewriteCond %{HTTP:Accept-Language} !^de.*$ [NC] |
This file contains 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 do any further rewrite for following file types (404 optimization) | |
RewriteRule \.(css|js|png|jpg|jpeg|gif|ico|ttf|otf|svg|eot|woff|avi|mov|mp4|wmf|pdf|doc|docx|xls|xlsx)$ - [NC,L] |
This file contains 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
for file in $(ls deployment_bosch-intranet_production*); do | |
sed -i 's/production/staging/g' ${file}; | |
mv ${file} ${file/production/staging}; | |
done |
This file contains 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
git clone --mirror git://git.typo3.org/Packages/TYPO3.CMS.git | |
git remote add github git@github.com:michaelklapper/TYPO3.CMS.git | |
git push git@github.com:michaelklapper/TYPO3.CMS.git | |
git remote update | |
git push git@github.com:michaelklapper/TYPO3.CMS.git | |
git checkout -b morphodo/TYPO3_4-7/4-7-12 TYPO3_4-7-12 | |
// add changes | |
git push origin morphodo/TYPO3_4-7/4-7-12 |
This file contains 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
$classes = array_filter(get_declared_classes(), function($class){ | |
return get_parent_class($class) === 'Morphodo\Environment\Settings\Handler\AbstractHandler'; | |
}); |
This file contains 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
ssh -R 9000:127.0.0.1:9000 user@yourserver.tdl |
This file contains 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
curl http://localhost:8095/solr/test/update --data-binary '<add><doc><field name="id">1</field><field name="type">website</field><field name="appKey">indexer</field><field name="title">My product</field><field name="price_mz_f">49.99</field><field name="price_fr_f">43.99</field><field name="price_st_f">23.99</field></doc></add>' -H 'Content-type:text/xml; charset=utf-8' |
This file contains 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
export XDEBUG_CONFIG="idekey=PHPSTORM remote_port=9000" | |
export SERVER_NAME=sandbox |