Monday, February 23, 2009

Deleting and Adding menu items

Many people asked me about adding or deleting menu items in UCM, it is easy to do this with UCM.

The steps to customize menus
1- Create a custom component, or use an existing one
2- Add new resource file to the component that file type is "HTML Include"
3- Add new include with the following name "custom_finish_layout_init" where it is an existing include that creates menus and we want to customize it
3- Inside that include write the following

// First we will call the parent definition for menus
<$include super.custom_finish_layout_init$>

// If we want to delete "My Profile" link

// Now we will add new menu item and we will add one child link to that menu item
// Check if the menu has been added before
<$if not MyScreensMenu_included$>
// add a drop-down menu, or a tray to the UI, that new menu item will be called "My Screen"
navBuilder.addChildNodeTo('NAVTREE', 'collection', 'id==MyScreens', 'label==My Screens');
//Now check if we are using Top Menus layout
if (navBuilder.menuB)

//Or we are using Trays layout
else if (navBuilder.trayA)

// Flag that the new menu item has been added
<$MyScreensMenu_included = 1$>

//At last add the link to the menu item that link called "Link 1"
navBuilder.addChildNodeTo('MyScreens', 'item', 'id==link1', 'label==Link 1', 'url==');

The code in blue is javascript code and in red is idocscript, also notice the following idocscript variable "MyScreensMenu_included" only defined when we used it that is because idocscript language doesn't need you to define variable before using them (Unchecked types language)

Monday, February 16, 2009

Pilanesberg Park - South Africa

I visited last Saturday the Pilanesberg Park in South Africa, it was awesome to see animal in the natural life, and I want to send special thanks for Johan and his wife from South Africa because John arranged for that and he took to that beautiful park. I enjoyed my day there watching animals and natural life. I think it's worthy to visit South Africa again but as a tourist.

Monday, February 9, 2009

I was confused because of SecurityFilter component

I am in a workshop in South Africa, and before I begin in exploring WebDAV, I installed HowToComponents sample, then suddenly While I am exploring WebDAV administration I discovered WebDAV is not working. I tried to resolve the problem but I failed where I was thinking the problem may be from WebDAV configuration or from Folders component. So I returned to the last snapshot of my lab virtual machine.

The story not ended yet, I discovered on of the attendees is facing the same problem and of course I should resolve it - I can not escape :)-

I was sure that the problem is trivial one but when I discovered that problem is from SecurityFilter component (part of HowToComponents bundle), I wanted to kill myself because I face the same problem before from 1.5 years.

Don't use SecurityFilter sample component with WebDAV

Sunday, February 8, 2009

South Africa

I visited today two parks in South Africa lions park and crocodile park, and I was lucky to watch lions eating and also crocodile but of course they are not in jungle and they are not hunting. But I was missing an important thing accompany, my family or my friends.

I took these pictures

Wednesday, February 4, 2009

From Dubai to Johannesburg

I got a long flight from Dubai to Johannesburg 8 hours with stops, the longest trip I had in my life. I finished Dubai UCM workshop, and I think it was successful in helping Oracle partners to know more about the product, and in giving them a push to work on the product.

Now I am in Johannesburg to give another workshop, of course repeating my words again :) and again. I wish I will give another successful workshop there. By the way until know all South African people are so nice with me, and Oracle South Africa is very beautiful and organized.