Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 6 of 6
  1. #1
    New to the CF scene
    Join Date
    Oct 2008
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Possible to crop an iframe?

    Hi I run a very simple, 1 page, calendar site however I would like to crop the bottom of my google calendar iframe. This bottom bit contains the "+ google calendar button" which means competition can easily steal my content...

    www.headfirstmusic.co.uk

    Thanks to anyone that can help - Harry

  • #2
    Senior Coder effpeetee's Avatar
    Join Date
    Feb 2007
    Location
    Clapham Junction - London SW
    Posts
    4,885
    Thanks
    228
    Thanked 204 Times in 203 Posts
    Last edited by effpeetee; 10-03-2008 at 12:13 PM.
    * Sources (updated: 21.11.2012.
    Using Windows 8 Professional. 64bit with HP Photosmart 5510 printer Very useful site here.

  • #3
    Regular Coder
    Join Date
    May 2008
    Location
    Oxford, UK
    Posts
    422
    Thanks
    14
    Thanked 27 Times in 27 Posts
    How will people steal your content? That button just prompts people to get their own google calendar does it not?

    Are you actually just wanting to hide the fact that it's a google calendar to make people think you made it yourself?

  • #4
    New to the CF scene
    Join Date
    Oct 2008
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts
    the "+ google calendar" adds it as an overlay in anyone's google calendars page they can then export it and reimport it to another calendar...

  • #5
    New to the CF scene
    Join Date
    Oct 2008
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Thanks for your help frank -

    The idea on the 2nd site doesn't seem to work with google calendar's iframe, as even when scroll bars are set to "no" or "0" they still occur. However the first idea sounds interested :

    how do I "You can apply negative margins to the body element inside iframe."

    Cheers!

  • #6
    Senior Coder effpeetee's Avatar
    Join Date
    Feb 2007
    Location
    Clapham Junction - London SW
    Posts
    4,885
    Thanks
    228
    Thanked 204 Times in 203 Posts
    Have a look at this URL.
    and this


    This is from the first url..


    Code:
    Negative margins
    
    The negative margins technique allows to center a block for which the dimensions are known.
    
    Centering can be horizontal, vertical or both.
    
    For a container block of 700 px by 400 px. We want it exactly centered within the navigator no matter the definition used (800x600, 1024x768 or more).
    
    The trick is to first place this block at 50% top and 50% left, which will place the upper left corner of the block in the middle of the page.
    
    Then we will define negative margins with a value that is exactly half of the width and height of the block, which will position it exactly in the middle of the page.
    
    Here is the CSS code for the container:
    
    #global {
         position:absolute;
         left: 50%; 
         top: 50%;
         width: 700px;
         height: 400px;
         margin-top: -200px; /* half of the height */
         margin-left: -350px; /* half of the width */
         border: 1px solid #000;
         }
    Then place the container right below the <body> tag:
    
    <div id="global"></div>
    Now the block is centered.(View result here)
    
    Note: Negative vertical margins in CSS seem to be causing problems on Explorer / Mac.
    
    (Liberally inspired from http://bluerobot.com/web/css/center2.html)
    
    Print article
    Raphael GOETTER
    www.alsacreations.com
    Last edited by effpeetee; 10-03-2008 at 12:58 PM.
    * Sources (updated: 21.11.2012.
    Using Windows 8 Professional. 64bit with HP Photosmart 5510 printer Very useful site here.


  •  

    LinkBacks (?)


    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •