Обычные (простые, одностраничные) компоненты создают какую-либо область на одной конкретной странице. Например, компонент показа новости по ее коду создает на одной конкретной странице (той, где он размещен) область, в которой показывает заголовок, текст и прочие параметры новости.
Комплексные (сложные, многостраничные) компоненты - это компоненты, которые создают разделы сайта. Например, компонент каталога создает на сайте весь раздел каталога: и список каталогов, и список групп, и страницы товаров. То есть комплексный компонент состоит из набора страниц. Комплексные компоненты строятся на основе обычных компонентов.
MVC
Комплексные компоненты построены на паттерне проектирования MVC (Model View Controller), в котором модель данных приложения, пользовательский интерфейс и управляющая логика разделены на три отдельных части, так, что модификация одной из частей оказывает минимальное воздействие на другие части.
Model (модель) в данном случае - это ядро системы. Model представляет собой данные и бизнес-логику, отвечает на запросы View. View (представление) - это простые компоненты (на самом деле все чуть сложнее, но для начала можно понимать именно так). View представляет вывод данных пользователю, запрашивает данные у Model, посылает действия пользователя в Controller (как правило через HTTP запрос). Controller (контроллер) - это комплексный компонент. Controller на основании действий пользователя и ответа Model выбирает соответствующий View.
Алгоритм работы паттерна MVC примерно таков: на основании действий пользователя Controller (контроллер) определяет, какое View (представление) должно быть показано пользователю, и отдает управление этому View (представлению); View (представление) запрашивает необходимые ему данные у Model (модели), получает эти данные и выводит их соответствующим образом пользователю; пользователь с помощью каких-либо элементов управления, которые ему предоставил View (представление), посылает новый запрос в Controller (контроллер).
Алгоритм работы паттерна MVC в применении к комплексным компонентам таков: на основании действий пользователя (как правило HTTP запрос) комплексный компонент (controller) определяет, какая страница (view) должна быть показана пользователю, и подключает свой шаблон компонента для этой страницы; шаблон страницы (view) подключает обычные компоненты, настраивая необходимым образом их свойства; обычные компоненты выполняют свою работу: запрашивают данные у ядра (model), форматируют их и выводят посетителю, а так же предоставляют пользователю различные элементы управления (ссылки, формы, кнопки и т.п.); пользователь с помощью каких-либо элементов управления, посылает новый запрос (как правило HTTP запрос) комплексному компоненту (controller).
Страница
1 - 1 из 2
Начало | Пред. |
12
|
След. |
Конец
Количество показов: 6831
Автор:
Алексей Кирсанов
Рейтинг:
3.3
[TR] [TD]http://www.business401k.us[/TD] [TD]Running a business can be one of the most rewarding and satisfying ventures one can partake in life. However, running a business can also be an extremely demanding, and at times, stressful career move. Luckily there are a wide range of business services that can help to take some of the weight off of your shoulders and allow you to focus on the core elements of your business.[/TD] [/TR]
[TR] [TD]http://www.diyhomeimprovement.us[/TD] [TD]How does one gauge the success of a do it yourself home improvement project? What level of expectations should we have upon their completion? For a good many people, evaluation of a DIY home improvement project is out of the question. There is a general misconception that once a DIY project is done, it's done. No need to further evaluate whether the project was really a success or not.[/TD] [/TR]
[TR] [TD]http://www.healthandglow.us[/TD] [TD]How to keep healthy and glowing skin throughout your life? There are some secrets to how to do it, and they include both habits and the use of some excellent skin products.[/TD] [/TR]
[TR] [TD]http://www.travelup.us[/TD] [TD]There is so much information available on the internet right now regarding travel. There are online travel sites for cruises, hotels, air, trains and any other type of travel. But what is the correct product for you?[/TD] [/TR]
[TR] [TD]http://www.thefashionstyles.us[/TD] [TD]For the best answers on choosing the right fashion styles follow these guidelines and you won't for wrong. Read on to learn more.[/TD] [/TR]
[TR] [TD]http://www.financeplanner.us[/TD] [TD]Starting a career in financial planning will take a lot of hard work and dedication to be successful. A financial planner specializes in the planning aspect of finances, usually finance planners focus on the aspect of personal finance rather than investments and insurance.[/TD] [/TR]
[TR] [TD]http://www.topeducations.us[/TD] [TD]Are you drowning in debt? Do you have no idea where to turn for help paying that debt off? This article discusses the top education debt solutions so that you can determine what the best way is for you to experience freedom from debt.[/TD] [/TR]
[TR] [TD]http://www.sportsfusion.us[/TD] [TD]A comprehensive auto review on the 2010 Ford Fusion that all automotive enthusiasts will enjoy. The new 2010 Ford Fusion is one of the most fuel-efficient, gas-engine, midsize sedans in America. The front-wheel-drive Fusion S with the I4 engine delivers 34 mpg highway and 23 mpg city, in six-speed automatic form.[/TD] [/TR]
[TR] [TD]http://www.royalproperty.us[/TD] [TD]Ben Thompson and Bat Masterson were notorious frontier gamblers/gunfighters that plied their trade in the wild cattle towns of Kansas. In 1879, Masterson hired Thompson and fifty Texas gunmen to serve as mercenaries for the Atchison, Topeka, & Santa Fe Railroad Company in a right-of-way feud in Colorado. It would become known as the Royal Gorge Railroad War.[/TD] [/TR]
[TR] [TD]http://www.vacationsplan.us[/TD] [TD]Vacation planning is fun and easy so you don't need to get overwhelmed. The first thing I want you to do is to take a deep breath and don't panic. If you've never done this before, relax. I am here to help you with some simple steps to plan a great vacation.[/TD] [/TR]
[TR] [TD]http://www.educationmagazines.us/[/TD] [TD]Information is the name of the game when it comes to academic life. Without latest information about the kinds of course options, scope of different courses, scholarships, fees, etc., offered by different colleges and universities, a student feels handicapped in taking the right decision regarding his or her academic growth.[/TD] [/TR]
Publier Vos Annonces Gratuitement Suisse Petites annonces gratuites en Belgique Publier Vos Annonces Gratuitement Belgique / !!!!! Site Recommandé ? Petites Annonces gratuites en Belgique | Acheter et vendre d'occasion et seconde main Petites annonces gratuites au Canada Site de petite annonce classée gratuite Yatoola, afficher une annonce gratuitement. Vous pouvez vendre et acheter partout au Canada Publier Vos Annonces Gratuitement Suisse Petites annonces gratuites en Suisse: marché en ligne avec plus de 8 mio. de visiteurs par mois. Trouvez des voitures, jobs, immobilier Annonces au Maroc 100% Gratuite Il est un Bienvenue petites annonces gratuites, petites annonces gratuites d'occasion, annonces gratuites immobilier, gratuites auto, animaux, gratuites belgique, Petites Annonces Gratuites pliggfra bien plus qu'un site d'annonces ! Site gratuit de mise en relation entre les annonceurs MasterChef | Film maroc | fokaha Trouvez des produits YOUTUBE VIDEOS ANALYSIS !!! l'offre Tous Produits| Animalerie, Téléphones l'offre Tous Produits| Animalerie, Téléphones telephone sett telephone set. telephone set synonyms, telephone set pronunciation, telephone set translation, English dictionary definition of telephone set. Noun 1. Piu Grandi Film film del 2017 stilata in base ai voti degli utenti del primo social network italiano dedicato al cinema. Le Barzellette Piu Belle Le più belle Barzellette Divertenti e Barzellettte Divertentissime France Annonce Gratuite annonces gratuites de particuliers et pros : faites de bonnes affaires d'achat, vente et déposez votre annonce gratuite Bacheca annunci qui gratuiti pubblicazione auto tua annuncio pubblicazione un cominciare trovi nuovo auto un bar, Gli auto La gratis Gli annuncio annunci. annunci gratuiti on line annunci gratuiti per chi cerca casa, lavoro, incontri ed eventi. Migliaia di annunci sempre nuovi per trovare subito quello che stai cercando! Video Programmi Tv Dmax Tutti i programmi di oggi su Dmax, completi di ogni informazione: descrizione delle trasmissioni e trame dei film. France annonces
На данной странице представлены элементы инфоблока статьи, относящиеся к типу Публикации. Статьи опубликованы на странице с помощью комплексного компонента Новостной раздел с указанием параметров инфоблока Статьи. При создании каждой статьи был использован тег <break />, который позволяет осуществить разделение статьи на страницы. В публичном разделе такая статья будет представлена в виде нескольких страниц в зависимости от количества тегов <break />