You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by "raju.ch" <ra...@gmail.com> on 2011/11/21 10:38:17 UTC

Difference b/w SetoutputMarkupId(true) and SetOutputMarkupHolderTag(true?)

Can anyone tell me the difference b/w SetoutputMarkupId(true) and
SetOutputMarkupHolderTag(true)?

--
View this message in context: http://apache-wicket.1842946.n4.nabble.com/Difference-b-w-SetoutputMarkupId-true-and-SetOutputMarkupHolderTag-true-tp4091035p4091035.html
Sent from the Users forum mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: Difference b/w SetoutputMarkupId(true) and SetOutputMarkupHolderTag(true?)

Posted by "raju.ch" <ra...@gmail.com>.
Thank you very much

--
View this message in context: http://apache-wicket.1842946.n4.nabble.com/Difference-b-w-SetoutputMarkupId-true-and-SetOutputMarkupHolderTag-true-tp4091035p4091182.html
Sent from the Users forum mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: Difference b/w SetoutputMarkupId(true) and SetOutputMarkupHolderTag(true?)

Posted by Ernesto Reinaldo Barreiro <re...@gmail.com>.
setOutputMarkupHolderTag(true) is there for the use case where you
want to place an empty element (e.g. an empty "div" with an ID
assigned to it)  and later on replace it, via AJAX, with real
contents. E.g.

final WebMarkupContainer div = new WebMarkupContainer("div");
 div.setVisible(false);
 div.setOutputMarkupHolderTag(true);
 // contents added to div

will place a

<div id="generatedId" style="display:none;"></div>

later on via AJAX you could do

onClick(AjaxRequestTarget target) {
     div.setVisible(true);
     target.add(div);
}

which will produce

<div id="generatedId">Contents here</div>

Regards,

Ernesto

On Mon, Nov 21, 2011 at 10:38 AM, raju.ch <ra...@gmail.com> wrote:
> Can anyone tell me the difference b/w SetoutputMarkupId(true) and
> SetOutputMarkupHolderTag(true)?
>
> --
> View this message in context: http://apache-wicket.1842946.n4.nabble.com/Difference-b-w-SetoutputMarkupId-true-and-SetOutputMarkupHolderTag-true-tp4091035p4091035.html
> Sent from the Users forum mailing list archive at Nabble.com.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: Difference b/w SetoutputMarkupId(true) and SetOutputMarkupHolderTag(true?)

Posted by "raju.ch" <ra...@gmail.com>.
Thank you very much

--
View this message in context: http://apache-wicket.1842946.n4.nabble.com/Difference-b-w-SetoutputMarkupId-true-and-SetOutputMarkupHolderTag-true-tp4091035p4091183.html
Sent from the Users forum mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: Difference b/w SetoutputMarkupId(true) and SetOutputMarkupHolderTag(true?)

Posted by Matthias Keller <ma...@ergon.ch>.
Hi

setOutputMarkupId sets the "id" attribute of the HTML tag. This 
generally must be set if the tag shall be updated by AJAX
setOutputMarkupPlaceholderTag has the effect that a *hidden* component 
is still added to the HTML tree but - hidden. This is used, if the 
component is initially not visible (isVisible() == false) and would 
normally not leave a trace in the generated HTML file, thus it cannot be 
set visible by AJAX since it doesn't have a 'handle' to it. So it 
generally must be set to true if the component is to be updated by AJAX 
but is NOT initially visible.

Matt

On 2011-11-21 10:38, raju.ch wrote:
> Can anyone tell me the difference b/w SetoutputMarkupId(true) and
> SetOutputMarkupHolderTag(true)?