Lost YUI Tabs After Upgrade

This forum is only for questions or discussions about working with the mojoPortal source code in Visual Studio, obtaining the source code from the repository, developing custom features, etc. If your question is not along these lines this is not the right forum. Please try to post your question in the appropriate forum.

Please do not post questions about design, CSS, or skinning here. Use the Help With Skins Forum for those questions.

This forum is for discussing mojoPortal development

This forum is only for questions or discussions about working with the mojoPortal source code in Visual Studio, obtaining the source code from the repository, developing custom features, etc. If your question is not along these lines this is not the right forum. Please try to post your question in the appropriate forum.

You can monitor commits to the repository from this page. We also recommend developers to subscribe to email notifications in the developer forum as occasionally important things are announced.

Before posting questions here you might want to review the developer documentation.

Do not post questions about design, CSS, or skinning here. Use the Help With Skins Forum for those questions.
This thread is closed to new posts. You must sign in to post in the forums.
3/7/2010 10:07:35 AM
Gravatar
Total Posts 131

Lost YUI Tabs After Upgrade

Hi, just upgrade my site to 2.3.3.9. Everything looks great but I lost my YUI Tabs.

In looking at the documentation, it points to a YUI location of ~/ClientScript/yui260/assets/skins/sam/tabview.css in web config, but there are no YUI files in that location and as far as I can tell never have been. So I'm at a loss as to why I lost them.

I did update my skin as well, so I'm sure I broke it some how, just not sure how to get it back.

Any thoughts?

3/7/2010 10:18:36 AM
Gravatar
Total Posts 18439

Re: Lost YUI Tabs After Upgrade

Hi David,

Once upon a time we shipped YUI with mojoPortal, but quite a while back we switched to loading it from the google CDN by default. The setting in Web.config would only be used if you need to host the files locally like on a private network with no internet access.

Did you get the newest Web.config or try to keep an old one? You should use the new one.

Also make sure your layout.master has the StyleSheetCombiner control and the ScriptLoader control, compare your file to versions in /Data/skins which have been upgraded over time. We never touch skin files under /Data/Sites/[SiteID]/skins during upgrades in case customizations have been made.

You should have this in Web.config:

<add key="UseGoogleCDN" value="true" />
 <add key="GoogleCDNYUIVersion" value="2.6.0" />

newer versions of YUI are not supported and cause problems in some places so don't change the version to a higher one.

So the path you mention is where you should install the YUI 2.6.0 files if you need to host them locally.

If you set UseGoogleCDN to false then you would need to host the YUI and jQuery and jQueryUI files locally.

Hope it helps,

Joe

3/7/2010 10:27:28 AM
Gravatar
Total Posts 18439

Re: Lost YUI Tabs After Upgrade

More info: I'm hoping to move away from the YUI tabs in the future and standardize on jQuery. As such I don't use the YUI tabs in content so I changed it to by default only load the YUI CSS on pages like edit pages where it is used. So by default it will not be included in CMS pages, ie pages in the menu, but if you are using it in your content you can set IncludeYUITabs=true  on StyleSheetCombiner and then it will always load it.

The idea is that in using both YUI and jQuery we are loading too many CSS and javascript files, that is why I want to standardize on jQuery. As a first step I've made the default not to load YUI at least on CMS pages unless you set it to true. This way at least public facing pages don't have both YUI and jQuery UI css loaded.

Since we currently have YUI tabs as a built in content template which encourages its use in the content, I also added a config setting AlwaysLoadYuiTabs which can be set to false to exclude those templates from the template system.

Hope it helps,

Joe

3/7/2010 11:09:55 AM
Gravatar
Total Posts 131

Re: Lost YUI Tabs After Upgrade

I've used the most recent web.config and have both values set as described.

The missing behavior is on the Admin > Site settings page and the myaccount pages, all stuff I never touch.

When I switch to my old skin, it all works fine so clearly a skin issue, just can't find what I am missing.

I don't want to set true on the style sheet combiner as those are the only places I use it.

I'll keep looking and post if I find something.

3/7/2010 11:25:45 AM
Gravatar
Total Posts 18439

Re: Lost YUI Tabs After Upgrade

Make sure the ID on StyleSheetCombiner and ScriptLoader are the same in your skin vs other skins, the IDs are important.

Hope it helps,

Joe

3/7/2010 12:00:16 PM
Gravatar
Total Posts 131

Re: Lost YUI Tabs After Upgrade

OK, I found it. When I copied the stylesheet combiner from another layout.master, it changed the id to StyleSheetCombiner1. Changed it back to StyleSheetCombiner and it seems to work.

Is that correct, is the ID a unique identifier for this control?

3/8/2010 12:04:03 PM
Gravatar
Total Posts 18439

Re: Lost YUI Tabs After Upgrade

A server side control id must be unique within its container such as a master page, a usercontrol, or a .aspx page. If you paste one in using Visual Studio and it clashes with an existing id VS will change what you pasted in.

In this case the id of the control is important because pages like Site Setings that use YUI must find the control by id with Page.Master.FindControl in order to set the property to include YUI.

Best,

Joe

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