Multiple Content Panes on Layout.master - 14 Panes

This is a forum to suggest new features for mojoPortal. 

This thread is closed to new posts. You must sign in to post in the forums.
7/24/2009 1:57:33 PM
Gravatar
Total Posts 22

Multiple Content Panes on Layout.master - 14 Panes

Hellow Joe,

I know you currently have support for up to 5 content panes on layout.master for one of you designs.

Can I add more than 5?

 

Please find below an example of what I would like to accomplish.

http://www.eslomio.com/panes.png

 

Thanks,

 

Beldwin

7/25/2009 6:33:54 AM
Gravatar
Total Posts 18439

Re: Multiple Content Panes on Layout.master - 14 Panes

Hi Beldwin,

Thats a lot of panes and a complex layout. It all seems very logical visually but the problem as I see it is if you break up the content into that many pieces you end up with a page that makes 30 or more hits to the database because each content instance retrieves its own content and settings. So while it might seem nice and user friendly to make that many sections, it adds a lot of complexity and hurts performance and scalability.

In my view its a better practice to do some layout inside a single content item. Like on the home page of this site I have a 3 column layout but its really just one content section that uses the whole width and the columns are done in html inside the one content item. You could even create content templates with some pre-establised layouts.

Best,

Joe

8/9/2009 10:24:06 AM
Nux
Gravatar
Total Posts 183

Re: Multiple Content Panes on Layout.master - 14 Panes

Hi Joe,

while I don't really need more than 3 columns for my own site'(s), I guess this would be a really improvement to the system to
have more than 3 or 4 content panels, with the functionality to drag & drop the different modules on the admin page.
For my earlier boss, I made a small cms system, and the users could choose where they wanted to have their content panels, how much and changed the content with drag & drop. And despite the fact that it is not that easy to develop it, it worked really well and also quick. Even on the public page.

Do you think that this would be possible in the future? I guess this is not the most important thing to work out , just a thought.

Stef

 

8/9/2009 12:14:11 PM
Gravatar
Total Posts 18439

Re: Multiple Content Panes on Layout.master - 14 Panes

We support up to 5 sections right now. 

Layout can be done inside the html module and this can save a lot of hits to the db as opposed to having multiple html modules on the page. The home page for this site for example is really just 1 html module with layout done internally. The main module has the title hidden and I have simple layouts using the floatpanel css class that most skins has a version of.  This could easily be made into a content template to make it easy to re-use the layout and a catalog of re-useable layouts can be created. This strategy gives a lot of flexibility and better performance than making a bunch of separate html content instances on a page.

The main layouts adapt automatically from 1 to 3 columns and its possible to have a header and footer content section. So this makes it possible to do almost anything with a combination of the main layout and layout internal to a content instance.

mojoPortal allows you to put as many modules on a page as you like but its not a good idea to put a bunch of things on a page because each thing will typically make at least 2 hits to the db, one for its settings and one for the main content. I think adding more content regions only encourages more content instances on a page and I think its better if the CMS doesn't lead in the wrong direction by encouraging this. 

Best,

Joe

8/9/2009 12:58:07 PM
Nux
Gravatar
Total Posts 183

Re: Multiple Content Panes on Layout.master - 14 Panes

Hi Joe,

like I said, I can do anything I like with the way it is now in mojoportal. And having 5 sections is even better.
Some thoughts about your comment:

The home page for this site for example is really just 1 html module with layout done internally.

Ok that your home page is 1 html content module, but I bet that you can not change it without hitting the "source" button and change things over there. Try to explain that to a customer or a less experienced person.

because each thing will typically make at least 2 hits to the db, one for its settings and one for the main content.

Does this mean there is no caching for this? So you go for every page request and for every module to the db?

Don't get me wrong Joe, I really like your product and follow it and hope I can integrate it in more customers sites. I was only thinking in the positive way to go to the future .


Stef

8/9/2009 5:42:32 PM
Gravatar
Total Posts 18439

Re: Multiple Content Panes on Layout.master - 14 Panes

Hi Stef,

No, of course I change it all the time without going to source view. I admit when I initially created it, it required using source view and if I wanted to change the layout it would require it again but it does not require source view to edit the text content.

To me this is the opportunity that you and others have to add value for your customers besides just installing and skinning. The content template system is designed for much more than just the javascript widgets we have, it can be used to create layouts that can empower users and supplementing the system with some layouts beyond what is included is a way to solve some common goals for your customers. Perhaps at some point I will implement more included templates to demonstrate this.

As far as caching, thats a complex topic that many people misunderstand. Caching uses server memory and in the vast majority of hosting situations thats the most scarce resource of all. I have seen inappropriate use of cache be a big performance killer. Yes database access is a precious resource but unless you are on a dedicated server with gobs of RAM server memory is much more precious. Shared hosting is usually a very memory constrained environment and using too much cache when your memory allocation is low is a sure way to cause your app to continuously recycle the app pool and kill performance because in most hosting in order to prevent rogue apps from running away with server memory they app pool is configured to recycle when a certain amount of memory is used and this frees up the cache. So if you try to cache too agressivley it can really hurt performance unless you have gobs of ram to hold all that stuff you are caching. As it is the runtime caches certain things and you have no choice like sitemaps, themes etc get cached heavily by the runtime and for very large sites the sitemap can be a fairly large thing to cache, and we do cache more complex and frequently used objects like SiteSettings. So cache is something to use very judiciously and can easily be misused to disadvantage.

Not all database hits are the same in terms of expense. If there is sufficient ram expensive things should be cached. But cache is rarely a cure all for too many db hits. db hits are neccessary, but its best to optimise and reduce the number of them as much as possible without having to cache to make up for too many.

mojoPortal does support caching in some features including the html module but it is disabled by default for this reason and people should think very carefully before enabling it. Even on a dedicated server, unless you are trying to solve an actual rather than theoretical performance problem I would not enable it. I'm not using it on this site and I'm on a dedicated server with 1 GB of ram. Its a good environement but its not a high end environment. I think part of the reason some other well known .NET apps don't work well in budget hosting is because they cache too agressively and consume too much server resources and this forces the app pool to recycle frequently killing real performance.

If you want to cache things you can add this to Web.config/user.config:

<add key="DisableContentCache" value="false" />

then you will see in module settings where you can specify the cache duration for features that do support caching. Note however that features that use ajax postbacks or that personalize content are not good candidates for caching.

Hope this explanation helps.

Best,

Joe

 

8/10/2009 2:16:26 AM
Nux
Gravatar
Total Posts 183

Re: Multiple Content Panes on Layout.master - 14 Panes

Hi Joe,

I don't have any experience with those content templates, as I thought it was something just with jquery, and no plain html template.
So perhaps an example to demonstrate this would be helpful.

About caching: I'm used to work on a dedicated server, or with strange servers, so I didn't thought about hosting environments. But while reading, I totally understand that this is a major thing to take into account for the people who use such an environment.

Every time I go to the forum to ask things or to read it, I learn something new. Ok, I haven't read everything from the documentation, cause it takes a  lot of time, but it is nice to see that there is already a lot of things implemented in the project. Keep up the good work.

So Joe, if you find the time to make an example of the content template or extend the documentation, ...

Thanks
Stef

8/10/2009 7:44:36 AM
Gravatar
Total Posts 18439

Re: Multiple Content Panes on Layout.master - 14 Panes

Hi Stef,

I have some documentation about the Content Template System, there is a link in the Admin menu for Content Templates that allows creating your own.

I've added 2 new templates for the next release and you can try them now on the demo.mojoportal.com site. I created one named "3 Columns Over 1 Column" and one named "4 Columns Over 1 Column" that work fairly well with the included skins. The 3 Columns Over 1 Column is based on the home page layout on this site.

I think the real magic of the content template system depends on having css in your skin that supports the template to make it attractive, like styling the headers etc. So there are a lot of creative possibilities but its more difficult to make templates that work in all skins unless you can rely on each skin having the needed css.

Best,

Joe

8/10/2009 8:47:32 AM
Nux
Gravatar
Total Posts 183

Re: Multiple Content Panes on Layout.master - 14 Panes

Hi Joe,

I checked the demo site, and I see them in the wysiwyg, but nothing to see on the admin page.
Is that normal? Because I don't know where to search if I want to make them myself.

Stef

8/10/2009 8:55:57 AM
Gravatar
Total Posts 18439

Re: Multiple Content Panes on Layout.master - 14 Panes

Click the key icon and its the 4th thing on the list.

Hope it helps,

Joe 

8/10/2009 9:07:20 AM
Nux
Gravatar
Total Posts 183

Re: Multiple Content Panes on Layout.master - 14 Panes

You must sign in to post in the forums. This thread is closed to new posts.