diff --git a/.gitignore b/.gitignore deleted file mode 100644 index e43b0f9..0000000 --- a/.gitignore +++ /dev/null @@ -1 +0,0 @@ -.DS_Store diff --git a/README.md b/README.md index bf8fa23..bcb4e62 100644 --- a/README.md +++ b/README.md @@ -1,20 +1,9 @@ # IFrame module -[![Build Status](https://travis-ci.org/silverstripe-labs/silverstripe-iframe.svg?branch=master)](https://travis-ci.org/silverstripe-labs/silverstripe-iframe) -[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/silverstripe-labs/silverstripe-iframe/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/silverstripe-labs/silverstripe-iframe/?branch=master) -[![Build Status](https://scrutinizer-ci.com/g/silverstripe-labs/silverstripe-iframe/badges/build.png?b=master)](https://scrutinizer-ci.com/g/silverstripe-labs/silverstripe-iframe/build-status/master) -[![codecov.io](https://codecov.io/github/silverstripe-labs/silverstripe-iframe/coverage.svg?branch=master)](https://codecov.io/github/silverstripe-labs/silverstripe-iframe?branch=master) - -[![Latest Stable Version](https://poser.pugx.org/silverstripe/iframe/version)](https://packagist.org/packages/silverstripe/iframe) -[![Latest Unstable Version](https://poser.pugx.org/silverstripe/iframe/v/unstable)](//packagist.org/packages/silverstripe/iframe) -[![Total Downloads](https://poser.pugx.org/silverstripe/iframe/downloads)](https://packagist.org/packages/silverstripe/iframe) -[![License](https://poser.pugx.org/silverstripe/iframe/license)](https://packagist.org/packages/silverstripe/iframe) -[![Monthly Downloads](https://poser.pugx.org/silverstripe/iframe/d/monthly)](https://packagist.org/packages/silverstripe/iframe) -[![Daily Downloads](https://poser.pugx.org/silverstripe/iframe/d/daily)](https://packagist.org/packages/silverstripe/iframe) - -[![Dependency Status](https://www.versioneye.com/php/silverstripe:iframe/badge.svg)](https://www.versioneye.com/php/silverstripe:iframe) -[![Reference Status](https://www.versioneye.com/php/silverstripe:iframe/reference_badge.svg?style=flat)](https://www.versioneye.com/php/silverstripe:iframe/references) - -![codecov.io](https://codecov.io/github/silverstripe-labs/silverstripe-iframe/branch.svg?branch=master) +[![Build Status](https://travis-ci.org/silverstripe/silverstripe-iframe.svg?branch=master)](https://travis-ci.org/silverstripe/silverstripe-iframe) +[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/silverstripe/silverstripe-iframe/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/silverstripe/silverstripe-iframe/?branch=master) +[![codecov](https://codecov.io/gh/silverstripe/silverstripe-iframe/branch/master/graph/badge.svg)](https://codecov.io/gh/silverstripe/silverstripe-iframe) +[![Version](http://img.shields.io/packagist/v/silverstripe/iframe.svg?style=flat)](https://packagist.org/packages/silverstripe/silverstripe-iframe) +[![License](http://img.shields.io/packagist/l/silverstripe/iframe.svg?style=flat)](LICENSE.md) ## Introduction @@ -23,16 +12,18 @@ custom code. ## Requirements - * SilverStripe 3.0 + * SilverStripe ^4.0 + +**Note:** For a SilverStripe 3.x compatible version, please use [the 1.x release line](https://github.com/silverstripe/silverstripe-iframe/tree/1.0). ## Installation -Copy the iframe directory into your SilverStripe project, then append dev/build?flush=all to the website URL in your -browser. e.g. http://mysite.com/dev/build?flush=all +Run `composer require silverstripe/iframe`, then append dev/build?flush=all to the website URL in your +browser. e.g. http://mysite.test/dev/build?flush=all ## Instructions -For usage instructions see [user manual](docs/en/userguide/index.md). +For usage instructions see the [user manual](docs/en/userguide/index.md). ## Contributing diff --git a/docs/en/userguide/index.md b/docs/en/userguide/index.md index 28346f8..0c67780 100644 --- a/docs/en/userguide/index.md +++ b/docs/en/userguide/index.md @@ -14,7 +14,7 @@ This module provides a page type that you can use to embed IFrames in your websi ## Creating an IFrame -IFrame pages are created like any other page. When you create a new page, selected the **IFrame Page** from the list of available page types. +IFrame pages are created like any other page. When you create a new page, selected the **I Frame Page** from the list of available page types. There are a few new fields on an IFrame page. @@ -22,12 +22,13 @@ The most important is *Iframe URL*: this is the URL that wish you display inside path (ie, http://example.com/) or a relative path (ie, /about-us/). If it is a relative path then it will be assumed to be from the root of your site (ie, http://mysite.com/about-us/). -*Auto height* will change the height of the IFrame to match the total height of the remote page. This will only work if -the remote page is hosted on the same domain. +*Auto height* will change the height of the IFrame to match the total height of the remote page. +_This will only work if the remote page is hosted on the same domain._ If you check *Auto width* the IFrame will take up the entire width of the content area that it is in. You can manually set the height and width with the *Fixed height* and *Fixed width* fields. +The Auto width/height options must not be enabled for these fields to work. The *Content* field has been broken up into three separate fields: one to display above the IFrame, one to display beneath the IFrame, and another to display instead of the IFrame if the user has disabled them. @@ -37,4 +38,4 @@ beneath the IFrame, and another to display instead of the IFrame if the user has A common test case is to enter "http://google.com" as the IFrame URL. This won't work! Google's website has the *X-Frame-Options: SAMEORIGIN* header which means that it can only be displayed in an IFrame with a bit of technical hackery. If you experience a white box displaying with any other website, check if it has that option set in the -header. \ No newline at end of file +header.