How to set dynamic markup to a transformation wrapper in Kentico - asp.net

I'm very new to Kentico and asp, I'm coming from a php/Wordpress background into this. I'm working on a Page Template that has an optional Carousel in it. I'll need the content of the carousel which I have set as a Document Type, but I'd also like to be able to have a Settings Document type in which they are contained. In the Settings Document Type I want to be able to control what kind of wrapper goes around the whole thing, using a form to do this. I've played around with Hierarchical Transformations, but can't seem to get them to work. At best, I'm able to display markup from the transformation, but the variables set in the Settings Form won't to come through.
Does anyone have any idea as to the best way to get this to work the way I want it to, or is this even possible? I only have access to the CMS and have no access to the file structure or anything like that. I've looked through pages of Kentico documentation, but it seems vague and I can't seem to find any examples of anything close to what I want to achieve.
Update: I've finally somewhat figured out how to make this work with Hierarchical Transformations, but I'm still having an issue with the Opening and Closing Wrappers which I set as Header and Footer Transformations. For some reason these tags appear twice, one within the other. The outer one does exactly what it's supposed to do, but the inner one doesn't take the variables set within the form. Anyone have any idea how I can just display this once?

Related

Sulu.io CMS editor add images inside content

Is there a way to add images inside Sulu.io editor, rather than creating properties or blocks?
I have been searching this in their issues, documentation and google, but I'm not sure if its possible or not, even tho one can add image links but not image tag, does not make sense.
We don't plan to support putting images directly into the editor. We actually also don't want that, because it contradicts our philosophy. Enabling the user to do stuff like that in the editor, would probably also allow him to break the site in unexpected ways, and it's close to impossible to properly implement a responsive design this way.

Drupal 7: best way to render arbitrary content directly into <body> while keeping what's in <head>

I'm new to Drupal. As I understand a Drupal(7 in my case) page normally would have layers of wrappers around a block, sections, regions etc ... What I'm trying to achieve is to render some arbitrary content directly into "body" with none of the wrapper overheads, while keeping everything in "head". I've researched hook_block_list_alter which allows you to exclude blocks before rendering - which doesn't offer the ability to customize (removing) sections. Then I came across hook_page_alter looks like a good way to go, although I haven't dug too deep yet, still trying to understand the structure of the $page object. I thought about other options such as using the context module to configure sections/zones when requested page url is in certain pattern.
What's "THE Drupal's way" of doing this?
I would suggest you to first try with Drupal's template system and then, if you can't achieve something try with hooks:
https://www.drupal.org/node/337173
So, as you mentioned drupal has layer templates wrapping one around another. Most outer one is html.tpl.php and if you want something to appear in page head put it there. Then, second inner one is page template, which can be different for any content (node) type. But you also have block templates, field templates...
To override templates for specific content type or field or something else Drupal has some special naming convention. So if you name you template some specific way (and clear the cache!) drupal will start use it in that specific case.
Check the documentation for more details.

Silverstripe 3 - Force list view of children for one page type

is it possible to force the children of a defined page type always to show as list?
And if yes, who? Can't figure out who to do this.
Thank you in advance
it is possible, however its pretty trick to get it working properly.
It is not only a lot of work to get it done right, it will also bring certain problems with it which you will have to overcome (eg the Preview Split Screen will not work, you will have to apply some custom javascript I think), so consider this carefully.
Have a look at the silverstripe-blogger module, micmania1 has done a pretty good job there.
He uses a GridField to display the blog children (BlogPosts) if you set the config like this:
BlogPost:
show_in_sitetree: false
you can find the module on Packagist and GitHub

Delayed rendering of components outside of the viewport in Flex

I am looking for some advice in regards to getting a very quick display of our reports. The problem I am working with is I receive an XML data structure that defines our layout. The report can be anywhere from 2 to 3 pages to perhaps 20 to 30. So to make the report display as quickly as possible I would like to just render the visible portion of the report. Here are the issues I need to overcome to accomplish this and I am looking for some advice how how to accomplish this.
To get a better visualization, Think of this like a word document. The reports have sections and I want to be able to get them to display as quickly as possible.
1) Of course I do not know the height of the child components I will be adding. Is there any techniques where I can determine if the components I am adding are not include in the view port and could I trigger off scroll bar movement.
2) I was thinking of adding estimation to the children components and then using that to set the height of the parent container. then when I receive scroll bar move event, I would check if the child components have been added to the parent and if not add them. Is there anyway to get the height of a component without rendering it?
3) Does Flex support anything built in that will accomplish this.
Any other techniques would be welcome. Basically I want to get the report displayed to the user as quickly as possible and delay the rendering of components that are off the screen.
Any suggestions would be welcomed. Thanks in advance.
Added Info.
Hard to provide code since I have not coded it yet. Let me try and expand with some details. I have a Parent Container where I take the some XML and using the XML creating children components based on the information in the XML. Right now when we do this it can take a long time to render a long report. What I want to do is to reduce the rendering time by delaying the rendering of those children objects. I have looked into things like the creation policy and createDeferredContent, but not sure if this is the right way to go. Guess the general problem I need to attack is how to do you stop rendering objects once you are outside the parents viewport. What I want is an item renderer like functionality but there is no similarity between the children. Perhaps a picture might be useful (will add as soon as I get to 10 points)?
Use spark List with useVirtualLayout turned on. This is what it does.
There is always similarity between children, but if you can't find it, you can use an itemRendererFunction.

Drupal—Content Repetition & Consistency

I'm currently working on a Drupal site (I'm fairly new to Drupal) and need to be able to create some blocks of content that appear on multiple pages and remain consistent between those pages. I'll need it so that if I change the content in one place, the change will be reflected in all places it appears.
I've looked around in CCK a bit but can't seem to find a way to accomplish this there. Is there a way to accomplish this?
Thank you!
You can define your own blocks at /admin/build/block/add, just put your content inside a block and then go to "page specific visibility settings" and put the pages, on which the block should appear there.
There are other ways to achieve something like you describe, if the blocks don't do what you need you should provide some more details on what exactly you want to do. Depending on the structure of your site, you could also use a node (set to appear at the top of lists) that is set to appear on those pages.
It would depend of what kind of data you need to display in this block if its static use
/admin/build/block/add
if you intend to fetch some content from your content types use views to create such block and then use "page specific visibility settings".

Resources