Linux 软件免费装
Banner图

Simple Ebook Viewer

开发者 wrcisco
更新时间 2026年3月16日 09:03
PHP版本: 6.0 及以上
WordPress版本: 6.9
版权: GPLv2 or later
版权网址: 版权信息

标签

viewer reader ebook epub azw3

下载

1.0.0 0.4.1

详情介绍:

After installing this plugin, you will be able to upload various ebook formats as normal media files and to display them in your site using a shortcode. Every ebook uploaded in your site will have an "ebook slug" (by default it will be the ebook name) that you can view and edit in the Edit Media page of the Admin Panel. The full source code of the plugin is hosted on GitHub. Supported formats At the moment, the plugin will let you upload and display the following file types, provided that they are DRM-free: Usage Insert the shortcode [simebv_viewer book="MY_EBOOK_SLUG_HERE"] in any one of your posts. Styling You can add css styles and classes for the viewer container by adding these attributes to the shortcode: Height, width, max-height, max-width and border accept any valid CSS value for those property. Style and class accept any valid value for the respective HTML attributes. Some examples: [simebv_viewer book="MY_EBOOK_SLUG_HERE" style="height:30em;border:2px inset black"] [simebv_viewer book="MY_EBOOK_SLUG_HERE" max-height="100vh" height="40em"] [simebv_viewer book="MY_EBOOK_SLUG_HERE" class="my-container-class my-container-second-class"] Settings The users of your site will be able to set their preferences about the appearance of the ebook in the Viewer by opening the Viewer menu (the cog icon on the top right) and by selecting the appropriate entries. The plugin sets some reasonable defaults for these preferences, but if you're not happy with those defaults, you can change them by adding one or more of the following attributes to the shortcode, with the appropriate values: Max-pages is the maximum number of pages (in the "paginated" layout) that the user will be able to see in a single view (if there is enough screen space). Show-annotations and show-page-delimiters let the user see on the pages the Calibre annotations (as highlighted text, if there are Calibre annotations in the ebook) and the page delimiters (as short vertical bars, if the ebook contains a page list). Color-scheme: "auto" means that the Viewer will adapt to the preferred color-scheme set by the user in their device or browser (light or dark). For most ebooks these preferences should be enough, but sometimes there are ebooks with style rules that don't play well with the styles set by the Viewer, so the users have also the option to apply some filters to the Viewer's colors (with the menu entry "Color filter..."). You can set the default values for these filters with the following shortcode's attributes: Bg-transparent-filter and bg-color-filter are available for reflowable ebooks only. Invert-color-filter inverts the lightness of the colors. With a value of 0 it has no effect, with a value of 1, the white will become black and the black will become white. Rotate-color-filter rotates the hues of all the colors in the ebook, like in a Color Wheel (so, no effect on black and white). There are some other settings that the users won't be able to change by themselves. These are: If real-fullscreen is set to "true", the ebook viewer will cover the entire screen instead of only the viewport of the webpage when the user clicks on the "full screen" icon. With real-fullscreen set to true, always-full-viewport is ignored, since the full screen requires an explicit action by the user. Allow-js: normally, the plugin forbids, as far as possible, script execution from inside the ebooks. If you set allow-js to true, this restriction is relaxed, and scripts within the ebook can be executed. Caveat 1: you need to be absolutely certain that the code inside the ebook is not malicious, since it can harm your entire webpage. Caveat 2: the ebook viewer is not strongly equipped to deal with dynamic content created or removed after the ebook opening, so you might encounter errors or inaccuracies when jumping from one ebook location to another in such a circumstance. Math-styles: in recent years all the major browser have implemented a good deal of the MathML Core specification, so it is now possible to represent natively many mathematical expression without the use of third party libraries. However, not all browsers and systems load automatically appropriate fonts. With math-styles set to "fonts" or "all", all the contents of MathML expression will use the Latin Modern font. Another shortcoming in the current support of MathML, is that only Gecko based browsers (i.e. Firefox) implement a breaking lines algorithm, so long math expressions within small screens usually don't fit entirely. With math-styles set to "styles" or "all", the plugin will use some html+css tricks to try to allow either line breaks or horizontal scrolling. Ebook-author and ebook-title: you can use these optional values to override the ones that the ebook viewer retrieves from the ebook metadata in order to display them to the users. Popup-notes: show footnotes and endnotes as popup instead of just links. The notes (and their references) need to be marked with the appropriate epub:type attributes to ensure that they are displayed as popups (the ebook viewer will try to recognize them anyway, but without guarantees).