Rerender:
Purpose: Partial refresh
The value of this attribute is the component ID, which can be one or more IDs. Multiple IDs are separated by commas.
Rendered:
Purpose: You can control whether a widget is displayed on a page.
The value of this attribute is a Boolean value. If it is true, the control is displayed on the page. Otherwise, it is not displayed on the page.
Combination of rerender and rendered:
You cannot write the rerender and rendered attributes in a control. Place the control that is not displayed in the control that is refreshed locally.
Eg:
<Apex: Form>
<Apex: pageblock Title = "condition">
<Apex: pageblocksection columns = "2">
<Apex: outputpanel Title = "Account">
<Apex: outputlabel value = "account:"> </Apex: outputlabel>
<Apex: selectlist value = "{! Optionacc} "size =" 1 "style =" width: 230px ">
<Apex: selectoptions value = "{! Optionacclist} "> </Apex: selectoptions>
<Apex: actionsupport event = "onchange" Action = "{! Searchaccopplist} "rerender =" oppid, contentid "/>
</Apex: selectlist>
</Apex: outputpanel>
<Apex: outputpanel Title = "opportunity" id = "oppid">
<Apex: outputlabel value = "opportunity:"> </Apex: outputlabel>
<Apex: selectlist value = "{! Optionopp} "size =" 1 "style =" width: 230px ">
<Apex: selectoptions value = "{! Optionopplist} "> </Apex: selectoptions>
<Apex: actionsupport event = "onchange" Action = "{! Searchoppcontentlist} "rerender =" contentid "/>
</Apex: selectlist>
</Apex: outputpanel>
</Apex: pageblocksection>
</Apex: pageblock>
<Apex: outputpanel id = "contentid">
<Apex: pageblock Title = "content" rendered = "{! Showcontentversion} ">
......
This article is from the "prodigal_k" blog, please be sure to keep this source http://919637235.blog.51cto.com/7344598/1529929