TV-customization (Part 4): Add CSS-class

In Part 1 and Part 2 of this tutorial series we have learned how to replace TV cells’ values by static text or HTML content. In Part 3 we have seen that there is a problem when adding CSS-styles. For security reasons AppGini removes style attributes. This Part 4 will show you how to reach or aim, conditionally highlighting cells, anyway. Current Code Please note, the code shown below will return unexpected results, als mentioned in Part 3. Step 1: Try an alternative attribute So now we know, AppGini will remove style-attributes. But what about other attributes? Let’s quickly check …

TV-customization (Part 3): Add CSS style

In Part 1 and Part 2 of our tutorial series we have learned how to replace values of TV cells. Now I am going to add some HTML and CSS but see the security related issues. Current Code Let’s start with code from Tutorial Part 2: Step 1: Replace static text by HTML tag Now we know how to concatenate strings. Let’s replace the value by a HTML tag. This is what I want right now: <span>Built: 2019</span> So we have to concatenate several static strings <span>, Built: , then a field value year_of_manufacture, then another static string </span>. You can …

TV-customization (Part 2): More complex value replacement

In Part 1 we have replaced the values of year_of_manufacture by static text “Test”. In this Part 2 I am going to replace the values by a concatenated string, containing static string AND table data. Current Code Let’s start with code from Tutorial Part 1: Target of Part 2 I’d like to replace the database values (currenly 2019, 2020, 2021) by concatenated values like Built: 2019 etc.. This means he have to combine (concat) a static string “Built: ” (note the blank) with the values of a field. Step 1: SQL theory first Let’s check the database records first. I …

TV-customization (Part 1): Change Value

There are many requests on AppGini forum for customizing Table View columns to your own needs. Especially many of you would like to change the table-cell-style depending on certain values, for example highlight a cell in red under certain conditions. Well, there has been a change recently: AppGini now removes custom style-attributes for security reasons. In this tutorial I am going to show how to reach the goal anyway. I will start with this Part 1 where I am going to show how to just replace values. If you are interested, just search the internet for “Cross Site Scripting (XSS) …