Klaus

Add pagination to TYPO3 default File Links Content Element

 Bonn, GermanyFri, 20 Apr 2018 01:19:46 +0200 
Ever wondered how to add a Fluid paginate widget to a non Extbase extension in TYPO3 #CMS? For example a core Content Element (CE) and fluid_styled_content? It is straight forward when you are familiar with TYPO3, but there was one not quite obvious workaround needed to make it complete. The following solution is tested in TYPO3 v9.1 and v9.2, but it is possible that there will be another solution in core in the future.

I have a TYPO3 default File Links [uploads] Content Element (CE) and wanted to output a collection from a folder with a lot of files. I was surprised, that there was no pagination available, but it is a fluid styled template, so it was easy to add a paginate widget.

Add a template override path to your Template constants:
# Add Fluid Styled Content template override path
styles.templates.templateRootPath = EXT:myext/Resources/Private/ContentTemplates/


Add to your ext Template setup following TypoScript to set an alternative template name for File Links CE. Also add a workaround for non-extbase elements like the File Links CE [uploads]. This is needed so that the Fluid paginate ViewHelper will also work. Otherwise you have pagination, but only results from the first page are shown, because no controller is executed.
##
# Customised TYPO3's File Links Content Element with pagination template.
#
# CType: uploads

# Use a customised fluid styled content template
tt_content.uploads.templateName = MyFilePagination

# Workaround to add functionality for non-extbase elements (https://forge.typo3.org/issues/79430)
tt_content.uploads.extbase {
    pluginName = filelist
    controllerName = filelist
    controllerExtensionName = myext
    controllerActionName = show
}


You can take the default template from typo3/sysext/fluid_styled_content/Resources/Private/Templates/Uploads.html and save it at typo3conf/ext/myext/Resources/Private/ContentTemplates/MyFilePagination.html. In your customised template add the Fluid paginate widget ViewHelper around the for ViewHelper and change the variable according:
<f:widget.paginate objects="{files}" as="paginatedFiles" configuration="{itemsPerPage: 10, insertAbove: 1, insertBelow: 1, maximumNumberOfLinks: 10}">
  <f:for each="{paginatedFiles}" as="file" iteration="fileIterator">


That's it. ;-)
Klaus

Drupal webform mail template override

 Wed, 18 Apr 2018 13:32:49 +0200 
The default #Drupal swiftmailer mail template override works something like this:
swiftmailer--[mymodule]--[mykey].html.twig

I was struggling how to configure a module which actually needed more than just module--key identifiers. For example when you have several Drupal webforms or even several handlers for one webform. It was not directly obvious how to access each handler, but actually it is quite simple:
swiftmailer--webform--[webform-node-id].html.twig
swiftmailer--webform--[webform-node-id]-[handler-id].html.twig


#CMS
Klaus

TYPO3 v9.2

 Wed, 11 Apr 2018 01:00:21 +0200 
Was fighting with Drupal8 half of my work day just to get stupid alternative mail templates for webform handlers with swiftmailer in production. And then in the evening I updated a private project to the new TYPO3 9.2 release and it was such a relief. ;-)

#^typo3-v920-released
Image/photo
Off to go Site-Seeing!
Packed with awesome features and perfectly on time, we released a new version of TYPO3 v9.
Klaus
 Thu, 22 Mar 2018 23:37:44 +0100 
The more I have to work with Drupal the less I understand people complaining about TYPO3. Fascinating how quick you get used to such pre security advisories. ;-)

#^Drupal 7 and 8 core highly critical release on March 28th, 2018 PSA-2018-001
Advisory ID: DRUPAL-PSA-2018-001
Project: Drupal Core
Version: 7.x, 8.x
Date: 2018-March-21

There will be a security release of Drupal 7.x, 8.3.x, 8.4.x, and 8.5.x on March 28th 2018 between 18:00 - 19:30 UTC, one week from the publication of this document, that will fix a highly critical security vulnerability. The Drupal Security Team urges you to reserve time for core updates at that time because exploits might be developed within hours or days.
Klaus

Digital Experience

 Wed, 07 Feb 2018 01:00:27 +0100 
creepy. Eine ziemlich einseitige und komische Argumentationslinie. Klar finde ich das aus technischer Sicht auch sehr spannend und hilfreich, aber als Besucher einer solch überwachten Application sträuben sich mir alle Haare.

#^Application Performance Management: Vom Nice-to-have zum Must-have
Image/photo

Kontextbezogenes Monitoring, Log- und Fehleranalyse mit KI-Unterstützung sowie die User Experience standen im Fokus der diesjährigen Perform-Konferenz des APM-Spezialisten Dynatrace.
Klaus

Selenoid

 Thu, 18 Jan 2018 18:52:14 +0100 
I already had a dockerized Selenium-Grid but it was a good idea to replace it with Selenoid. The state of automation and the video recording feature are really impressive.

#^Selenoid
Selenoid is a powerful implementation of Selenium hub using Docker containers to launch browsers.

Lightweight and Lightning Fast
Suitable for personal usage and in big clusters:
* Consumes 10 times less memory than Java-based Selenium server under the same load
* Small 7 Mb binary with no external dependencies (no need to install Java)
* Browser consumption API working out of the box
* Ability to send browser logs to centralized log storage (e.g. to the ELK-stack)
* Fully isolated and reproducible environment



#^Scalable Selenium Cluster: Up & Running | Ivan Krutov
by seleniumconf on YouTube
Klaus

3-Faltigkeit

 Tue, 10 Oct 2017 15:18:24 +0200 
#^Zahlen, bitte! Die 3-Faltigkeit der Cascading Style Sheets
Image/photo

Der Siegeszug der Cascading Style Sheets für Webseiten begann vor 23 Jahren. Heute ist CSS aus dem Web nicht mehr wegzudenken. Wie CSS entstand und was die Zahl 3 für eine Rolle spielt:
Heute vor 23 Jahren stellte der norwegische Computerwissenschaftler Håkon Wium Lie, ein Kollege des HTML-Erfinders Tim Berners-Lee, den ersten Entwurf einer Sprache namens "Cascading HTML Style Sheets" vor. Das "HTML" fiel – ebenso wie einige der kühneren Ideen des Konzepts – bald weg, und als "CSS" eroberte die Sprache bald die Bildschirme der Welt.
Klaus

under pressure

 Fri, 04 Aug 2017 19:01:05 +0200 
Technically interesting website.
The stories are a bit strange, but the results at the end are quite interesting.

#^Climate under pressure - Home
Image/photo

An interactive documentary experience giving you control over the climate stories and destinies of 6 individuals around the world.
Klaus

background-clip:text

 Wed, 02 Aug 2017 23:04:19 +0200 
I really like the experimental background-clip:text;. Such a nice effect!

#^background-clip
The background-clip CSS property specifies whether an element's background, whether a color or an image, extends underneath its border.
Klaus

inclusive design

 Wed, 02 Aug 2017 13:32:47 +0200 
#^Inclusive Components
A blog trying to be a pattern library. All about designing inclusive web interfaces, piece by piece.

What is inclusive-components.design?
A blog trying to be a pattern library, with a focus on inclusive design. Each post explores a common interface component and comes up with a better, more robust and accessible version of it.

Why?
Because the web is full of interfaces which don't consider the diversity of abilities, circumstances, and preferences of their users.

What do you mean by component?
A module, a part of your interface, an entry in your pattern library. A bit of what you make as a designer and developer.
Klaus

CSS Grid Layout Module

 Mon, 03 Apr 2017 00:54:55 +0200 
Falls jemand einen Grund sucht sich die iX zu kaufen. ;-)

#^Hinter Gittern
Seit den Frühzeiten des Web wollen Designer Elemente in Zeilen und Spalten positionieren. Bis vor Kurzem mussten sie dafür Umwege über Tabellen oder umfließende Inhalte gehen. Mit neuen CSS-Attributen können sie gitterartige Layouts komfortabel aufbauen.
Klaus

Danaergeschenk

 Fri, 17 Mar 2017 13:27:25 +0100 
Schon ziemlich krank dieses AMP und was mit den ganzen Erweiterungen dafür noch geplant ist. Obwohl ich auch leider aus eigener Erfahrung feststellen muss, dass es doch einen ziemlichen Unterschied macht, ob man 1-2 Minuten wartet bis man etwas lesen kann, oder 5-10 Sekunden. :-/ Obwohl ich mit meinem Internetzugang auch eher die Ausnahme bin, als Googles eigentliche Absicht die sie damit bezwecken.

#^Kommentar zu Google AMP: Der goldene Käfig
Image/photo

AMP macht Websites schneller – aber es verstärkt zugleich die Abhängigkeit von Google in gefährlichem Maß, findet Herbert Braun.
Klaus

Thou Shalt Not Depend on Me

 Mon, 13 Mar 2017 13:12:14 +0100 
#^Thou Shalt Not Depend on Me: Analysing the Use of Outdated JavaScript Libraries on the Web
Web developers routinely rely on third-party JavaScript libraries such as jQuery to enhance the functionality of their sites. However, if not  properly maintained, such dependencies can create attack vectors allowing a site to be compromised.

In this paper, we conduct the first comprehensive study of client-side JavaScript library usage and the resulting security implications across the Web. Using data from over 133k websites, we show  that 37% of them include at least one library with a known vulnerability; the time lag behind the newest release of a library is measured in the order of years. In order to better understand why websites use so many vulnerable or outdated libraries, we track causal inclusion relationships and quantify different scenarios. We observe sites including libraries in ad hoc and often transitive ways, which can lead to different versions of the same library being loaded into the same document at the same time. Furthermore, we find that libraries included transitively, or via ad and tracking code, are more likely to be vulnerable. This demonstrates that not only website administrators, but also the dynamic architecture and developers of third-party services are to blame for the Web’s poor state of library management.

The results of our work underline the need for more thorough approaches to dependency management, code maintenance and third-party code inclusion on the Web.
Klaus

Brutalist

 Wed, 08 Mar 2017 22:10:19 +0100 
Damn, if I have to choose between flat design and brutalist I would choose the latter one.

#^Brutalist Framework
Image/photo
A simple framework for the brutalist web design trend.
Klaus

Task Times

 Fri, 03 Mar 2017 16:05:21 +0100 
Measuring Task Times without Users
A key aspect of usability is efficiency. Users should be able to complete tasks quickly.

Efficiency is usually measured as time on task, one of the quintessential usability metrics.

For transactional tasks done repeatedly, shaving a couple seconds off a time can mean saving minutes per day and hours per week for users (think Accounting, Contact Management and Order Entry).

It can also mean saving all of us a lot of time (how many web-forms do you fill out a day?).
Klaus

TYPO3 v8.5

 Wed, 21 Dec 2016 10:39:11 +0100 
The new forms framework makes a great impression. Not so sure about the new RTE (CKEditor). No question the old one (htmlArea) was a beast and terrible to configure, but when you once had a right configuration, it was very powerful. We will see how much effort it will be to customize the new editor.

#^TYPO3 v8.5 released
Christmas came early this year - TYPO3 v8.5 has been released just now, including some very exciting and promising changes. This so-called sprint release is one further step towards TYPO3 8 LTS, scheduled to be published in April 2017.
Klaus
 Fri, 09 Dec 2016 15:13:04 +0100 
#^HTML5 Mega-Spickzettel
Unten finden Sie eine komplette Liste mit allen HTML5 Tags / Elementen inklusive Beschreibung wofür sie verwendet werden

#CheatSheet
Klaus

EXT:mask

 Mon, 05 Dec 2016 16:56:07 +0100 
Custom Content Elements made easy – EXT:mask
„Mask“ is a TYPO3 extension which makes it really easy to create custom content elements and enrich backend layouts. This post is about the motivation, the howto and the differences to other “templating“ solutions. I am convinced that this extension will solve most of your requirements for individual content elements.
Klaus

Nagios check with PhantomJS

 Tue, 29 Nov 2016 17:47:18 +0100 
#^hggh/phantomjs-nagios
phantomjs-nagios - Nagios check with PhantomJS. Render an complete Webpage headless and test load time with nagios

Icinga performance data
    load_time: load time of complete website in ms
    size: complete size of all downloaded files in byte
    requests: count of files (css,js,html,...)
    dom_elements: count of all DOM elements on the site
    load_time_initial_req: the load time of the first request
Klaus

Misrepresentation?

 Fri, 25 Nov 2016 19:18:31 +0100 
I saw today screenshots of a website with annotations made by Google AdWords Support Team how to change a website to confirm with their advertising policies. Companies who rely on AdWords and Google traffic are really fucked. You change your site to their will or you are out.
Feels a bit like Amazon. When the products you sell on Amazon platform get a bit too successful Amazon claims the product for themselves and denies every other company to sell it on their platform.
So much power and no one who controls it. #don't be evil unless it is profitable :rofl

#^Misrepresentation - Advertising Policies Help
We don't want users to feel misled by ads that we deliver, and that means being upfront, honest, and providing them with the information that they need to make informed decisions. For this reason, we don't allow the following:
* promotions that prompt users to initiate a purchase, download, or other commitment without first providing all relevant information and obtaining the user's explicit consent
* promotions that represent you, your products, or your services in a way that is not accurate, realistic, and truthful
Below are some examples of what to avoid in your ads.