Re: ajax ajax ajax

2005-09-19 Thread Enrique Medina
Nice stuff. At least it seems less intrusive than the Ajax framework...2005/9/18, Matthias Wessendorf [EMAIL PROTECTED]:
yet another ajax lib.AjaxAnywhere released on sourceforge via LGPL.http://ajaxanywhere.sourceforge.net/There is also a MyFaces sample, which shows some tomahawk components
with and without ajax.-MatthiasOn 8/15/05, Werner Punz [EMAIL PROTECTED] wrote: Just checked the wiki again, some russian guy posted links to his project
 that stuff looks really interesting http://wiki.apache.org/myfaces/AJAX_Framework--Matthias Wessendorf
Zülpicher Wall 12, 23950674 Köln


Re: ajax ajax ajax

2005-09-19 Thread Matthias Wessendorf
:-)

On 9/19/05, Enrique Medina [EMAIL PROTECTED] wrote:
 Nice stuff. At least it seems less intrusive than the Ajax framework...
 
 2005/9/18, Matthias Wessendorf [EMAIL PROTECTED]:
  yet another ajax lib.
  
  AjaxAnywhere released on sourceforge via LGPL.
  
  http://ajaxanywhere.sourceforge.net/
  
  There is also a MyFaces sample, which shows some tomahawk components 
  with and without ajax.
  
  -Matthias
  
  On 8/15/05, Werner Punz [EMAIL PROTECTED] wrote:
   Just checked the wiki again, some russian guy posted
   links to his project 
   that stuff looks really interesting
  
   http://wiki.apache.org/myfaces/AJAX_Framework
  
  
  
  
  --
  Matthias Wessendorf
  Zülpicher Wall 12, 239
  50674 Köln
  
 
  


-- 
Matthias Wessendorf
Zülpicher Wall 12, 239
50674 Köln


Issue MYFACES-247 not resolved !

2005-09-19 Thread Nebojsa Vasiljevic
This is clarified issue scenario:

 

A h:dataTabe has no rows on first rendering. After post back, there are some 
rows. In this case h:actionLink in h:column will not trigger action.  

 

I have made an example to produce the issue. 

You can find important parts of the source at the end of this message,

or download full version from:

http://www.sw4i.com/download/myftest.zip

 

After you build and deploy example, go to: 
http://localhost:8080/myftest/numberList.jsf

Then enter some number.  If you click on -1 you will se You have selected 
-1, but if you click on 1 (or any other number), you will not see You have 
selected 1. So, the h:actionLink in h:column hasn't triggered action, but 
the other h:actionLink has trigger action.

 

After that, open com.sw4i.myftest.NumberListBean.java and change

private int limit = 0;

to

private int limit = 5;

 

After rebuild, go again to: http://localhost:8080/myftest/numberList.jsf and 
click on 1. Now you will see You have selected 1. Now both h:actionLink 
components have triggered action.

 

Unfortunately, this is very common practice: 

 

Put search criteria fields and result table on the same page and don't show any 
result first time user navigate to the page.

 

Regards,

Nebojsa


From NumberListBean.java :

com.sw4i.myftest;
// imports
public class NumberListBean { 
private int limit = 0;
private int selected = 0;

public ListInteger getNumbers() {
ListInteger numbers = new ArrayListInteger();
for(int i=1; i= limit; i++) {
numbers.add(i);
}
return numbers;
}
public String selectNumber() { 
Map parameters =  FacesContext.getCurrentInstance()
  .getExternalContext().getRequestParameterMap();
String parameter = (String) parameters.get(n);
if(parameter != null) {
   selected = Integer.parseInt(parameter);
}
return null;
}
// getters and setters for limit and selected
}

From numberList.jsp:

h:form
 Numbers from 1 to h:inputText value=#{numberListBean.limit}/
 h:commandButton value=show/
 brbr
 
 h:dataTable var=number value=#{numberListBean.numbers} 
h:column
h:outputText value=This is  /
h:commandLink action = #{numberListBean.selectNumber} 
value=#{number}
   f:param name=n value=#{number} /
/h:commandLink
/h:column
 /h:dataTable
 br
 
 Try 
 h:commandLink action = #{numberListBean.selectNumber} 
value=-1
   f:param name=n value=-1 /
 /h:commandLink
 /brbr
 
 h:panelGroup rendered=#{numberListBean.selected !=0}
h:outputText value=You have selected:  /
h:outputText  value=#{numberListBean.selected}/
 /h:panelGroup
/h:form






Re: commandLink with action inside Table

2005-09-19 Thread Christian Froelich
Hello,

I tried to save foo and only foo with x:saveState but it's
not working the action method is NOT CALLED.

now my jsp looks like that:

h:column id=columnBrowsTab1 rendered=#{foo.secondBoolean} 
   x:saveState id=foo value=#{foo}/

   h:commandLink action=#{listener.sort} 
   value=#{listener.browserHeadList[1]} 
   rendered=#{foo.obid == 'obid'}   
 f:param id=sortBy name=sortBy
 value=#{listener.browserHeadList[1]}/f:param
 f:param id=colNr name=colNr value='1'/f:param
   /h:commandLink   

   h:outputText  value=#{foo.secondColumn} 
   rendered=#{foo.obid != 'obid' and !(foo.obid == listener.obid)}/
   h:outputText  value=#{foo.secondColumn} 
   rendered=#{(foo.obid == listener.obid)}
   styleClass=treeNodeSelected/
/h:column

I would be glad if anyone could give me another hint!

Warm Regards,

Christian

-- 
Lust, ein paar Euro nebenbei zu verdienen? Ohne Kosten, ohne Risiko!
Satte Provisionen für GMX Partner: http://www.gmx.net/de/go/partner


ValueChangeListener another time...

2005-09-19 Thread Goyo Escobar Escalero
I want to develop a comboBox wich ge 2 arrayList, one for the labels and one for the values, that's ok, I do it with those methods...

public void encodeBegin(FacesContext context) throws IOException {ResponseWriter writer = context.getResponseWriter();char salto = '\n';
try {ArrayList lista = (ArrayList)getLista();ArrayList listaValores = new ArrayList();;if (lista != null) {listaValores = (ArrayList) this.getAttributes().get("listaValores");if (listaValores == null) {listaValores = lista;} else {if (listaValores.size() == 0) {listaValores = lista;}}}ArrayList list = new ArrayList();Application app = 
context.getApplication();HtmlSelectOneListbox comb = new HtmlSelectOneListbox();int i = 0;String valor = "";valor = (String) this.getAttributes().get("value");for (i = 0; i  lista.size(); i++) {UISelectItem sel = new UISelectItem();sel.setItemValue(listaValores.get(i));sel.setItemLabel((String) lista.get(i));String 
selected="selected";comb.getChildren().add(sel);}comb.setId(this.getId());comb.setSize(1);comb.setStyleClass("comboBox");comb.decode(context);try {renderChild(context, comb);} catch (IOException e) {e.printStackTrace();}
} catch (Exception e) {System.out.println(e);}
}
public static void renderChild(FacesContext facesContext, UIComponent child)throws IOException {if (!child.isRendered()) {return;}
child.encodeBegin(facesContext);if (child.getRendersChildren()) {child.encodeChildren(facesContext);} else {renderChildren(facesContext, child);}child.encodeEnd(facesContext);}
public static void renderChildren(FacesContext facesContext,UIComponent component) throws IOException {if (component.getChildCount()  0) {for (Iterator it = component.getChildren().iterator(); it.hasNext();) {UIComponent child = (UIComponent) it.next();renderChild(facesContext, child);}}}

Now I want to add it a valueChangeLisntener... but I'm unable to do it... for this I have the next method at the tag-class

protected void setProperties(UIComponent component) {super.setProperties(component);BDE_IAS_UICombo listaMenu=(BDE_IAS_UICombo) component;if (lista != null) {if (isValueReference(lista)) {ValueBinding vb =FacesContext.getCurrentInstance().getApplication().createValueBinding(lista);listaMenu.setValueBinding(BDE_IAS_UIComboBox.LISTA_VB, vb);} else {if(lista.length()==0){lista=null;}else{listaMenu.setLista(lista);}}}if (listaValores != null) 
{if (isValueReference(listaValores)) {ValueBinding vb =FacesContext.getCurrentInstance().getApplication().createValueBinding(listaValores);listaMenu.setValueBinding(BDE_IAS_UIComboBox.LISTAVALORES_VB, vb);} else {if(listaValores.length()!=0){listaMenu.setListaValores(listaValores);}else{if(lista!=null){if(lista.length()0){ValueBinding vb =FacesContext.getCurrentInstance().getApplication().createValueBinding(lista);listaMenu.setValueBinding(BDE_IAS_UIComboBox.LISTA_VB, 
vb);}
if (valueChangeListener != null) { if (isValueReference(valueChangeListener)) { FacesContext context = FacesContext.getCurrentInstance(); Application app = context.getApplication(); MethodBinding mb = app.createMethodBinding(valueChangeListener, new Class[] { ValueChangeEvent.class }); listaMenu.setValueChangeListener(mb); } }}

Debugging I'm sure taht the alue of the methodBinding is ok, but the methodisn't executed

WHATH HAVEI TO DO??? Please help me...;-)

One more thing, If I want to select one of the item by default, how can I implement it?? I would pass the component a value, whin matches with an itm of the list, and then it must be selected... is it possible??



Re: Issue MYFACES-247 not resolved !

2005-09-19 Thread Nebojsa Vasiljevic
Foget to mention, the platform is:

MyFaces 1.1.0
Sun JDK 1.5 on Windows XP
Tomat 5  (also tested on 5.5)

Ndebojsa
 
- Original Message - 
From: Nebojsa Vasiljevic [EMAIL PROTECTED]
To: users@myfaces.apache.org
Sent: Monday, September 19, 2005 1:11 PM
Subject: Issue MYFACES-247 not resolved !


This is clarified issue scenario:

[...]


RE: [ANN] [STRUTS/JSF] BOF XII / Belgo Central / Wednesday 28th S ept 2005 / 18:45

2005-09-19 Thread Pilgrim, Peter

*
P U S H E D  B A C K  ! 
*

The twelfth bird-of-feature Struts JSF London meet-up has been 
postponed for just eight days.

The event will now take place on Wednesday 28th September 2005,
at approximately 18:45. 

Same venue, same time. Bring a mate.


Thanks very much


--
Peter Pilgrim :: J2EE Software Development
Operations/IT - Credit Suisse First Boston, 
Floor 15, 5 Canada Square, London E14 4QJ, United Kingdom
Tel: +44-(0)207-883-4497


 -Original Message-
 From: Pilgrim, Peter [mailto:[EMAIL PROTECTED]
 Sent: 13 September 2005 17:11
 To: Struts User Apache (E-mail); MyFaces Discussion (E-mail)
 Subject: [ANN] [STRUTS/JSF] BOF XII / Belgo Central / Tuesday 
 20th Sept
 2005 / 18:45
 
 
 Greetings
 
 I am very pleased to announce that the ``Struts / JSF London Network''
 is meeting for the twelfth bird-of-feather discussions 
 
 This event will be taking place at the
 
 ``Belgo Central Restaurant'' at 6:45PM on Tuesday, 20th 
 September, 2005.
 
 
 50 Earlham Street, 
 Covent Garden, 
 London, 
 United Kingdom
 WC2H 9HP
   
 
 Nearest Tube: Covent Garden
 Cuisine: Belgian
 Telephone: 020 7813 2233 
 
 For an ajax Google Map click here
 http://www.london-eating.co.uk/maps/248.asp
 
 For the more traditional street map try this
 http://www.streetmap.co.uk/newmap.srf?x=530189y=181082z=0sv
=WC2H+9HPst=2pc=WC2H+9HPmapp=newmap.srfsearchp=newsearch.srf


(1) It's ok to bring a friend or colleague.
(2) My choice would have been china town.


--
Peter Pilgrim :: J2EE Software Development
Operations/IT - Credit Suisse First Boston, 
Floor 15, 5 Canada Square, London E14 4QJ, United Kingdom
Tel: +44-(0)207-883-4497

==
Please access the attached hyperlink for an important electronic communications 
disclaimer: 

http://www.csfb.com/legal_terms/disclaimer_external_email.shtml

==


==
Please access the attached hyperlink for an important electronic communications 
disclaimer: 

http://www.csfb.com/legal_terms/disclaimer_external_email.shtml

==



Re: commandLink with action inside Table

2005-09-19 Thread Mathias Brökelmann
You can not put x:savestate inside a column. The state of the nested
columns components is not saved for each row.

2005/9/19, Christian Froelich [EMAIL PROTECTED]:
 Hello,
 
 I tried to save foo and only foo with x:saveState but it's
 not working the action method is NOT CALLED.
 
 now my jsp looks like that:
 
 h:column id=columnBrowsTab1 rendered=#{foo.secondBoolean}
x:saveState id=foo value=#{foo}/
 
h:commandLink action=#{listener.sort}
value=#{listener.browserHeadList[1]}
rendered=#{foo.obid == 'obid'} 
  f:param id=sortBy name=sortBy
  value=#{listener.browserHeadList[1]}/f:param
  f:param id=colNr name=colNr value='1'/f:param
/h:commandLink
 
h:outputText  value=#{foo.secondColumn}
rendered=#{foo.obid != 'obid' and !(foo.obid == listener.obid)}/
h:outputText  value=#{foo.secondColumn}
rendered=#{(foo.obid == listener.obid)}
styleClass=treeNodeSelected/
 /h:column
 
 I would be glad if anyone could give me another hint!
 
 Warm Regards,
 
 Christian
 
 --
 Lust, ein paar Euro nebenbei zu verdienen? Ohne Kosten, ohne Risiko!
 Satte Provisionen für GMX Partner: http://www.gmx.net/de/go/partner
 


-- 
Mathias


Re: Issue MYFACES-247 not resolved !

2005-09-19 Thread Mathias Brökelmann
That´s an easy one ;)

Try to put your numberListBean into session scope or put it into a
x:savestate component or use preserveDataModel=true of x:datatable

Otherwise the state of your bean will not be saved between the
requests. Each request creates a new instance with limit=0. The method
getNumbers() is called in the decode phase to determine the row data.
If the returned list is empty the table decoder can not iterate
through the rows and will not fire any events.

Take a look into other threads like commandLink with action inside
Table for some more info.

2005/9/19, Nebojsa Vasiljevic [EMAIL PROTECTED]:
 Foget to mention, the platform is:
 
 MyFaces 1.1.0
 Sun JDK 1.5 on Windows XP
 Tomat 5  (also tested on 5.5)
 
 Ndebojsa
 
 - Original Message -
 From: Nebojsa Vasiljevic [EMAIL PROTECTED]
 To: users@myfaces.apache.org
 Sent: Monday, September 19, 2005 1:11 PM
 Subject: Issue MYFACES-247 not resolved !
 
 
 This is clarified issue scenario:
 
 [...]
 


-- 
Mathias


Re: Issue MYFACES-247 not resolved !

2005-09-19 Thread Nebojsa Vasiljevic
Your discussion went to wrong direction.

The problem is: 

The action is not triggered. View is not constructed properly.

I don't need to save anything. If getNumbers() method returns non-empty list 
fist time, then
the example works fine after that. If getNumbers() method returns empty list 
first time, then action attribute is not set properly in the commandLink 
component. Broken component tree is saved in client or session. So, the problem 
is about something that IS saved.

The example is based on standard JSF and should work fine in a proper 
implementation.
This is serious MyFaces bug.

Nebojsa

- Original Message - 
From: Mathias Brökelmann [EMAIL PROTECTED]
To: MyFaces Discussion users@myfaces.apache.org
Sent: Monday, September 19, 2005 1:48 PM
Subject: Re: Issue MYFACES-247 not resolved !


That´s an easy one ;)

Try to put your numberListBean into session scope or put it into a
x:savestate component or use preserveDataModel=true of x:datatable

Otherwise the state of your bean will not be saved between the
requests. Each request creates a new instance with limit=0. The method
getNumbers() is called in the decode phase to determine the row data.
If the returned list is empty the table decoder can not iterate
through the rows and will not fire any events.

Take a look into other threads like commandLink with action inside
Table for some more info.

2005/9/19, Nebojsa Vasiljevic [EMAIL PROTECTED]:
 Foget to mention, the platform is:
 
 MyFaces 1.1.0
 Sun JDK 1.5 on Windows XP
 Tomat 5  (also tested on 5.5)
 
 Ndebojsa
 
 - Original Message -
 From: Nebojsa Vasiljevic [EMAIL PROTECTED]
 To: users@myfaces.apache.org
 Sent: Monday, September 19, 2005 1:11 PM
 Subject: Issue MYFACES-247 not resolved !
 
 
 This is clarified issue scenario:
 
 [...]
 


-- 
Mathias



auto scroll

2005-09-19 Thread ir. ing. Jan Dockx
Probably not, but to be sure:

Is there any way known to mankind to have the JavaScript for
context-param>
param-name>org.apache.myfaces.AUTO_SCROLL/param-name>
param-value>true/param-value>
/context-param>
only in some pages, and not in others?

It probably only makes sense if the output type is text/html (and does hinder for our generated AJAX response files, SYLK files, and generated JS files).


x-tad-smallerMet vriendelijke groeten,

Jan Dockx
/x-tad-smallerx-tad-smaller
PeopleWare NV - Head Office/x-tad-smallerx-tad-smaller
Cdt.Weynsstraat 85 
B-2660 Hoboken 
Tel: +32 3 448.33.38 
Fax: +32 3 448.32.66 /x-tad-smallerx-tad-bigger
/x-tad-biggerx-tad-smaller
PeopleWare NV - Branch Office Geel/x-tad-smallerx-tad-smaller
Kleinhoefstraat 5
B-2440 Geel
Tel: +32 14 57.00.90
Fax: +32 14 58.13.25/x-tad-smallerx-tad-bigger
/x-tad-biggerx-tad-smaller
http://www.peopleware.be/
/x-tad-smallerx-tad-smallerhttp://www.mobileware.be//x-tad-smaller

smime.p7s
Description: S/MIME cryptographic signature


Re: Issue MYFACES-247 not resolved !

2005-09-19 Thread Bruno Aranda
Does it work with the RI?

Bruno

2005/9/19, Nebojsa Vasiljevic [EMAIL PROTECTED]:
 Your discussion went to wrong direction.
 
 The problem is:
 
 The action is not triggered. View is not constructed properly.
 
 I don't need to save anything. If getNumbers() method returns non-empty list 
 fist time, then
 the example works fine after that. If getNumbers() method returns empty list 
 first time, then action attribute is not set properly in the commandLink 
 component. Broken component tree is saved in client or session. So, the 
 problem is about something that IS saved.
 
 The example is based on standard JSF and should work fine in a proper 
 implementation.
 This is serious MyFaces bug.
 
 Nebojsa
 
 - Original Message -
 From: Mathias Brökelmann [EMAIL PROTECTED]
 To: MyFaces Discussion users@myfaces.apache.org
 Sent: Monday, September 19, 2005 1:48 PM
 Subject: Re: Issue MYFACES-247 not resolved !
 
 
 That´s an easy one ;)
 
 Try to put your numberListBean into session scope or put it into a
 x:savestate component or use preserveDataModel=true of x:datatable
 
 Otherwise the state of your bean will not be saved between the
 requests. Each request creates a new instance with limit=0. The method
 getNumbers() is called in the decode phase to determine the row data.
 If the returned list is empty the table decoder can not iterate
 through the rows and will not fire any events.
 
 Take a look into other threads like commandLink with action inside
 Table for some more info.
 
 2005/9/19, Nebojsa Vasiljevic [EMAIL PROTECTED]:
  Foget to mention, the platform is:
 
  MyFaces 1.1.0
  Sun JDK 1.5 on Windows XP
  Tomat 5  (also tested on 5.5)
 
  Ndebojsa
 
  - Original Message -
  From: Nebojsa Vasiljevic [EMAIL PROTECTED]
  To: users@myfaces.apache.org
  Sent: Monday, September 19, 2005 1:11 PM
  Subject: Issue MYFACES-247 not resolved !
 
 
  This is clarified issue scenario:
 
  [...]
 
 
 
 --
 Mathias
 



Re: New ANNOUNCEMENT mailing list

2005-09-19 Thread ssobot
im glad to read that. 
fow a few months im leaving JSF pojects (became SWT dev.;), but i'd
like to be informed about the great stuff u guys are doing...

btw: i'm trying to unsubscribe from this list by sending mail at:
[EMAIL PROTECTED], but i keep receiving error
messages? 
whats wrong? 
do u guys have not enough people here and u dont want to let me out?;)

it was great to be able to participate (a little;) in this comunity.
thanks!

cheers

Sławek




 Hi *,
 
 a new announcement mailing list has been created - subscribe to this
 list to receive announcements about Apache MyFaces in a low traffic
 way.
 
 Subscription is done by sending mail to:
 
 announce-subscribe.at.myfaces.apache.org
 
 regards,
 
 Martin
 



Re: New ANNOUNCEMENT mailing list

2005-09-19 Thread Bruno Aranda
it should work that address... are you doing it from the address you
subscribed? Maybe you should try later...

Anyway, thanks for all your help and finding of issues during this
time. Hope to see you soon here again. Regards,

Bruno

2005/9/19, [EMAIL PROTECTED] [EMAIL PROTECTED]:
 im glad to read that.
 fow a few months im leaving JSF pojects (became SWT dev.;), but i'd
 like to be informed about the great stuff u guys are doing...
 
 btw: i'm trying to unsubscribe from this list by sending mail at:
 [EMAIL PROTECTED], but i keep receiving error
 messages?
 whats wrong?
 do u guys have not enough people here and u dont want to let me out?;)
 
 it was great to be able to participate (a little;) in this comunity.
 thanks!
 
 cheers
 
 Sławek
 
 
 
 
  Hi *,
 
  a new announcement mailing list has been created - subscribe to this
  list to receive announcements about Apache MyFaces in a low traffic
  way.
 
  Subscription is done by sending mail to:
 
  announce-subscribe.at.myfaces.apache.org
 
  regards,
 
  Martin
 
 



Re: Issue MYFACES-247 not resolved !

2005-09-19 Thread Mathias Brökelmann
Your datamodel *will not* be saved between request. That´s not a bug
in myfaces it is specified in the spec. Try using the RI with your
example and you will see the same problem. You have to restore the
value of limit to recreate the datamodel.

You can not do it through the input field because the value may have
been changed between the requests and will not update your limit value
before the decode phase (you could use immediate for the input field
but if the value changes from 1 to 0 no events will be fired again.)

Please try out my suggested changes like using x:savestate
value=#{numberListBean.limit} this will restore the value of limit
in the restore phase before the decode phase. You can also put a
breakpoint in your getNumbers() method to see when it will be called
(take a look into the stacktrace of the stopped thread).

2005/9/19, Nebojsa Vasiljevic [EMAIL PROTECTED]:
 Your discussion went to wrong direction.

 The problem is:

 The action is not triggered. View is not constructed properly.

 I don't need to save anything. If getNumbers() method returns non-empty list 
 fist time, then
 the example works fine after that. If getNumbers() method returns empty list 
 first time, then action attribute is not set properly in the commandLink 
 component. Broken component tree is saved in client or session. So, the 
 problem is about something that IS saved.

 The example is based on standard JSF and should work fine in a proper 
 implementation.
 This is serious MyFaces bug.

 Nebojsa

 - Original Message -
 From: Mathias Brökelmann [EMAIL PROTECTED]
 To: MyFaces Discussion users@myfaces.apache.org
 Sent: Monday, September 19, 2005 1:48 PM
 Subject: Re: Issue MYFACES-247 not resolved !


 That´s an easy one ;)

 Try to put your numberListBean into session scope or put it into a
 x:savestate component or use preserveDataModel=true of x:datatable

 Otherwise the state of your bean will not be saved between the
 requests. Each request creates a new instance with limit=0. The method
 getNumbers() is called in the decode phase to determine the row data.
 If the returned list is empty the table decoder can not iterate
 through the rows and will not fire any events.

 Take a look into other threads like commandLink with action inside
 Table for some more info.

 2005/9/19, Nebojsa Vasiljevic [EMAIL PROTECTED]:
  Foget to mention, the platform is:
 
  MyFaces 1.1.0
  Sun JDK 1.5 on Windows XP
  Tomat 5  (also tested on 5.5)
 
  Ndebojsa
 
  - Original Message -
  From: Nebojsa Vasiljevic [EMAIL PROTECTED]
  To: users@myfaces.apache.org
  Sent: Monday, September 19, 2005 1:11 PM
  Subject: Issue MYFACES-247 not resolved !
 
 
  This is clarified issue scenario:
 
  [...]
 


 --
 Mathias


-- 
Mathias


Re: Tiles and JSF Wiki entry

2005-09-19 Thread Rick Reumann
Awesome. Thanks Robert.

( By the way the above URL is really http://wiki.apache.org/myfaces/Tiles_and_JSF )On 9/18/05, 
Robert Taylor [EMAIL PROTECTED] wrote:
It was recommended by a few users that a wiki entry be created for myrecent adventures in learning how to use Tiles with MyFaces. See thethread subject [newbie] Forward to launch page if you want all the
gory details. You can find the wiki entry here:http://wiki.apache.org/myfaces/Tiles_and_JSF%2eIt's my first wiki entry, so if you find some mistakes or ways to
improve it, feel free to jump right in or let me know.Thanks again for all who helped me and I hope this helps others./robert-- Rick


Re: t:columns How to render different UI for each column

2005-09-19 Thread Mike Kienenberger
Is there a reason you can't use

h:panelGroup*
h:selectBooleanCheckbox rendered=if boolean
h:selectOneMenu rendered=if not boolean
/h:panelGroup*

* Actually, the panelGroup might be optional as well.

On 9/16/05, Dave [EMAIL PROTECTED] wrote:
 Some column is boolean type, need a h:selectBooleanCheckbox 
 some column is choice, need a h:selectOneMenu 
   
 The openDataTable.jsp example uses a flag to render h:inputText or
 h:outputText. 
 but what is the way to render different UIcomponent for each column? Thanks.
  
 
 t:columns id=columns value=#{openDataList.columnHeaders}
 var=columnHeader style=width:#{openDataList.columnWidth}px 
 
 f:facet name=header 
 
 t:commandSortHeader columnName=#{columnHeader.label} arrow=false
 immediate=false 
 
 f:facet name=ascending 
 
 t:graphicImage value=images/ascending-arrow.gif rendered=true
 border=0/ 
 
 /f:facet 
 
 f:facet name=descending 
 
 t:graphicImage value=images/descending-arrow.gif rendered=true
 border=0/ 
 
 /f:facet 
 
 h:outputText value=#{columnHeader.label} / 
 
 /t:commandSortHeader 
 
 /f:facet 
 
 !-- row is also available -- 
 
 h:inputText rendered=#{openDataList.valueModifiable}
 value=#{openDataList.columnValue} / 
 
 h:outputText rendered=#{!openDataList.valueModifiable}
 value=#{openDataList.columnValue} / 
 
 /t:columns
 
  
 Yahoo! for Good
  Click here to donate to the Hurricane Katrina relief effort. 
 



Re: commandLink with action inside Table

2005-09-19 Thread Mike Kienenberger
Conceptionally, it probably makes the most sense to stick your
x:saveState components at the top, right after your f:view.   It
doesn't really matter where you put them, but the state always gets
restored in the restore view phase and this always happens before the
apply value phase (where all of the values get assigned from your
other components get assigned).  The ordering of your x:saveState
components won't affect anything but your other x:saveState
components.

On 9/19/05, Mathias Brökelmann [EMAIL PROTECTED] wrote:
 You can not put x:savestate inside a column. The state of the nested
 columns components is not saved for each row.
 
 2005/9/19, Christian Froelich [EMAIL PROTECTED]:
  Hello,
 
  I tried to save foo and only foo with x:saveState but it's
  not working the action method is NOT CALLED.
 
  now my jsp looks like that:
 
  h:column id=columnBrowsTab1 rendered=#{foo.secondBoolean}
 x:saveState id=foo value=#{foo}/
 
 h:commandLink action=#{listener.sort}
 value=#{listener.browserHeadList[1]}
 rendered=#{foo.obid == 'obid'} 
   f:param id=sortBy name=sortBy
   value=#{listener.browserHeadList[1]}/f:param
   f:param id=colNr name=colNr value='1'/f:param
 /h:commandLink
 
 h:outputText  value=#{foo.secondColumn}
 rendered=#{foo.obid != 'obid' and !(foo.obid == listener.obid)}/
 h:outputText  value=#{foo.secondColumn}
 rendered=#{(foo.obid == listener.obid)}
 styleClass=treeNodeSelected/
  /h:column
 
  I would be glad if anyone could give me another hint!
 
  Warm Regards,
 
  Christian
 
  --
  Lust, ein paar Euro nebenbei zu verdienen? Ohne Kosten, ohne Risiko!
  Satte Provisionen für GMX Partner: http://www.gmx.net/de/go/partner
 
 
 
 --
 Mathias



Re: Tiles and JSF Wiki entry

2005-09-19 Thread Werner Punz

Superb entry, wonderful stuff

Werner


Robert Taylor wrote:
It was recommended by a few users that a wiki entry be created for my 
recent adventures in learning how to use Tiles with MyFaces. See the
thread subject [newbie] Forward to launch page if you want all the 
gory details. You can find the wiki entry here:


http://wiki.apache.org/myfaces/Tiles_and_JSF%2e

It's my first wiki entry, so if you find some mistakes or ways to 
improve it, feel free to jump right in or let me know.


Thanks again for all who helped me and I hope this helps others.


/robert







Re: Issue MYFACES-247 not resolved !

2005-09-19 Thread Nebojsa Vasiljevic
I tried RI and behavior is the same as with MyFasces.

I have put numberListBean in session scope and example wors fine (with RI, but
I expect same behavior with MyFaces).

I have checked and getNumbers() is not called in the critical scenario.

As I can see, method getNumbers() is called two times per request. Firt time in 
applyRequestValues phase, and seccond time in renderResponse phase. 

MyFaces have to assign the current row variable  (var attribute of dataTable 
tag) before it triger action, but it can't. That's why action is not called.  

Why not call action, just skip setting the current row variable?  
Sometimes action does not depend on the current row, but on parameter, like in 
example.

In any case MyFaces should write some worning in log.

For similar cases I suggest:

- read the parameter in constructor and write it to property. Use the same 
property in a field (hidden or not).
- in getter for dataTable attribute read property and make list, but be 
carefull not to do complex calculation twice if property is not changed.

Nebojsa


- Original Message - 
From: Mathias Brökelmann [EMAIL PROTECTED]
To: MyFaces Discussion users@myfaces.apache.org
Sent: Monday, September 19, 2005 3:51 PM
Subject: Re: Issue MYFACES-247 not resolved !


Your datamodel *will not* be saved between request. That´s not a bug
in myfaces it is specified in the spec. Try using the RI with your
example and you will see the same problem. You have to restore the
value of limit to recreate the datamodel.

You can not do it through the input field because the value may have
been changed between the requests and will not update your limit value
before the decode phase (you could use immediate for the input field
but if the value changes from 1 to 0 no events will be fired again.)

Please try out my suggested changes like using x:savestate
value=#{numberListBean.limit} this will restore the value of limit
in the restore phase before the decode phase. You can also put a
breakpoint in your getNumbers() method to see when it will be called
(take a look into the stacktrace of the stopped thread).

2005/9/19, Nebojsa Vasiljevic [EMAIL PROTECTED]:
 Your discussion went to wrong direction.

 The problem is:

 The action is not triggered. View is not constructed properly.

 I don't need to save anything. If getNumbers() method returns non-empty list 
 fist time, then
 the example works fine after that. If getNumbers() method returns empty list 
 first time, then action attribute is not set properly in the commandLink 
 component. Broken component tree is saved in client or session. So, the 
 problem is about something that IS saved.

 The example is based on standard JSF and should work fine in a proper 
 implementation.
 This is serious MyFaces bug.

 Nebojsa

 - Original Message -
 From: Mathias Brökelmann [EMAIL PROTECTED]
 To: MyFaces Discussion users@myfaces.apache.org
 Sent: Monday, September 19, 2005 1:48 PM
 Subject: Re: Issue MYFACES-247 not resolved !


 That´s an easy one ;)

 Try to put your numberListBean into session scope or put it into a
 x:savestate component or use preserveDataModel=true of x:datatable

 Otherwise the state of your bean will not be saved between the
 requests. Each request creates a new instance with limit=0. The method
 getNumbers() is called in the decode phase to determine the row data.
 If the returned list is empty the table decoder can not iterate
 through the rows and will not fire any events.

 Take a look into other threads like commandLink with action inside
 Table for some more info.

 2005/9/19, Nebojsa Vasiljevic [EMAIL PROTECTED]:
  Foget to mention, the platform is:
 
  MyFaces 1.1.0
  Sun JDK 1.5 on Windows XP
  Tomat 5  (also tested on 5.5)
 
  Ndebojsa
 
  - Original Message -
  From: Nebojsa Vasiljevic [EMAIL PROTECTED]
  To: users@myfaces.apache.org
  Sent: Monday, September 19, 2005 1:11 PM
  Subject: Issue MYFACES-247 not resolved !
 
 
  This is clarified issue scenario:
 
  [...]
 


 --
 Mathias


-- 
Mathias



Re: Custom ViewManager to avoid save/restore state

2005-09-19 Thread Ihab Awad

Hi again, folks,

On Sep 14, 2005, at 11:32, Ihab Awad wrote:
... I tried overriding ViewHandler methods renderView and  
restoreView to *not* call the state saving mechanism. The result is  
that I can run my app without UIComponent methods processSaveState  
or processRestoreState ever being called, which is what I want. ...  
Hence my question: do you folks see any problems with this approach?


Nobody replied yet, so I thought I'd add some more details of my  
code. Below are selected portions of my ViewHandler. This is based on  
the example from Hans Bergsten's JSF book. Again, any comments re  
this approach, especially regarding portability or possible problems  
with future JSF implementations, would be appreciated. Peace, -- Ihab


public class CustomViewHandler extends ViewHandler {

private static final String SMD_VIEW_ID = /smdMainView;

private final ViewHandler origViewHandler;
private final MapString, UIViewRoot smdViews = new  
HashMapString, UIViewRoot();


public CustomViewHandler(ViewHandler origViewHandler) {
this.origViewHandler = origViewHandler;
}

public UIViewRoot createView(FacesContext context, String viewId) {
if (isSMDView(viewId)) {
UIViewRoot view = customCreateView(context, viewId);
smdViews.put(viewId, view);
return view;
} else {
return origViewHandler.createView(context, viewId);
}
}

public void renderView(FacesContext context, UIViewRoot  
viewToRender)

throws IOException
{
if (isSMDView(viewToRender)) {
setupResponseWriter(context);
/ NOTE NO STATE SAVING /
context.getResponseWriter().startDocument();
renderResponse(context, viewToRender);
context.getResponseWriter().endDocument();
} else {
origViewHandler.renderView(context, viewToRender);
}
}

public UIViewRoot restoreView(FacesContext context, String  
viewId) {

if (isSMDView(viewId)) {
/ NOTE NO STATE RESTORATION /
return smdViews.get(viewId);
} else {
return origViewHandler.restoreView(context, viewId);
}
}

private boolean isSMDView(String viewId) {
return viewId.startsWith(SMD_VIEW_ID);
}

private boolean isSMDView(UIViewRoot view) {
return isSMDView(view.getViewId());
}

private UIViewRoot customCreateView(FacesContext context, String  
viewId) {


UIViewRoot result = new UIViewRoot();

result.setViewId(viewId);
result.setRenderKitId(calculateRenderKitId(context));
result.setLocale(calculateLocale(context));

/ NOTE CREATING INSTANCE OF MY OWN CLASS /
SMDRootViewPanel rootViewPanel = new SMDRootViewPanel();
rootViewPanel.initialize();
result.getChildren().add(rootViewPanel);

return result;
}

}




Re: Custom ViewManager to avoid save/restore state

2005-09-19 Thread Mike Kienenberger
Is there a reason you used a custom ViewHandler instead of a custom
StateManager?
It seems like that's the expected place to change state management
behavior, and it might be more portable across different ViewHandler
implementations.

On 9/19/05, Ihab Awad [EMAIL PROTECTED] wrote:
 Hi again, folks,
 
 On Sep 14, 2005, at 11:32, Ihab Awad wrote:
  ... I tried overriding ViewHandler methods renderView and
  restoreView to *not* call the state saving mechanism. The result is
  that I can run my app without UIComponent methods processSaveState
  or processRestoreState ever being called, which is what I want. ...
  Hence my question: do you folks see any problems with this approach?
 
 Nobody replied yet, so I thought I'd add some more details of my
 code. Below are selected portions of my ViewHandler. This is based on
 the example from Hans Bergsten's JSF book. Again, any comments re
 this approach, especially regarding portability or possible problems
 with future JSF implementations, would be appreciated. Peace, -- Ihab
 
 public class CustomViewHandler extends ViewHandler {
 
  private static final String SMD_VIEW_ID = /smdMainView;
 
  private final ViewHandler origViewHandler;
  private final MapString, UIViewRoot smdViews = new
 HashMapString, UIViewRoot();
 
  public CustomViewHandler(ViewHandler origViewHandler) {
  this.origViewHandler = origViewHandler;
  }
 
  public UIViewRoot createView(FacesContext context, String viewId) {
  if (isSMDView(viewId)) {
  UIViewRoot view = customCreateView(context, viewId);
  smdViews.put(viewId, view);
  return view;
  } else {
  return origViewHandler.createView(context, viewId);
  }
  }
 
  public void renderView(FacesContext context, UIViewRoot
 viewToRender)
  throws IOException
  {
  if (isSMDView(viewToRender)) {
  setupResponseWriter(context);
  / NOTE NO STATE SAVING /
  context.getResponseWriter().startDocument();
  renderResponse(context, viewToRender);
  context.getResponseWriter().endDocument();
  } else {
  origViewHandler.renderView(context, viewToRender);
  }
  }
 
  public UIViewRoot restoreView(FacesContext context, String
 viewId) {
  if (isSMDView(viewId)) {
  / NOTE NO STATE RESTORATION /
  return smdViews.get(viewId);
  } else {
  return origViewHandler.restoreView(context, viewId);
  }
  }
 
  private boolean isSMDView(String viewId) {
  return viewId.startsWith(SMD_VIEW_ID);
  }
 
  private boolean isSMDView(UIViewRoot view) {
  return isSMDView(view.getViewId());
  }
 
  private UIViewRoot customCreateView(FacesContext context, String
 viewId) {
 
  UIViewRoot result = new UIViewRoot();
 
  result.setViewId(viewId);
  result.setRenderKitId(calculateRenderKitId(context));
  result.setLocale(calculateLocale(context));
 
  / NOTE CREATING INSTANCE OF MY OWN CLASS /
  SMDRootViewPanel rootViewPanel = new SMDRootViewPanel();
  rootViewPanel.initialize();
  result.getChildren().add(rootViewPanel);
 
  return result;
  }
 
 }
 
 



RE: jscookmenu problem

2005-09-19 Thread Deepinder Singh
 Greg,
Can you now click on the links of JSCookMenu. If so can you please
let us know what you changed or what was missing earlier.
Thanks,
deepinder

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, September 14, 2005 12:05 PM
To: users@myfaces.apache.org
Subject: RE: jscookmenu problem

1.
I'm looking into that too and currently trying to figure out why, unless
I include the js and css files in my page, it does not work. One way I
was able to see it (but not click on any links...) was to use TheOffice
for example, and in my page that uses the t:jscookmenu, add the
following:

script type=text/javascript src=jscookmenu/JSCookMenu.js/script
link rel=stylesheet href=jscookmenu/ThemeOffice/theme.css
type=text/css /
script type=text/javascript
src=jscookmenu/ThemeOffice/theme.js/script

In the head section. Of course you'll need the files in there... I
found them in
myFaces-srcsrc\components\org\apache\myfaces\custom\navmenu\resource

But that's not the way it is supposed to work I believe...

2.
Haven't tried this one yet.

3.
I was able to get that one running fine. Maybe you can tell us how
you're trying to implement this?

Regards,

Greg

-Original Message-
From: Deepinder Singh [mailto:[EMAIL PROTECTED]
Sent: Wednesday, September 14, 2005 2:58 PM
To: MyFaces Discussion
Subject: RE: jscookmenu problem

 I am still learning how to use these comps. Some of the problems I am
seeing are:- 1. Unbale to see the JSCookMenu on my page.
2. The table option is always visibile with the HTML Editor.
3. The scroller works fine, however I see crashes when I integrate with
the sorter.

I am using 1.0.9 version. Is anyone else having these problems?
Thanks,
deepinder



___
Siebel
IT'S ALL ABOUT THE CUSTOMER
Visit www.siebel.com

This e-mail message is for the sole use of the intended recipient(s) and 
contains confidential and/or privileged information belonging to Siebel 
Systems, Inc. or its customers or partners. Any unauthorized review, use, 
copying, disclosure or distribution of this message is strictly prohibited. If 
you are not an intended recipient of this message, please contact the sender by 
reply e-mail and destroy all soft and hard copies of the message and any 
attachments. Thank you for your cooperation.



Highlighting a specifc row in a datatable

2005-09-19 Thread Emmanuel Jay
Hi,

Is it possible to highlight a specifc row in a datatable?

I have tried the following but it doesn't work

dataTable.setValueBinding(rowClasses, createValueBinding(#{(myvar.highlight) ? 'style1' : 'style2'}));

Thanks,

Emmanuel



RE: jscookmenu problem

2005-09-19 Thread gvial
Hi,

Alright I'm gonna try to go through the steps I followed (to make it
from scratch, not from a weird situation like I was at the other day).

1) Install MyFaces the usual way
2) In your application, make sure your web.xml contains extra properties
for extensions filters like the following:

  filter
filter-nameextensionsFilter/filter-name
 
filter-classorg.apache.myfaces.component.html.util.ExtensionsFilter/f
ilter-class
init-param
  param-nameuploadMaxFileSize/param-name
  param-value10m/param-value
/init-param
init-param
  param-nameuploadThresholdSize/param-name
  param-value100k/param-value
/init-param
  /filter
  filter-mapping
filter-nameextensionsFilter/filter-name
url-pattern*.faces/url-pattern
  /filter-mapping

Note here that the url-pattern *.faces has to correspond to the
url-pattern of your servlet mapping, as in:

  servlet-mapping
servlet-nameFaces Servlet/servlet-name
url-pattern*.faces/url-pattern
  /servlet-mapping

This was my problem, the examples were using *.jsf but I was using
*.faces for my extensions and I had just done copy/paste without paying
attention to this...

3) In the page where you want to use the jsCookMenu, you should now be
able to use the following:

t:jscookMenu layout=hbr theme=ThemeOffice
t:navigationMenuItem id=users
itemLabel=#{bundle['menu.users']} action=#{bean.test} /
/t:jscookMenu

Note: Using this technique you are using built-in themes within the
component. Hence you do not need to include any css or js files that
belong to the jsCookMenu component specifically in your page. These will
be added at run time for you.

Check the documentation for the layouts and themes available. As far as
I'm concerned this worked for me. Let us know if you're still stuck, and
let us know where you are stuck exactly if you're still experiencing
problems.

Hope this helps,

Greg


-Original Message-
From: Deepinder Singh [mailto:[EMAIL PROTECTED] 
Sent: Monday, September 19, 2005 2:54 PM
To: MyFaces Discussion
Subject: RE: jscookmenu problem

 Greg,
Can you now click on the links of JSCookMenu. If so can you please
let us know what you changed or what was missing earlier.
Thanks,
deepinder

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, September 14, 2005 12:05 PM
To: users@myfaces.apache.org
Subject: RE: jscookmenu problem

1.
I'm looking into that too and currently trying to figure out why, unless
I include the js and css files in my page, it does not work. One way I
was able to see it (but not click on any links...) was to use TheOffice
for example, and in my page that uses the t:jscookmenu, add the
following:

script type=text/javascript src=jscookmenu/JSCookMenu.js/script
link rel=stylesheet href=jscookmenu/ThemeOffice/theme.css
type=text/css /
script type=text/javascript
src=jscookmenu/ThemeOffice/theme.js/script

In the head section. Of course you'll need the files in there... I
found them in
myFaces-srcsrc\components\org\apache\myfaces\custom\navmenu\resource

But that's not the way it is supposed to work I believe...

2.
Haven't tried this one yet.

3.
I was able to get that one running fine. Maybe you can tell us how
you're trying to implement this?

Regards,

Greg

-Original Message-
From: Deepinder Singh [mailto:[EMAIL PROTECTED]
Sent: Wednesday, September 14, 2005 2:58 PM
To: MyFaces Discussion
Subject: RE: jscookmenu problem

 I am still learning how to use these comps. Some of the problems I am
seeing are:- 1. Unbale to see the JSCookMenu on my page.
2. The table option is always visibile with the HTML Editor.
3. The scroller works fine, however I see crashes when I integrate with
the sorter.

I am using 1.0.9 version. Is anyone else having these problems?
Thanks,
deepinder



___
Siebel
IT'S ALL ABOUT THE CUSTOMER
Visit www.siebel.com

This e-mail message is for the sole use of the intended recipient(s) and
contains confidential and/or privileged information belonging to Siebel
Systems, Inc. or its customers or partners. Any unauthorized review,
use, copying, disclosure or distribution of this message is strictly
prohibited. If you are not an intended recipient of this message, please
contact the sender by reply e-mail and destroy all soft and hard copies
of the message and any attachments. Thank you for your cooperation.



Getting the sandbox components

2005-09-19 Thread gvial
Hi,

I was wondering if there was any place to download the sandbox components for 
myfaces. I want to take a look at the AjaxInputSuggest one ☺.

Thanks,

Greg


RE: jscookmenu problem

2005-09-19 Thread Dave
Has anyone figured out how to remove the missing icons (red X) from the menu items? I am using nightly build 9/12. Thanks[EMAIL PROTECTED] wrote:
Hi,Alright I'm gonna try to go through the steps I followed (to make itfrom scratch, not from a weird situation like I was at the other day).1) Install MyFaces the usual way2) In your application, make sure your web.xml contains extra propertiesfor extensions filters like the following:extensionsFilterorg.apache.myfaces.component.html.util.ExtensionsFilterilter-classuploadMaxFileSize10muploadThresholdSize100kextensionsFilter*.facesNote here that the url-pattern *.fac
 es has
 to correspond to theurl-pattern of your servlet mapping, as in:Faces Servlet*.facesThis was my problem, the examples were using *.jsf but I was using*.faces for my extensions and I had just done copy/paste without payingattention to this...3) In the page where you want to use the jsCookMenu, you should now beable to use the following:itemLabel="#{bundle['menu.users']}" action="" /Note: Using this technique you are using built-in themes within thecomponent. Hence you do not need to include any css or js files thatbelong to the jsCookMenu component specifically in your page. These willbe added at run time for you.Check the documentation for the layouts a
 nd
 themes available. As far asI'm concerned this worked for me. Let us know if you're still stuck, andlet us know where you are stuck exactly if you're still experiencingproblems.Hope this helps,Greg-Original Message-From: Deepinder Singh [mailto:[EMAIL PROTECTED] Sent: Monday, September 19, 2005 2:54 PMTo: MyFaces DiscussionSubject: RE: jscookmenu problemGreg,Can you now click on the links of JSCookMenu. If so can you pleaselet us know what you changed or what was missing earlier.Thanks,deepinder-Original Message-From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Wednesday, September 14, 2005 12:05 PMTo: users@myfaces.apache.orgSubject: RE: jscookmenu problem1.I'm looking into that too and currently trying to figure out why, unlessI include the js and css files in my page, it does not work. One way Iwas able to see it (but 
 not
 click on any links...) was to use TheOfficefor example, and in my page that uses the , add thefollowing:

type="text/css" /

In the section. Of course you'll need the files in there... Ifound them insrc\components\org\apache\myfaces\custom\navmenu\resourceBut that's not the way it is supposed to work I believe...2.Haven't tried this one yet.3.I was able to get that one running fine. Maybe you can tell us howyou're trying to implement this?Regards,Greg-Original Message-From: Deepinder Singh [mailto:[EMAIL PROTECTED]Sent: Wednesday, September 14, 2005 2:58 PMTo: MyFaces DiscussionSubject: RE: jscookmenu problemI am still learning how to use these comps. Some of the problems I amseeing are:- 1. Unbale to see the JSCookMenu on my page.2. The table option is always visibile with the HTML Editor.3. The scroller works fine, however I see crashes when I integrate withthe sorter.I am using 1.0.9 version. Is anyone else having these
 problems?Thanks,deepinder___SiebelIT'S ALL ABOUT THE CUSTOMERVisit www.siebel.comThis e-mail message is for the sole use of the intended recipient(s) andcontains confidential and/or privileged information belonging to SiebelSystems, Inc. or its customers or partners. Any unauthorized review,use, copying, disclosure or distribution of this message is strictlyprohibited. If you are not an intended recipient of this message, pleasecontact the sender by reply e-mail and destroy all soft and hard copiesof the message and any attachments. Thank you for your cooperation.__Do You Yahoo!?Tired of spam?  Yahoo! Mail has the best spam protection around http://mail.yahoo.com 

RE: jscookmenu problem

2005-09-19 Thread gvial








Nope... I get that too under IE but
strangely enough my coworker has no problem using Firefox apparently... Id
go for some browser-specific problem.



Greg











From: Dave
[mailto:[EMAIL PROTECTED] 
Sent: Monday, September 19, 2005 3:35
PM
To: MyFaces Discussion
Subject: RE: jscookmenu problem







Has anyone figured out how to remove the missing icons (red X) from the
menu items? I am using nightly build 9/12. Thanks

[EMAIL PROTECTED]
wrote: 

Hi,

Alright I'm gonna try to go through the steps I followed (to make it
from scratch, not from a weird situation like I was at the other day).

1) Install MyFaces the usual way
2) In your application, make sure your web.xml contains extra properties
for extensions filters like the following:


extensionsFilter

org.apache.myfaces.component.html.util.ExtensionsFilter/F
ilter-class

uploadMaxFileSize
10m


uploadThresholdSize
100k



extensionsFilter
*.faces


Note here that the url-pattern *.fac es has to correspond to the
url-pattern of your servlet mapping, as in:


Faces Servlet
*.faces


This was my problem, the examples were using *.jsf but I was using
*.faces for my extensions and I had just done copy/paste without paying
attention to this...

3) In the page where you want to use the jsCookMenu, you should now be
able to use the following:



itemLabel=#{bundle['menu.users']}
action="" /


Note: Using this technique you are using built-in themes within the
component. Hence you do not need to include any css or js files that
belong to the jsCookMenu component specifically in your page. These will
be added at run time for you.

Check the documentation for the layouts a nd themes available. As far as
I'm concerned this worked for me. Let us know if you're still stuck, and
let us know where you are stuck exactly if you're still experiencing
problems.

Hope this helps,

Greg


-Original Message-
From: Deepinder Singh [mailto:[EMAIL PROTECTED] 
Sent: Monday, September 19, 2005 2:54 PM
To: MyFaces Discussion
Subject: RE: jscookmenu problem

Greg,
Can you now click on the links of JSCookMenu. If so can you please
let us know what you changed or what was missing earlier.
Thanks,
deepinder

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, September 14, 2005 12:05 PM
To: users@myfaces.apache.org
Subject: RE: jscookmenu problem

1.
I'm looking into that too and currently trying to figure out why, unless
I include the js and css files in my page, it does not work. One way I
was able to see it (but not click on any links...) was to use TheOffice
for example, and in my page that uses the , add the
following:



type=text/css /


In the section. Of course you'll need the files in there... I
found them in
src\components\org\apache\myfaces\custom\navmenu\resource

But that's not the way it is supposed to work I believe...

2.
Haven't tried this one yet.

3.
I was able to get that one running fine. Maybe you can tell us how
you're trying to implement this?

Regards,

Greg

-Original Message-
From: Deepinder Singh [mailto:[EMAIL PROTECTED]
Sent: Wednesday, September 14, 2005 2:58 PM
To: MyFaces Discussion
Subject: RE: jscookmenu problem

I am still learning how to use these comps. Some of the problems I am
seeing are:- 1. Unbale to see the JSCookMenu on my page.
2. The table option is always visibile with the HTML Editor.
3. The scroller works fine, however I see crashes when I integrate with
the sorter.

I am using 1.0.9 version. Is anyone else having these problems?
Thanks,
deepinder



___
Siebel
IT'S ALL ABOUT THE CUSTOMER
Visit www.siebel.com

This e-mail message is for the sole use of the intended recipient(s) and
contains confidential and/or privileged information belonging to Siebel
Systems, Inc. or its customers or partners. Any unauthorized review,
use, copying, disclosure or distribution of this message is strictly
prohibited. If you are not an intended recipient of this message, please
contact the sender by reply e-mail and destroy all soft and hard copies
of the message and any attachments. Thank you for your cooperation.



__
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 








t:dataScroller one portion of data

2005-09-19 Thread Dave

I have 100 rows. Each time I like to fetch 10 rows from database. So the data model has knowledge of 10 rows. 


t:dataScroller id="scroll_1"
for=""
rowsCountVar="rowsCount"
displayedRowsCountVar="displayedRowsCountVar"
firstRowIndexVar="firstRowIndex"
lastRowIndexVar="lastRowIndex"
pageCountVar="pageCount"
pageIndexVar="pageIndex"
---
So the rowCount is 10, firstRowIndex=0, lastRowIndex=9 even though I fetch rows 50-59 from database.
I like the rowCount is 100 (the whole data model from user's view), the firstRowIndex is 50, and the lastRowIndex is 59. When User click next page (paginator), backing bean needs to be notified which portion of data to fetch from database.
Does t:dataTable and t:dataScroller support this? 
Thanks! Dave.
		Yahoo! for Good 
Click here to donate to the Hurricane Katrina relief effort. 


Re: jscookmenu problem

2005-09-19 Thread Martin Marinschek
It's already fixed in the SVN head!

regards,

Martin

On 9/19/05, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote:
  
  
 
 Nope... I get that too under IE but strangely enough my coworker has no
 problem using Firefox apparently... I'd go for some browser-specific
 problem. 
 
   
 
 Greg 
 
   
  
  
  
 
 From: Dave [mailto:[EMAIL PROTECTED] 
  Sent: Monday, September 19, 2005 3:35 PM
  To: MyFaces Discussion
  Subject: RE: jscookmenu problem 
 
   
  
 
 Has anyone figured out how to remove the missing icons (red X) from the menu
 items?  I am using nightly build 9/12. Thanks
  
  [EMAIL PROTECTED] wrote: 
 
 Hi,
  
  Alright I'm gonna try to go through the steps I followed (to make it
  from scratch, not from a weird situation like I was at the other day).
  
  1) Install MyFaces the usual way
  2) In your application, make sure your web.xml contains extra properties
  for extensions filters like the following:
  
  
  extensionsFilter
  
  org.apache.myfaces.component.html.util.ExtensionsFilter/F
 
  ilter-class
  
  uploadMaxFileSize
  10m
  
  
  uploadThresholdSize
  100k
  
  
  
  extensionsFilter
  *.faces
  
  
  Note here that the url-pattern *.fac es has to correspond to the
  url-pattern of your servlet mapping, as in:
  
  
  Faces Servlet
  *.faces
  
  
  This was my problem, the examples were using *.jsf but I was using
  *.faces for my extensions and I had just done copy/paste without paying
  attention to this...
  
  3) In the page where you want to use the jsCookMenu, you should now be
  able to use the following:
  
  
  
  itemLabel=#{bundle['menu.users']} action=#{bean.test} /
  
  
  Note: Using this technique you are using built-in themes within the
  component. Hence you do not need to include any css or js files that
  belong to the jsCookMenu component specifically in your page. These will
  be added at run time for you.
  
  Check the documentation for the layouts a nd themes available. As far as
  I'm concerned this worked for me. Let us know if you're still stuck, and
  let us know where you are stuck exactly if you're still experiencing
  problems.
  
  Hope this helps,
  
  Greg
  
  
  -Original Message-
  From: Deepinder Singh [mailto:[EMAIL PROTECTED] 
  Sent: Monday, September 19, 2005 2:54 PM
  To: MyFaces Discussion
  Subject: RE: jscookmenu problem
  
  Greg,
  Can you now click on the links of JSCookMenu. If so can you please
  let us know what you changed or what was missing earlier.
  Thanks,
  deepinder
  
  -Original Message-
  From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] 
  Sent: Wednesday, September 14, 2005 12:05 PM
  To: users@myfaces.apache.org
  Subject: RE: jscookmenu problem
  
  1.
  I'm looking into that too and currently trying to figure out why, unless
  I include the js and css files in my page, it does not work. One way I
  was able to see it (but not click on any links...) was to use TheOffice
  for example, and in my page that uses the , add the
  following:
  
  
  
  type=text/css /
  
  
  In the section. Of course you'll need the files in there... I
  found them in
 src\components\org\apache\myfaces\custom\navmenu\resource
  
  But that's not the way it is supposed to work I believe...
  
  2.
  Haven't tried this one yet.
  
  3.
  I was able to get that one running fine. Maybe you can tell us how
  you're trying to implement this?
  
  Regards,
  
  Greg
  
  -Original Message-
  From: Deepinder Singh [mailto:[EMAIL PROTECTED]
  Sent: Wednesday, September 14, 2005 2:58 PM
  To: MyFaces Discussion
  Subject: RE: jscookmenu problem
  
  I am still learning how to use these comps. Some of the problems I am
  seeing are:- 1. Unbale to see the JSCookMenu on my page.
  2. The table option is always visibile with the HTML Editor.
  3. The scroller works fine, however I see crashes when I integrate with
  the sorter.
  
  I am using 1.0.9 version. Is anyone else having these problems?
  Thanks,
  deepinder
  
  
  
  ___
  Siebel
  IT'S ALL ABOUT THE CUSTOMER
  Visit www.siebel.com
  
  This e-mail message is for the sole use of the intended recipient(s) and
  contains confidential and/or privileged information belonging to Siebel
  Systems, Inc. or its customers or partners. Any unauthorized review,
  use, copying, disclosure or distribution of this message is strictly
  prohibited. If you are not an intended recipient of this message, please
  contact the sender by reply e-mail and destroy all soft and hard copies
  of the message and any attachments. Thank you for your cooperation. 
  
 
 __
  Do You Yahoo!?
  Tired of spam? Yahoo! Mail has the best spam protection around 
  http://mail.yahoo.com 


-- 

http://www.irian.at
Your JSF powerhouse - 
JSF Trainings in English and German


Re: t:dataScroller one portion of data

2005-09-19 Thread David Haynes

Dave wrote:

I have 100 rows. Each time I like to fetch 10 rows from database. So 
the data model has knowledge of 10 rows.
 


t:dataScroller id=scroll_1

for=data

rowsCountVar=rowsCount

displayedRowsCountVar=displayedRowsCountVar

firstRowIndexVar=firstRowIndex

lastRowIndexVar=lastRowIndex

pageCountVar=pageCount

pageIndexVar=pageIndex

---

So the rowCount is 10, firstRowIndex=0, lastRowIndex=9 even though I 
fetch rows 50-59 from database.


I like the rowCount is 100 (the whole data model from user's view), 
the firstRowIndex is 50, and the lastRowIndex is 59. When User click 
next page (paginator), backing bean needs to be notified which portion 
of data to fetch from database.


Does t:dataTable and t:dataScroller support this?

Thanks! Dave.


Yahoo! for Good
Click here to donate http://store.yahoo.com/redcross-donate3/ to the 
Hurricane Katrina relief effort. 


AFAIK the answer is no.

The dataTable is a view onto the ResultSet that has been handed to it 
via the backing bean. The backing bean is assumed to hand the *entire* 
query result in one ResultSet. That is, the dataTable 'first' and 'rpws' 
operators are relative to the ResultSet, not to the database query 
result. (I am using 'query result' to indicate the set of values 
returned by the SQL query and ResultSet to be the JSF Collection of 
objects equivalent to the query result.)


In order to get what you want, there would have to be some way for the 
dataTable to hand the offset and row count values to the backing bean 
for use in creating the ResultSet. (See my earlier emails on having a 
parametric dataTable option.)


The assumption that the ResultSet is the entire query result is in 
keeping with the MVC model in that the view component is independent 
from the model, but it does present additional difficulties when working 
with large query results from a database performance point of view. 
There are other use cases where the non-dynamic nature of dataTable 
causes limitations, however these 'limitations' may be viewed as being 
the result of MVC and not necessarily JSF.


-david-



Re: Highlighting a specifc row in a datatable

2005-09-19 Thread Sean Schofield
There is a simple example that shows how you can highlight on mouse
over.  Perhaps you can build on that.

sean

On 9/19/05, Emmanuel Jay [EMAIL PROTECTED] wrote:
 Hi,
  
  Is it possible to highlight a specifc row in a datatable?
  
  I have tried the following but it doesn't work
  
  dataTable.setValueBinding(rowClasses,
 createValueBinding(#{(myvar.highlight) ? 'style1' : 'style2'}));
  
  Thanks,
  
  Emmanuel
  



RE: jscookmenu problem

2005-09-19 Thread gvial



Terrific!Gotta love an active community like that :)

Greg

  -Original Message- From: Martin 
  Marinschek [mailto:[EMAIL PROTECTED] Sent: Mon 9/19/2005 
  4:05 PM To: MyFaces Discussion Cc: Subject: 
  Re: jscookmenu problem
  



New ANNOUNCEMENT mailing list

2005-09-19 Thread Martin Marinschek
Hi *,

a new announcement mailing list has been created - subscribe to this
list to receive announcements about Apache MyFaces in a low traffic
way.

Subscription is done by sending mail to:

announce-subscribe.at.myfaces.apache.org

regards,

Martin