You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@myfaces.apache.org by Thomas Chang <th...@yahoo.de> on 2007/02/15 13:28:11 UTC

Problem by using

Hi,

I till have problem by using the <t:updateActionListener/>.

Matthias's email had helped me a step forward. I get no error now. 

My situation is: First I login into my web application. I navigate my web application by clicking the index menu on the left side of my page. For example I click the index "Show Message". In this page this a link as follow:

...
<t:commandLink action="openNewBrowser" immediate="true"
  value="Open New Browser" target="readMessageWindow">
  <t:updateActionListener property="property" value="message" />
</t:commandLink>
...

I click the commandLink, a new browser window, "readMessageWindow", will be opened. 

Now my problem: after I close the new opened window and click other index menu, the page "readMessageWindow" will be open again and even worse, this "readMessageWindow" will not be open in a new browser window but just over the first window, somewhat like target="self".

But if I use the <t:updateActionListener /> in a simple web application without login, it runs quite well.

I wonder if this has to do with Session?

Regards

Thomas.



Matthias Wessendorf <ma...@apache.org> schrieb: Thomas,

check [1] for more on it (search for updateActionListener), since you
need a *taghandler*

-M

[1]http://wiki.apache.org/myfaces/Use_Facelets_with_Tomahawk

On 2/2/07, Thomas Chang  wrote:
> Hi Aleksandr,
>
> You are right. I do use Facelets. But I can use other t-tags such as   etc. in xHtml and they work well.  Besides, I have the followings on the top of my files.
>
> Thanks
>
> Thomas
>
>
>
> 
>     xmlns:ui="http://java.sun.com/jsf/facelets"
>     xmlns:h="http://java.sun.com/jsf/html"
>     xmlns:f="http://java.sun.com/jsf/core"
>     xmlns:t="http://myfaces.apache.org/tomahawk">
>
>
> Aleksandr Mazur  schrieb:
>
>
> Hi Thomas,
>
> As I see you are  using faceletes. updateActionListener should be presented in tomahawk.taglib.xml. Is it?
>
>
> Best regards,
>  Aleksandr
>
>
>
>  Thomas Chang 
> 02.02.2007 12:14
>
> Please respond to
>  "MyFaces Discussion" 
>
>
> To MyFaces Discussion 
>
> cc
>
>
> Subject Error by using 
>
>
>
>
>
>
>
> Hi all,
>
>  My code look as follow:
>
>  myPage.xHtml
>  ***************
>  ...
>  
>    action="openNewBrowser"
>    immediate="true"
>    value="Open New Browser"
>    target="readMessageWindow">
>    
>  
>  ...
>
>  But I get following error when try to open myPage.xHtml. What's wrong?
>
>    Tag Library supports namespace: http://myfaces.apache.org/tomahawk, but no tag was defined for name: updateActionListener
>
>
>  Thanks
>
>  Thomas
>   ________________________________
Yahoo! 360° – Bloggen und Leute treffen. Erstellen Sie jetzt Ihre
eigene Seite – kostenlos!.
>
>
>
>     ________________________________
Yahoo! Messenger -   kostenlos* mit Familie und Freunden von PC zu PC
telefonieren .
>
>



-- 
Matthias Wessendorf
http://tinyurl.com/fmywh

further stuff:
blog: http://jroller.com/page/mwessendorf
mail: mwessendorf-at-gmail-dot-com


 		
---------------------------------
Keine Lust auf Tippen? Rufen Sie Ihre Freunde einfach an.
  Yahoo! Messenger. Jetzt installieren . 

Re: How to open a new page which has no close button and no tool bar?

Posted by delbd <da...@oma.be>.
Thomas Chang a écrit :
> impossible? Then how can I catch the window close event in my (xhtml)
> page? What I realy want is: I click a commandLink to open a new page.
> If one close this new page, I will do something. So I want to catch
> this event in the new opened page.
>  
> Thanks
>  
> Thomas
Several note.
1) removing of toolbars and menu is not always appreciated by user. It's
like removing the right click ability.
2) Doing actions during window close event is subject to high jeopardy.
What happen if user just browse to another document? You get no close
event as window still opened. What to do if user turn off computer? What
to do if browser crash? What to do if parent frame was closed? What to
do if user turned off javascript?

If you really need a 'popup' the can not be closed without your
javascript knowing, do it the xhtml way, put a css driven internal frame
on top of the current page. It's not that difficult and is far easier 
to manage in the end (there is no close button or any decoration around
an iframe).
>
>
> */Volker Weber <v....@inexso.de>/* schrieb:
>
>     Hi Tomas,
>
>     i don't think the supression of close button is possible, but for the
>     rest maybe this helps:
>
>     http://tinyurl.com/22k5gr
>
>     Regards,
>     Volker
>
>     2007/2/15, Thomas Chang :
>     > Hi,
>     >
>     > Could you write it a little bit in detail? :) Or maybe you have
>     an example?
>     >
>     > Thanks
>     >
>     > Thomas
>     >
>     >
>     > "Wabner, Thomas (EXT)" schrieb:
>     >
>     >
>     >
>     > Hi,
>     >
>     > you have to use a java script function like openWindow('url',
>     'windoname',
>     > 'parameters like no toolbar') in your action in the onclick
>     parameter for
>     > the commandlink tag.
>     >
>     > - Thomas Wabner
>     >
>     >
>     > ________________________________
>     >
>     > From: Thomas Chang [mailto:thomas2004ch@yahoo.de]
>     > Sent: Donnerstag, 15. Februar 2007 17:47
>     > To: MyFaces Discussion
>     > Subject: How to open a new page which has no close button and no
>     tool bar?
>     >
>     >
>     > Hi all,
>     >
>     >
>     >
>     > My code look as follow:
>     >
>     >
>     >
>     >
>     > value="Open New Browser" target="readMessageWindow">
>     >
>     >
>     >
>     >
>     > I wonder how canI set properties so that the new page
>     "readMessageWindow"
>     > has no tool bar such as forwart and backwort and has no close
>     button?
>     >
>     >
>     >
>     >
>     >
>     >
>     >
>     > ________________________________
>     >
>     > Was ist Glück? Schlafen Fische überhaupt? Die Antworten gibt's
>     auf Yahoo!
>     > Clever.
>     >
>     >
>     > ________________________________
>     > Yahoo! 360° – Bloggen und Leute treffen. Erstellen Sie jetzt
>     Ihre eigene
>     > Seite – kostenlos!.
>     >
>     >
>
>
> ------------------------------------------------------------------------
> Jetzt Mails schnell in einem Vorschaufenster überfliegen. Dies und
> viel mehr bietet das neue Yahoo! Mail
> <http://de.rd.yahoo.com/evt=40589/*http://de.docs.yahoo.com/ymail/landing.html%20>.



Re: How to call a backing bean method from javascript?

Posted by Mick Knutson <mi...@gmail.com>.
You can use DWR

On 2/15/07, Thomas Chang <th...@yahoo.de> wrote:
>
> Assumed I will simulate calling a backing bean function in
> <t:commandLink... action="{#myBackingBean.doSomething}.../> by closing a
> window. I think I have to do followings:
>
> ...
> <body onUnload=jsFunction()/>
> ...
> function jsFunction(){
> ...
> # what should be here?
> ...
> }
>
> Thanks
>
> Thomas
>
>
>
>
>
>
> ------------------------------
> Yahoo! 360° – Bloggen und Leute treffen. Erstellen Sie jetzt Ihre eigene
> Seite – kostenlos!<http://us.rd.yahoo.com/evt=41052/*http://de.360.yahoo.com/>.
>
>
>


-- 
---
Thanks,
Mick Knutson

http://www.baselogic.com
http://www.blincmagazine.com
http://www.djmick.com
http://www.myspace.com/djmick_dot_com
http://www.thumpradio.com
---

How to call a backing bean method from javascript?

Posted by Thomas Chang <th...@yahoo.de>.
Assumed I will simulate calling a backing bean function in <t:commandLink... action="{#myBackingBean.doSomething}.../> by closing a window. I think I have to do followings:
   
  ...
  <body onUnload=jsFunction()/>
  ...
  function jsFunction(){
  ...
  # what should be here?
  ...
  }
   
  Thanks
   
  Thomas
   
   
   
   
   

 		
---------------------------------
Yahoo! 360° – Bloggen und Leute treffen. Erstellen Sie jetzt Ihre eigene Seite – kostenlos!. 

Re: How to open a new page which has no close button and no tool bar?

Posted by Thomas Chang <th...@yahoo.de>.
impossible? Then how can I catch the window close event in my (xhtml) page? What I realy want is: I click a commandLink to open a new page. If one close this new page, I will do something. So I want to catch this event in the new opened page. 
   
  Thanks
   
  Thomas
  

Volker Weber <v....@inexso.de> schrieb:
  Hi Tomas,

i don't think the supression of close button is possible, but for the
rest maybe this helps:

http://tinyurl.com/22k5gr

Regards,
Volker

2007/2/15, Thomas Chang :
> Hi,
>
> Could you write it a little bit in detail? :) Or maybe you have an example?
>
> Thanks
>
> Thomas
>
>
> "Wabner, Thomas (EXT)" schrieb:
>
>
>
> Hi,
>
> you have to use a java script function like openWindow('url', 'windoname',
> 'parameters like no toolbar') in your action in the onclick parameter for
> the commandlink tag.
>
> - Thomas Wabner
>
>
> ________________________________
>
> From: Thomas Chang [mailto:thomas2004ch@yahoo.de]
> Sent: Donnerstag, 15. Februar 2007 17:47
> To: MyFaces Discussion
> Subject: How to open a new page which has no close button and no tool bar?
>
>
> Hi all,
>
>
>
> My code look as follow:
>
>
>
> > value="Open New Browser" target="readMessageWindow">
> 
>
>
>
> I wonder how canI set properties so that the new page "readMessageWindow"
> has no tool bar such as forwart and backwort and has no close button?
>
>
>
>
>
>
>
> ________________________________
>
> Was ist Glück? Schlafen Fische überhaupt? Die Antworten gibt's auf Yahoo!
> Clever.
>
>
> ________________________________
> Yahoo! 360° – Bloggen und Leute treffen. Erstellen Sie jetzt Ihre eigene
> Seite – kostenlos!.
>
>


 		
---------------------------------
Jetzt Mails schnell in einem Vorschaufenster überfliegen. Dies und viel mehr bietet das  neue Yahoo! Mail .

Re: How to open a new page which has no close button and no tool bar?

Posted by Volker Weber <v....@inexso.de>.
Hi Tomas,

i don't think the supression of close button is possible, but for the
rest maybe this helps:

http://tinyurl.com/22k5gr

Regards,
  Volker

2007/2/15, Thomas Chang <th...@yahoo.de>:
> Hi,
>
> Could you write it a little bit in detail? :) Or maybe you have an example?
>
> Thanks
>
> Thomas
>
>
> "Wabner, Thomas (EXT)" <th...@siemens.com> schrieb:
>
>
>
> Hi,
>
> you have to use a java script function like openWindow('url', 'windoname',
> 'parameters like no toolbar') in your action in the onclick parameter for
> the commandlink tag.
>
> - Thomas Wabner
>
>
>  ________________________________
>
> From: Thomas Chang [mailto:thomas2004ch@yahoo.de]
> Sent: Donnerstag, 15. Februar 2007 17:47
> To: MyFaces Discussion
> Subject: How to open a new page which has no close button and no tool bar?
>
>
> Hi all,
>
>
>
> My code look as follow:
>
>
>
> <t:commandLink action="openNewBrowser" immediate="true"
>   value="Open New Browser" target="readMessageWindow">
> </t:commandLink>
>
>
>
> I wonder how canI set properties so that the new page "readMessageWindow"
> has no tool bar such as forwart and backwort and has no close button?
>
>
>
>
>
>
>
>  ________________________________
>
> Was ist Glück? Schlafen Fische überhaupt? Die Antworten gibt's auf Yahoo!
> Clever.
>
>
>  ________________________________
> Yahoo! 360° – Bloggen und Leute treffen. Erstellen Sie jetzt Ihre eigene
> Seite – kostenlos!.
>
>

RE: How to open a new page which has no close button and no tool bar?

Posted by Thomas Chang <th...@yahoo.de>.
Hi,
   
  Could you write it a little bit in detail? :) Or maybe you have an example?
   
  Thanks
   
  Thomas
  

"Wabner, Thomas (EXT)" <th...@siemens.com> schrieb:
        v\:* {behavior:url(#default#VML);}  o\:* {behavior:url(#default#VML);}  w\:* {behavior:url(#default#VML);}  .shape {behavior:url(#default#VML);}                Hi,
   
  you have to use a java script function like openWindow(’url’, ’windoname’, ’parameters like no toolbar’) in your action in the onclick parameter for the commandlink tag.
   
  - Thomas Wabner
   
      
---------------------------------
  
  From: Thomas Chang [mailto:thomas2004ch@yahoo.de] 
Sent: Donnerstag, 15. Februar 2007 17:47
To: MyFaces Discussion
Subject: How to open a new page which has no close button and no tool bar?

   
    Hi all,

     

    My code look as follow:

     

    <t:commandLink action="openNewBrowser" immediate="true"
  value="Open New Browser" target="readMessageWindow">
</t:commandLink>

     

    I wonder how canI set properties so that the new page "readMessageWindow" has no tool bar such as forwart and backwort and has no close button?

     

    

 

    
    
---------------------------------
  
  Was ist Glück? Schlafen Fische überhaupt? Die Antworten gibt’s auf Yahoo! Clever.



 		
---------------------------------
Yahoo! 360° – Bloggen und Leute treffen. Erstellen Sie jetzt Ihre eigene Seite – kostenlos!. 

RE: How to open a new page which has no close button and no tool bar?

Posted by "Wabner, Thomas (EXT)" <th...@siemens.com>.
Hi,

 

you have to use a java script function like openWindow('url', 'windoname', 'parameters like no toolbar') in your action in the onclick parameter for the commandlink tag.

 

- Thomas Wabner

 

________________________________

From: Thomas Chang [mailto:thomas2004ch@yahoo.de] 
Sent: Donnerstag, 15. Februar 2007 17:47
To: MyFaces Discussion
Subject: How to open a new page which has no close button and no tool bar?

 

Hi all,

 

My code look as follow:

 

<t:commandLink action="openNewBrowser" immediate="true"
  value="Open New Browser" target="readMessageWindow">
</t:commandLink>

 

I wonder how canI set properties so that the new page "readMessageWindow" has no tool bar such as forwart and backwort and has no close button?

 



 

  

________________________________

Was ist Glück? Schlafen Fische überhaupt? Die Antworten gibt's auf Yahoo! Clever <http://de.rd.yahoo.com/xx/searchpromo/i/tagline/cleverfp/*http:/de.answers.yahoo.com> .


How to open a new page which has no close button and no tool bar?

Posted by Thomas Chang <th...@yahoo.de>.
Hi all,
   
  My code look as follow:
   
  <t:commandLink action="openNewBrowser" immediate="true"
  value="Open New Browser" target="readMessageWindow">
</t:commandLink>
   
  I wonder how canI set properties so that the new page "readMessageWindow" has no tool bar such as forwart and backwort and has no close button?
   
  

 

 		
---------------------------------
Was ist Glück? Schlafen Fische überhaupt? Die Antworten gibt’s auf Yahoo! Clever.