=== Sfogliami ===
Contributors: sfogliami
Tags: flipbook, pdf, magazine, catalog, embed
Requires at least: 6.3
Tested up to: 7.1
Requires PHP: 7.4
Stable tag: 1.0.0
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Show your Sfogliami flipbooks and collections on your WordPress site: paste the link, or use the block or the shortcode.

== Description ==

[Sfogliami](https://www.sfogliami.it/) turns a PDF into a flipbook you can share with a link: magazines, catalogues, brochures, menus, books. This plugin shows those flipbooks inside your WordPress pages, with pages that turn like paper, zoom and full screen.

* **Paste the link.** Paste the address of a flipbook on its own line in the editor and it becomes the flipbook. It works in the block editor, in the classic editor and in the page builders that accept embeds.
* **Sfogliami block.** Search for "Sfogliami" among the blocks, paste the link, done. In the sidebar you can open the flipbook at a given page or give it a fixed height. Wide and full width alignments are supported.
* **Shortcode.** `[sfogliami url="https://www.sfogliami.it/fl/…"]` for page builders, widgets and themes.
* **Collections.** The link of a collection shows all its issues, and the frame grows with the collection. The link of the latest issue (`/ultimo/…`) always shows the most recent one, so the page never needs to be changed.
* **The right height.** The frame fits the open book in the width of your column, on computers and phones, for upright and landscape pages.
* **Light.** No settings to fill in; the flipbook loads only when it scrolls into view.

You need a flipbook on Sfogliami: creating one is free, from [www.sfogliami.it](https://www.sfogliami.it/).

= Shortcode =

`[sfogliami url="https://www.sfogliami.it/fl/123456/abcdef"]`

Optional attributes:

* `height="700"`: fixed height in pixels instead of the automatic one.
* `page="5"`: opens the flipbook at page 5.
* `new_tab="yes"`: collections only, opens the issues in a new browser tab.

== External services ==

This plugin shows content hosted by Sfogliami, the service at www.sfogliami.it run by ID Studio Srl, and it cannot work without it.

* **The flipbook itself.** Every flipbook or collection you add is shown in a frame loaded from www.sfogliami.it. When a visitor opens the page, their browser connects to the Sfogliami servers, which receive the visitor's IP address, the address of the page (as referrer) and the usual browser data.
* **Title and format.** When a page with a flipbook is shown, the site asks https://www.sfogliami.it/oembed for the title and the page format of that flipbook, to give the frame the right height. The request contains only the address of the flipbook and the address of your site (in the user agent). The answer is kept for a week.

Sfogliami terms of use: https://www.sfogliami.it/condizioni?language=en
Sfogliami privacy policy: https://www.sfogliami.it/privacy?language=en

== Installation ==

1. In WordPress go to Plugins > Add New Plugin and search for "Sfogliami", or upload the zip file downloaded from https://www.sfogliami.it/plugin-wordpress.
2. Activate the plugin.
3. Copy the link of your flipbook from your Sfogliami library (Share) and paste it in a page.

== Frequently Asked Questions ==

= Where do I find the link of my flipbook? =

In your library on Sfogliami, under Share: it is the address that starts with https://www.sfogliami.it/fl/. The embed code (iframe) copied from the same page works too.

= Does it work with Elementor, Divi and other page builders? =

Yes, with the shortcode: put `[sfogliami url="…"]` in a shortcode or text widget. Many page builders also turn a pasted link into the flipbook.

= My flipbook is visible only on my own site. =

Add the domain of your WordPress site to the option "Visible only from the domain" of the flipbook on Sfogliami, otherwise the frame shows a warning instead of the pages.

= Does it slow my pages down? =

The plugin adds only a small stylesheet, and the browser loads the flipbook only when it gets close to the screen.

= Does it set cookies? =

The plugin does not. The flipbook comes from www.sfogliami.it, which has its own cookie banner and privacy policy (https://www.sfogliami.it/privacy?language=en). The plugin adds a suggested paragraph to your privacy policy (Settings > Privacy).

== Changelog ==

= 1.0.0 =
* First version: block, shortcode, automatic embeds of pasted links, collections and latest issue.
