Self-contained activity within a channel?

I don't even really know how to phrase this -- I'm trying to figure out if

there is any way of having the results of some search or simply a click on a

link returned within a channel area independent of any other channel on the

page.

For example, a page has channels X, Y and Z. X contains a search form.

User enters some search terms into the form and submits it. Instead of

getting a new page with just the search results, I want the entire portal

desktop page to redisplay, with channels Y and Z unchanged but the results

of the search now showing up within X.

This could also be simply a click on a URL within X assuming X originally

contained some links -- the page would redisplay but the destination of that

link would be displayed not on a new page but within the bounds of the

channel X box, completely independent of channels Y and Z.

In an even more complex case it could be an entire interaction that would

take place entirely inside a channel -- perhaps some web application where

the channel area initially displays a logon prompt and then the user can

continue to traverse many different screens within that channel without

disrupting the rest of the portal page.

Aside from some clever coding using an IFRAME or some DHTML solution, I

can't think of any way to do this using only the portal framework.

I haven't seen any other portal products that can do this, but I was asked

if this was possible and while I was pretty confident about my answer, I

just wanted to make sure I'm not overlooking or misunderstanding something.

Thanks

[1705 byte] By [708785] at [2007-11-25 4:29:08]
# 1

This is possible using the DesktopURL class and a custom content provider.

In the custom content provider, use the DesktopURL class to generate all links

including form actions. Each link can pass arguments to the channel to cause it

to do something different when the link is pressed. For example, let's say we had

three pages of data that we wanted to show in a channel, with two links to get to

the other two pages of data. Do the following when generating the links:

output.append("<a href=" + new DesktopURL(getSession(), getName() + ".data=2") +

">page 2</a>" +

"<a href=" + new DesktopURL(getSession(), getName() + ".data=3") +

">page 3</a>");

At the beginning of the getContent method, the decision about what output to display

would be coded as:

String data = params.get(getName() + ".data");

if (data == null || data.equals("1")) {

// display page 1

}

else if (data.equals("2")) {

// display page 2

}

else if (data.equals("3")) {

// display page 3

}

This general strategy can be used to produce a complete application that runs within a channel.

HTH.

Tom

Marshall Levin wrote:

>

> I don't even really know how to phrase this -- I'm trying to figure out if

> there is any way of having the results of some search or simply a click on a

> link returned within a channel area independent of any other channel on the

> page.

>

> For example, a page has channels X, Y and Z. X contains a search form.

> User enters some search terms into the form and submits it. Instead of

> getting a new page with just the search results, I want the entire portal

> desktop page to redisplay, with channels Y and Z unchanged but the results

> of the search now showing up within X.

>

> This could also be simply a click on a URL within X assuming X originally

> contained some links -- the page would redisplay but the destination of that

> link would be displayed not on a new page but within the bounds of the

> channel X box, completely independent of channels Y and Z.

>

> In an even more complex case it could be an entire interaction that would

> take place entirely inside a channel -- perhaps some web application where

> the channel area initially displays a logon prompt and then the user can

> continue to traverse many different screens within that channel without

> disrupting the rest of the portal page.

>

> Aside from some clever coding using an IFRAME or some DHTML solution, I

> can't think of any way to do this using only the portal framework.

>

> I haven't seen any other portal products that can do this, but I was asked

> if this was possible and while I was pretty confident about my answer, I

> just wanted to make sure I'm not overlooking or misunderstanding something.

>

> Thanks

704689 at 2007-6-29 2:31:53 > top of Java-index,Web & Directory Servers,Portal Servers...
# 2

Marshall,This is an excellent question.. We would like to do exactly the same sort of thing.A general solution to this problem would be extremely useful.Regards,Adam Farquhar.Marshall Levin wrote:... a page has channels X, Y and Z. X contains a search form.User enters some search terms into the form and submits it. Instead ofgetting a new page with just the search results, I want the entire portaldesktop page to redisplay, with channels Y and Z unchanged but the resultsof the search now showing up within X.

Guest at 2007-6-30 21:15:24 > top of Java-index,Web & Directory Servers,Portal Servers...
# 3

Hi,

i don't know if you have reached what you want to do.

I've done the same thing you want to do:

I've tried it with the sample code in the answer but the code is a little bit incomplete:

So here we go:

(this is only the getContent Method which you must overwrite)

there are comments in the code, you will need this line if you want to iterate over all attributes....

public StringBuffer getContent(Map m) throws ProviderException {

StringBuffer content = new StringBuffer("");

String value;

Set mapSet = m.keySet();

Iterator it = m.keySet().iterator();

DesktopURL test = new DesktopURL(getSession(), "iwtDynProviderVal=1");

DesktopURL inhalt = new DesktopURL(getSession(), "iwtDynProviderVal=2");

//while(it.hasNext()) {

//Object Key = it.next();

//content.append("(" + Key.getClass().getName() + ") ");

//content.append(Key);

//content.append(" --> ");

//content.append("(" + m.get("iwtDynProviderVal").getClass().getName() + ") ");

if (m.containsKey("iwtDynProviderVal")) {

value=((String[])m.get("iwtDynProviderVal"))[0];

}

else {

value = null;

}

//};

if (value == null || value.equals("1")) {

content.append("<A HREF=\"");

content.append(test.toString());

content.append("\">Test</A>");

content.append("
");

content.append("<A HREF=\"");

content.append(inhalt.toString());

content.append("\">Inhalt</A>");

content.append("
");

}

else if (value.equals("2")) {

content.append("something");

}

else if (value.equals("3")) {

content.append("something");

}

return content;

}

another thing. I've done the same thing with a jsp and it is more easier to work with them because you doesn't need to restart the portal every time...

708785 at 2007-6-30 21:15:24 > top of Java-index,Web & Directory Servers,Portal Servers...
# 4
Hi,I do have a similar problem,Is it possible to display the content of a search of channel X,in Channel Y,using jsp.sThanks...
704689 at 2007-6-30 21:15:24 > top of Java-index,Web & Directory Servers,Portal Servers...