To align Pageblock center

The <center> tag in HTML is used to align the <apex:pageblock> center:

Sample Code:

<center>
  <apex:pageBlock >
    <b>Category:&nbsp;&nbsp;</b>
    <select id =”ctgry” onchange = “memb()”>
      <option>Please Select</option>
      <option value = “Member”>Members</option>
      <option value = “Blog”>Blogs</option>
      <option value = “Photo”>Photos</option>
    </select>
  </apex:pageBlock>
</center>

Simple way.

Leave a Reply