Can i add more colors in tx_gridelements - typo3

i want to add more backend colors in Typo3 Gridelements.
Under Typo3 -> List -> CE Backend Layout is an Option "Frame" with 4 colors and i want to add more colors.
Is there a way for it?
Best Regards

You probably want to use something like this in your pageTS:
TCEFORM.tx_gridelements_backend_layout{
frame{
addItems{
10 = unicorn-pink
}
}
}
You can change every field from every table with this method.
See https://docs.typo3.org/typo3cms/TSconfigReference/PageTsconfig/TCEform/Index.html for further information about this.

Just adding the value in TCEFORM might not be enough, since you will need to add CSS to get the colors assigned to those new classes.
So you will at least need to have a small extension providing the items, a basic folder structure as in the usual sitepackages and the CSS embedded via ext_tables.php and/or ext_localconf.php

Related

Changing Name in Link Browser Typo3

The Names I wanna change
How do I change the Names of the marked Menus?
probably with different labels instead of using always the same:
label = LLL:EXT:my_extension/Resources/Private/Language/Backend.xlf:browse_links.press

HTML5 Custom Data Attributes in TYPO3 Backend Content Elements

I am wondering if there is a way to add a HTML5 Custom Data Attribute to any Content Element like Text or Text w/ images.
Anyone tried / did this before or is there a good reason not to do this?
You can either add a new field (own extension) or use any of the existing (e.g. layout to define own values. Then you can change the TypoScript rendering based on the value of this field.
... or in addition to #pgampe's answer, which is fine for programmers you can use ie. DCE extension, which allows you to create any HTML structure with usage pure Fluid syntax
Thank's for the answers. I didn't know DCE, looks very interesting.
As I needed a quick solution for just a few elements on one page I did something really quick and dirty. But as it worked for me, I would like to post it in addition to the two other excellent answers.
I used the field Description field to add the content of my custom field. I know it's not intended for this, but as alreay mentioned: quick & dirty. :-)
tt_content.stdWrap.innerWrap.cObject {
50 =< tt_content.stdWrap.innerWrap.cObject.default
50.20.10.value = csc-default layout-{field:layout}" data-filter="{field:rowDescription}
50.20.10.insertData = 1
}

Element Checkbox got its label always to the left and needs a link

How can I change the positions of checkbox and label and how to implement a link into the label?
$acceptGTC = new Element\Checkbox('AGBs');
$acceptGTC->setLabel('I Accept the GTC (show it).');
$this->add($acceptGTC);
regards
n00n
meanwhile:
I tried to overwrite the view helper for checkboxes.
copied
*/vendor/zendframework/zend-form/src/View/Helper/FormCheckbox.php
to
*/module/Application/src/Application/View/Helper/FormCheckbox.php
added to module.config.php
'viewhelpers' => array('checkbox'=>'Application\View\Helper'),
But it still uses the original one...
Do I have to tell zend to use my FormCheckbox?
I don't exactly know the way you are rendering your Zend_Form_Element, but in order to enhance the rendering as you want you should build a custom decorator, and add it to this element.
You should read the Zend documentation on Zend_Form_Decorators, everything is quite well explained and should lead you to a fancy solution.

Typo3: classes for elements

I have 3 different kinds of in my website, and I want to give be able to give different classes from the backend using the RTE from the Text Element. It should look like this:
<ul class="type2">
....
</ul`>
I thought I should use one of the 3 boxes from the RTE, probably "blockstyle", but im not sure how to add new options to this dropdow. Can someone please help me? Thanks!
The standard RTE editor (rtehtmlarea) populates the class list by parsing the CSS file that you set for it so all you need to do is to define ul.type2 in that CSS file. See the manual of the extension and search for contentCSS property. Example:
RTE.default.contentCSS = fileadmin/template/rte.css
Note that you might have to set it also for each table, e.g.:
RTE.config.tt_content.bodytext.contentCSS = fileadmin/template/rte.css
This depends on your configuration and whether you already have default settings (RTE.default) copied into other configurations. See Info -> [page] -> Page TSconfig -> RTE. for your current settings.

How to fusion two content elements? / Does an all in one content element exist?

I need a content element that cointains apsects from the "Textpic" and the "Media" content elements.
Basically I need the whole palette of input masks of the textpic CE (headline, rte text, images) plus the media tab (swf, mp4, mov) from the media content element.
This special requirements for our project comes from the need that we can only use one content element for our specific javascript content slieder. So I can not use like a Textpic and underneath a media CE. No it really has to be just one CE which can handle the textpic + the media CE stuff.
Generally I ask you: Is there already a extension, trick, modification or a framework which I can/should be use to achive that i can "fusionate" content elements? Like an "all-in-one"-content element, a multi content element?
Ps: I do not use Templavoila. My Typo3 version is 4.5
I think this is the tutorial you're looking for:
http://castironcoding.com/resources/our-blog/sp/view/single/post/reason-6-for-choosing-typo3-custom-content-elements-and-extbase-again-part-23.html
Follow step 2 and 3.
You'll also need to add a specific rendering config in Typoscript ie: tt_content._your-ce_
But it can be copied from out of tt_content.textpic and tt_content.media. You can find the expample typoscript of before mentioned CE's in: typo3/sysext/css_styled_content/static/setup.txt. Just don't alter it there, but make a copy and alter in your own file.
As you seem to only talk about reusing already exisiting fields, you really only need to change the backend interface (big keyword: "showitem"). You'll need the database names of the fields (peek into the tt_content table of some records where you know the contents), alternatively visit the module Admin Tools / Configuration, select TCA in top dropdown menu, open tt_content and columns.
Try http://blog.chandanweb.com/typo3/adding-new-fields-to-existing-typo3-tables-at-desired-location, you'll of course have to substitue tt_content for tt_news etc.
You might also want to make a new type (the above recipe is for changing a preexisitent), but I'm sorry, I'm currently out of time for explaining that. It's not very hard, though, and the castiron link by Koopa will help you on your way.
Perhaps you can wrap the content column in another div? You can use that outer div for your content slider. Now you actually use all content elements seperately, but combine then for usage.