For coders TYPO3 Tech Corner

[PHPSTORM] Insert UNIX timestamp in PHP

[PHPSTORM] Insert UNIX timestamp in PHP

If you want to set a TypeNum in TYPO3 or if you throw an exception, a current timestamp is very helpful. And if you don't want microtime, then Groovyscript can help in a live template. In the following example you can enter "ts" and the current timestamp will be inserted at the position of the cursor. If you click "Edit variables" in Settings / Live Template, you can insert GroovyScript:

groovyScript("(int) (System.currentTimeMillis() / 1000L);")

Back

"Code faster, look at the time" - does this sound familiar to you?

How about time and respect for code quality? Working in a team? Automated tests?

Join us