Russian TYPO3 community Форум больше не используется. Присоединяйтесь к каналу #community-ru в Slack for TYPO3 community  

Вернуться   Russian TYPO3 community > Обсуждение общих технических вопросов > Общие вопросы

Ответ
 
Опции темы Опции просмотра
Старый 08.03.2005, 01:40   #1
Aleksandrov
Продвинутый
 
Регистрация: 04.05.2005
Сообщений: 51
По умолчанию По поводу TypoScript

Кто-нибудь, объясните толком, пожалуйста, доступными словами, для чего нужен TypoScript и насколько нужно быть программером для того, чтоб его освоить? Я только начинаю изучать TYPO3. Всем заранее спасибо!
Aleksandrov вне форума   Ответить с цитированием
Старый 08.03.2005, 09:16   #2
Gleb
Продвинутый
 
Регистрация: 10.11.2004
Адрес: Montreal
Сообщений: 92
По умолчанию

TS needs for configuration and settings.
There are \"TS by example\" and \"TS ref\" docs. Personally I do think it is better to start with TS ref and then take a look in examples. TS ref has examples with explanation as well.
The other way to go is to write an extention. It will clarify a lot (for me at least).
Here is an example how TS it is mainly used:
In your html template you have to put marker or subpart. This marker or subpart then will be replaced with some content. And the content is defined by TS.
1. Say this is a chank of your html with marker:
<hr />
<div>###MARKER_HERE###</div>
<hr />
2. Here is a chank of your TS temploate:
page.20.mark.MARKER_HERE < TEXT
page.20.marks.MARKER_HERE.value = Hey here

The result is that the marker is replaced with \"Hey here\" string. So instead of putting text you can stream output of your script and replace the marker.

If you just started with TYPO I can say from my experience do not experiment on big project. First spend some time and create simple site. It will allow you to get the point. Then thins go smoother with real project.

Have a luck








Gleb вне форума   Ответить с цитированием
Старый 08.03.2005, 18:18   #3
Valery Romanchev
Administrator
 
Аватар для Valery Romanchev
 
Регистрация: 23.08.2003
Адрес: Moscow, Russia
Сообщений: 1,926
Отправить сообщение для Valery Romanchev с помощью Skype™
По умолчанию

Помоему самая главная вещь (которую лично я не сразу понял :-)) - это то, что TS является заменой конфигурационных файлов.
Например, если посмотрите конфиг файл phpMyAdmin, то увидите задание PHP-массивов, которые собственнои и определяют конфигурацию.
Так вот, TS - это те же самые многомерные PHP-массивы, только с правилами рендернинга
(котрые сделаюы с помощью всяких там функций типа stdWrap)

Valery Romanchev вне форума   Ответить с цитированием
Старый 09.03.2005, 10:34   #4
Gleb
Продвинутый
 
Регистрация: 10.11.2004
Адрес: Montreal
Сообщений: 92
По умолчанию

I am sorry for typo in my last post. It should be
page.20.mark.MARKER_HERE = TEXT
instead of
page.20.mark.MARKER_HERE < TEXT
-----------------------------------------
Yes it is completely true what VR said. TS is just another way to define PHP array. But it is not obvious. Implicitly I comprehended it but explicitly I got it later. In other words with TS you create datastructure then TS parser translate it into PHP array. Then TYPO kernal parses it according to its own rouls. For me was hard to understand why this one more layer of complecity then when I start getting used to it I realized that it is pretty cool and neat.
Gleb вне форума   Ответить с цитированием
Ответ


Ваши права в разделе
Вы не можете создавать новые темы
Вы не можете отвечать в темах
Вы не можете прикреплять вложения
Вы не можете редактировать свои сообщения

BB code is Вкл.
Смайлы Вкл.
[IMG] код Вкл.
HTML код Выкл.

Быстрый переход


Часовой пояс GMT +4, время: 02:59.


Работает на vBulletin® версия 3.8.1.
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Перевод: zCarot

Хостинг и техническая поддержка: TYPO3 Лаборатория