+ Start a Discussion
madhu_ramadhu_ra 

Render a specific div in landscape mode

Is there a way to render a specific <div /> section in landscape mode when we using renderAs="pdf" ? This is what I'm looking for.
I'm exporting some reports to be printed. I need to add a summary page for all of them at the begining or at the end. This page(s) need to to be in landscape mode.
<div id="summary" >
    <table width="100%" border="1">
        <tr>
            <td width="40%"><apex:image id="logo1" url="{!$Resource.logo}"/></td>
            <td align="right"><span class="headings2">Summary</span></td>
        </tr>        
    </table>
    <br />
    <table style="width:100%" >
        <thead>
            <tr >
           </tr>
        </thead>
        <apex:repeat value="{!uiContentList}" var="item">
            <tr >
            </tr>
        </apex:repeat>
    </table>    
</div>

<div id="details" >
    <table width="100%" border="1">
        <tr>
            <td width="40%"><apex:image id="logo1" url="{!$Resource.logo}"/></td>
            <td align="right"><span class="headings2">Summary</span></td>
        </tr>        
    </table>
    <br />
    <table style="width:100%" >
        <thead>
            <tr >
           </tr>
        </thead>
        <apex:repeat value="{!uiContentList}" var="item">
            <tr >
            </tr>
        </apex:repeat>
    </table>    
</div>

CSS
@page {
        size: A4;
        @bottom-center {
            content: "Page " counter(page) " of " counter(pages);
        }
    }

I have more css for page breaks and all are working fine. Just need to add something so that my summary table is in landscape mode. It can't assummed to be in one page and so I'm looking for a div in landscape mode.

Thanks
AmitAmit (Salesforce Developers) 
Please refer following links for more information :

http://stackoverflow.com/questions/16412987/css-fixed-position-div-content-cuts-off-in-mobile-landscape-mode-and-will-not-sc 

http://matthewjamestaylor.com/demos/ipad-css-layout/

http://force.siddheshkabe.co.in/2011/04/some-pdf-tricks-on-visualforce.html