Friday, June 27, 2008

Hands Or Foots Baby Tattoo

View Magnifier for enlarging images (click enlarge) through

Hello!
So, there is again a new TypoScript Hack by me. This time the problem was
following: Customer wanted a picture on his website that is magnified when you click on it. By default, yes really a problem.
now but will be displayed under the picture a small magnifying glass that does when you click on the same - that is, increase the actual image. In addition to the motion will then be the Bildcaption.

solution:
 tt_content.image.30 < tt_content.image.20
tt_content.image.30
1.stdWrap {{
HTMLparser = 1 = 1
HTMLparser.tags.a
HTMLparser.tags.img.fixAttrib.src.set = fileadmin / template / icons / zoom_in.jpg
HTMLparser.tags.img.fixAttrib.width.set = 40 = 40
HTMLparser.tags.img.fixAttrib.height.set

if {
value.field = image_zoom
equals = 1}

}}

tt_content. {{image.20
caption.1.stdWrap.if
value.field = image_zoom
equals = 1
negate = 1}

}


you actually have to adjust only the rows 6, 7 and 8 The path to your "magnifying glass" has to be right, logically, and the width or height and, as this may inflate the magnifying glass to the size of the original image. This was
's it for now. Thus the motion displayed only if the checkbox "Click enlarge" clicked - the caption is moved only in this case in the Lupenbox.

Wednesday, March 12, 2008

Appropriate South Park

Rootlevel until it finds a value

Sooo, now has a relatively long time since I've written again what.
is today's question that will be issued on one side of the alias of the current page. If this is not set, the alias is to the next higher page output. Is not set, the next higher, etc., etc. The

is relatively simple. With the following you can
Typoscript do just that:

 temp.showAlias = TEXT 
temp.showAlias.data field level = -1, alias, slide


The "data" property of stdWrap is of type "getText". Here you will find your a more detailed description.

Wednesday, May 2, 2007

Sterilizing For Pregnant Dogs

RTE (HTMLArea): paragraph and text selection define

So, after a long time writing another entry ...
I have once again engaged in a Typo3 problem and found a solution ;-).
Problem: Customer wants to highlight the RTE text and make it turn red. The just use the Color Picker, but her knows that: Once you give the general editor, more options than necessary, everyone must obviously be a mess out somehow somewhere in the website. As a developer, you get gray hairs over relatively quickly, as it probably even six months gehießen even before "The page must correspond exactly to our Style Guide!" has and it is for the A * sch has opened ... well, for the solution ...
TSConfig In your Page must be in the pure:
 
RTE.config.tt_content.bodytext
proc.allowedClasses = {} redtext

RTE.default
{# just to be sure that all fields are #
da .. .
showButtons = *
}
RTE {
classes {
redtext {
name = Red
value = color: # AA0000;
}
important {
name = Important
value = color: # 00FF00;
}
} default
{
classesCharacter = = Redtext
classesParagraph important
contentCSS = fileadmin / _system / rte.css
}}


So now created her a CSS file with the abstract names rte.css.
In the states the following:
 
span.redtext
{color: # AA0000;}


p.important
{color: # 00FF00;}


Download the file in the directory files / _system (or wherever However - you must then just adjust the path above).
Flushes all caches have on the safety time and already you should select the part of the text in your text drop-down list, select \u0026lt;Rot> . Your clicks into a Paragraph, should see \u0026lt;Wichtig> .

The really was all in all, nothing heavy, but can still eat time.

Tuesday, January 16, 2007

Hyundai Camera Driver

Custom character sets in the backend

So after I've spent a good five hours to find out why the website of a customer shot so Sun has been shown (only in Japanese language version), you get the solution of quasi served on a silver platter.
First off my problem description: Our client supplied
Japanese texts (web site exists in German [Standard], English and Chinese [Simplified]). After our intern entered the majority of Japanese texts is then had noticed that for some sign of HTML code will be destroyed.
have for eternal back and forth, I then found that the Japanese character ( csh_jp [yes, the TYPO3 version is not 4.0]) set for the Japanese language pack with shift_jis not compatible with the customer-supplied Word documents was (who were in the character set euc-jp encoded ).
Now one could argue, "Why did not you forceCharset in the Install Tool to set UTF-8 Then the problem would not exist ...?"
My answer: "Sure - absolutely thoughtful response, but no one was so real keen on the customer his German texts explain why all must be entered again. And ... oh yeah I had mentioned - since even a Chinese version was ... "
Conclusion: We have to somehow convert the BE in euc-jp (yes the VU is relatively simple to switch)

The bad news first. except forceCharset the encoding in the backend can not override
Now the good. too hard it still is not - if you know where you even need ...

solution:

You open the file typo3 . / t3lib/class.t3lib_cs.php
approximately in line 356 is the following code:
 var $ lang_to_charset_unix = array (
'west_european' => 'iso-8859-1',
'estonian' => 'iso-8859-1',
[...]
'chinese' => 'gb2312' / / = euc-cn
'japanese' => 'euc-jp '
'korean' => 'euc-kr',
[...]
);

The next array is the same for Windows, just that there is a charset for Japanese shift_jis . This has to be euc-jp be replaced. Last you need in the next array ($ charSetArray ), ticker jp euc-jp also be registered. Now you have to
only upload the file and voila - your back shines with new coding.

Oh, and for front-end's in your TypoScript template you must insert the following line:
 config.renderCharset = euc-jp 

I hope you saved a lot of time.