I have create a command button on vf page. But Command button not getting display on Vf page.
My code
<apex:page controller="testpopup">
<apex:form>
<apex:pageBlock>
<apex:pageBlockButtons>
<apex:commandButton value="test" action="{!showpopup}" rendered="testpopup"></apex:commandButton>
</apex:pageBlockButtons>
<apex:pageBlockSection></apex:pageBlockSection>
</apex:pageBlock>
<apex:pageBlock>
</apex:pageBlock>
<apex:outputPanel id="testpopup">
<apex:outputPanel styleClass="popupbackgroud" layout="block" rendered="{!displayPopUp}" />
<apex:outputPanel styleClass="custPopup" layout="block" rendered="{!displayPopUp}">
This is where I would put whatever information I needed to show to my end user.
<br/>
<br/>
<br/>
<apex:commandButton value="Hide Pop up" action="{!closePopup}" rerender="testpopup" />
</apex:outputPanel>
</apex:outputPanel>
</apex:form>
<style type="text/css">
.custPopup {
background-color: white;
border-width: 2px;
border-style: solid;
z-index: 9999;
left: 50%;
padding: 10px;
position: absolute;
/* These are the 3 css properties you will need to change so the popup
displays in the center of the screen. First set the width. Then set
margin-left to negative half of what the width is. You can add
the height property for a fixed size pop up if you want.*/
width: 500px;
margin-left: -250px;
top: 100px;
}
.popupBackground {
background-color: black;
opacity: 0.20;
filter: alpha(opacity=20);
position: absolute;
width: 100%;
height: 100%;
top: 0;
left: 0;
z-index: 9998;
}
</style>
</apex:page>
i am new in salesforce. Please let me know what is getting wrong .