Saturday, September 29, 2012

Skin Analysis on WebCenter Spaces Page Template

Oracle WebCenter Spaces provides framework and resources that ready for business users to use after installation and configurations. But we all know the default look and feel of the site is really not appealing. I’ve seen prospective customers direct eyes on the WebCenter great features but step back because of the look and feel. I will have to confirm them that the site can be skinned and customized to whatever you want the site to look like. And that’s true, there are indeed great looking sites out there using sophisticated CSS and JavaScript (e.g. JQuery). Those sites are mostly designed from a HTML markup perspective and mixed with ADF components, which could make the source codes of the pages hard to read and maintain. Hard to read? Who cares, as long as it works for what the customer wants. But one of the drawbacks I’ve seen and it’s worthy to mention is it breaks the partial page rendering because of the mix of html and ADF components. Most of the pretty WebCenter public sites so far don't have the PPR feature - every navigation is a full page refresh - which doesn't surprise me (If anyone knows any public sites with PPR enabled, please let me know). Therefore, I will do a few analyses on the standard WebCenter Space page template and make a few changes on the CSS file to improve the look and feel of the WebCenter Spaces site. It might not be good enough for your needs, but should be a good start to begin with.

The default page template widely used in WebCenter Spaces is the one called “Top Navigation”. Please note there is another version of top navigation but stretchable. I will take the non-stretchable one to present as it is the default one being used. Here is the screenshot of it using the default top navigation page template. 

Page Structure

I’ve marked four regions which will represent on the page definition later on. To grab the source codes for the page template, just go to the administration section -> resources, from the ‘page template’ group, make a copy of the top navigation template and rename it whatever you like, from the edit link, you will be able to see the ‘Edit Source’ link enabled and that’s how you can grab the source code easy and quick. You can paste the source codes into JDeveloper which will help us to understand the page template structure. Here is the screenshot of the page structure:

As you can see, the page template starts with a panelGroupLayout in a scroll layout, and this is how this template is a flow layout template (fixed width of the page). For a stretchable layout, you will see it starts with the ‘panel stretch layout’.

Next you will find two Spaces tags <wcdc> and we will skip that.

Next is a decorative box component and it’s the template header part and the A region in the first image. This region contains site logo, a search inputbox region and several command/go links. You are definitely free to customize those components if you like. One thing you may consider to do is to upload your site logo to content server and put the image url to an ADF image component for the site logo. Decorative box comes with two facets: center and top. By default, the top facet doesn’t have any background (white color), but the center has some light gray background on the top edge of it. See the following:

Besides, decorative box provides an additional property for styling call “theme”.

Tips: About Theme

The purpose of themes is to provide a consistent look and feel across multiple components for a portion of a page. A common usage for themes is in a page template where certain areas have a distinct look. For example, a page may have a branding area at the top with a dark background and light text, a navigation component with a lighter background, and a main content area with a light background.
A component that sets a theme exposes that theme to its child components and therefore the theme is inherited. Themes can be set (started or changed) by the following components:

·         af:document
·         af:decorativeBox
·         af:panelStretchLayout
·         af:panelGroupLayout

By definition, themes are cascaded down through all child components. All HTML elements that are rendered by a rich component within a themed component will have the theme added to its list of style classes. Themes are not compatible with tonal styles and therefore only one method can be used per page (themes or tonal styles). A blank theme will remove the current theme, and a value of "inherit", null or not setting a theme will use the current theme. Skins are the sources of the themes. Some skins may have no themed definitions. Suggested theme names include "dark", "medium", "light", and "default".

Besides decorative box, Spaces have additional theme styling, such as “webcenter” is applied to the decorative box by default. If you want to have your own background and styling, I suggest avoiding using the decorative box simply by dragging its direct child out of the decorative box. In this case it’s ‘panel border layout’. Just drag the panel border layout out of the decorative box and comment it. You can apply your styling directly on the panel border layout.

Next component is the navigation panel region which is marked as ‘B’. The region is referring a build-in navigation task flow. To examine the source codes of it, please refer to another blog I posted here.

Next part is the content which is just a facet in a page template. It’s marked as ‘C’.

The last part is the ‘panel border layout’ component again wrapping the footer of the page template. It’s marked as ‘D’.


Spaces template uses style class for styling purpose, which comes with “WC” as its prefix. Now I will list all the style class that are used in the top navigation template by what effect it could take for styling in the page.

Here I am going to change the background to white:
/*override the background*/
    background: #FFFFFF !important;

Change the navigation background to dark gray color:
/*change the styling of the page template top navigation*/
.WCSiteTemplateTopNavPanel {
    background: #666666 !important;

To change the navigation links text color to white:
af|commandMenuItem.WCSiteTemplateTopNavPanel::bar-item-text {
    color: #FFFFFF !important;

You can add hover effect if you want by defining:
af|commandMenuItem.WCSiteTemplateTopNavPanel::bar-item-text:hover {}

Define the background of the navigation link when it’s selected:
/*the styling when tab is selected*/
.WCSiteTemplateTopNavPanelSelected {
    background: #FF8000 !important;

You can define the text color to change when it’s selected by:
af|commandMenuItem.WCSiteTemplateTopNavPanelSelected::bar-item-text {}

Define the navigation link to change color when hovering:
/*the styling when mouse hover*/
.WCSiteTemplateTopNavPanel:highlighted {
    background: #7A7A7A !important;

Change the footer background:
/*change the background of the page template footer*/
.WCSiteTemplateFooter {
    background: #666666 !important;

Change the header and footer font color:
/*change the font color on the template header*/
.x106, .x107 {
    color: #FFFFFF !important;
    font-weight: bold !important;

By the above few CSS changes and some minor change on the template, you will find your pages could look like this:

Is it nice and neat? Besides, you won’t have your ppr navigation broken. Enjoy!


  1. Hey guys if you loves to play free online card game then here on our homepage you will play freecell card game it is the multiplayer card game the goal fo the game is to score more than your opponent it is really an awesome and fantastic game you loves to play freecell.


  2. to grow and manage your business letting you to concentrate on your business with One Person Company registration

  3. If you are faced a any type of the problems in your system then quick to visit here and find out all the available answers in windows operating system, all the valuable solution are available in there homepage.

  4. This is very useful post for me. This will absolutely going to help me in my project.
    Read about Best Parental control app.


  5. I like the valuable info you provide in your articles.I’ll bookmark your weblog and check again here regularly.
    Read Best Child monitoring app.

  6. Good job on this article! I really like how you presented your facts and how you made it interesting and easy to understand.
    Read about Tooth Abscess stages with Ekdantam Dental Clinic.

  7. Thank you for the good writeup. It in fact was a amusementaccount it. Look advanced to more added agreeable from you!
    Book appointment with Best Dentist in Jaipur.

  8. Our company provides insect eradication services in Dammam. Our goal is always to satisfy our customers. We eliminate insects of all types and forms. We enjoy a clean environment free of all insects.شركة رش مبيدات بسكاكا
    المبيدات الحشرية الكيميائية
    افضل شركة مكافحة حشرات
    شركة رش مبيدات بالمجمعة

  9. This is really a big and great source of information. We can all contribute and benefit from reading as well as gaining knowledge from this content just amazing
    experience Thanks for sharing such a nice information.

  10. Thanks for posting useful information.You have provided an nice article, Thank you very much for this one. And i hope this will be useful for many people.. and i am waiting for your next post keep on updating these kinds of knowledgeable things...Really it was an awesome article...very interesting to read..please sharing like this information.

    Cpa offers

  11. Oracle WebCenter Spaces gave us a great opportunity to learn a lot of new things. And also to know about the business users to use after the installation and also get best coursework writing service to solve your quality task easily. Thanks for sharing this kind of content with us. I appreciated your work

  12. Thank you for the auspicious writeup. The Benefits of stay at home mom is countless. Have a look at the brighter side of at-home parenting.


  13. شركة نقل اثاث من الرياض الى حائل شركة نقل اثاث من الرياض الى حائل

    شركة تركيب جبس بورد بالرياض شركة تركيب جبس بورد بالرياض

    شركة تركيب طارد الحمام بالرياضشركة تركيب طارد الحمام بالرياضمعلم دهانات بالرياض معلم دهانات بالرياض

    فني تركيب ورق جدران بالرياض فني تركيب ورق جدران بالرياض
    شركة دهان ابواب خشب بالرياض

  14. Nice Post, I really loved this Blog.
    If you are looking for a kind of streaming device that can offer you to watch a large number of TV Programs or movies for the sake of entertainment.

    Roku Activation Link code
    roku activation link
    roku tv activation link code
    activate hulu on roku

  15. إذا كنت تفكر في إجراء عملية تكميم المعدة في مصر، فعليك التأكد من الذهاب إلى أحد افضل مراكز تكميم المعدة يمكنك التعرف عليهم من خلال معدلات نجاحهم العالية وتعليقات المرضى الإيجابية بعد العملية.