I agree with you that skinning shouldn't need access to the content. However, it seems to me it is useful to for the skin to have dynamic behaviors based on the nature of the content.
on a website I'm designing, there are different kinds of "articles" that might be posted . The article types include:
- A picture only (meaning that I want the picture to be at the top of the page without any (unplanned) white space above it).
- a title only
- title and paragraphs
- paragraph only
It is hard to explain without showing you a picture (which I'm unable to do), but what I wanted to to do is prevent dotnetnuke from outputting ANYTHING in the case where there is no content (paragraph or picture) provided. DotNetNuke was breaking my intended layout by inserting empty DIVs when it had no content to fill those divs (I was expecting to be able to output just the title, but the extra divs were adding "white space" below my title.
I am working around the problem, but it seems to me that even if I don't have access to the content, I should have access to a flag that lets me know there is content. Another example use (an opposite use) of this flag would be to place some text like "[add article content here]" only in admin mode and only in the case where the user has not yet added content (I'm aware of the default text when you add a new html module to a page... but that text could be erased by the user).
Anyway, thank you for the response. I guess the main suggestion I have for the future is that modules should be able to expose variables to the container skins so that skins can act on those variables. Examples include:
- a "module count" (per pane) so that I can alternatively style odd and even numbered modules
- "module type" so that I might style modules differently in my container code. As things are now, I would have to depend on the user to remember to change the container skin on a per-instance basis.
- module settings (such as http path to the XML source data for the XML module)
...and maybe better documentation for the existing .ascx container and skin possibilities would be useful. One has to dig through forums now to learn how to access the module id or the module title or to learn that it is possible to detect "admin mode".
Thank you for bothering to reply to mail post.