• Resolved Satri

    (@satri)


    Hi Tobias – I tried to find a previous discussion / existing documentation about this but failed.

    I’d like to display a TablePress table full screen, ignoring the WordPress layout and widgets. Any way to do this?

    What about a feature which provides a link to ‘Display table in a new window’? A new window which would be limited by the screen size and not the WordPress theme width.

    Thanks Tobias for any feedback! — Alex
    (I just flattered you :-))

    https://www.ads-software.com/plugins/tablepress/

Viewing 10 replies - 1 through 10 (of 10 total)
  • Plugin Author TobiasBg

    (@tobiasbg)

    Hi Alex,

    thanks for your post, and sorry for the trouble.
    And thanks for the flattr ?? )

    Unfortunately, I don’t know an existing solution to this, and I think this is more something that would need to be implemented by the theme. You would for example need to create a new custom “page template” or something, where you only show the table without anything around it.
    Then, you could use some JavaScript maybe to open that page with the table in a new window.

    Regards,
    Tobias

    Thread Starter Satri

    (@satri)

    Hi Tobias – thanks for the blazing fast feedback!

    I’m not asking you anything, I understand the plugin is free and anyone can contribute to the code on GitHub, that said, here’s my personal feedback.

    While I have little experience in WP plugin development, I believe it should really be done at the Plugin-level, not the Theme-level. Just like slider plugins can display images full screen, a table could be displayed full screen in its own window via the Plugin.

    Actually, we’re very close to this with TablePress. TablePress can already export tables to html. This html can be opened in a new window at the table’s width. The main thing missing is the CSS/decoration to make this html pretty enough. Maybe reusing the current TablePress CSS for such an exported html is possible? What do you think?

    Thanks & take care Tobias! — Alex

    Plugin Author TobiasBg

    (@tobiasbg)

    Hi Alex,

    well this is tricky. Of course, one could use the exported HTML, but then again, why not use the actual rendering algorithm that TablePress has? That however has to be initialized by either a Shortcode or by a template tag function. One way or the other, a URL on the site for the page with just the table would be necessary, and I feel that that’s more something that a theme can do.
    The comparison with the images might make this clearer: The images have their own URL, so that can easily be opened in a new window/tab. Tables don’t have such a URL. The approach with the full-screen view that slider or gallery plugins use could be easier actually. With that, one would only need JavaScript, grab the corresponding DOM element, move it somewhere else maybe and apply styling to it, similar to how those Lightbox effects work.
    This however would require a pretty tight integration into the theme, with JS and everything. So, while it could be done in a plugin, this particular scenario might make more sense in the theme.

    Regards,
    Tobias

    Put your tables in some shortcode of plugin that opens shortcodes in modal box. And percentage of screen size, 100% or 90%. You will still have “close” X button.

    That way you wont lose visitors because they can come back. Tables in fullscreen dont have navigation and people might just close tab/window.

    If you are looking to print tables then maybe WP Print plugin can be easy customized, i did it once not so difficult.

    Plugin Author TobiasBg

    (@tobiasbg)

    Hi,

    yes, that’s a good idea. When showing such a modal box, user’s will be kept on the same page.
    For printing, the DataTables TableTools Extension from https://tablepress.org/extensions/datatables-tabletools/ might also be helpful.

    Regards,
    Tobias

    Thread Starter Satri

    (@satri)

    Thanks to both of you! That should work.

    I have tried 3 modal plugins so far without success, but I suspect that’s going to work at some point (it should!). I’ll report back once I succeed and let you know what worked.

    jQuery Colorbox plugin can open everything in modal box.
    And you can use it as lightbox for all your images on website. To not duplicate JS scripts.

    https://www.ads-software.com/plugins/jquery-colorbox/

    Plugin Author TobiasBg

    (@tobiasbg)

    Hi,

    very cool! Thanks for sharing that plugin!

    Best wishes,
    Tobias

    Thread Starter Satri

    (@satri)

    I successfully made it work with the ‘Easy Modal Plugin’. So yes, TablePress tables can be put in their own windows with such plugins. Maybe you can add this in the TablePress FAQ Tobias?

    I haven’t tested jQuery Colorbox, but it has not been updated for over 18 months and I have a solution now.

    Thanks a lot Stagger and Tobias for your contributions! ?? — Alex

    Plugin Author TobiasBg

    (@tobiasbg)

    Hi,

    “Easy Modal Plugin” also looks nice. Good to hear that you found this!
    And yes, this would be nice for the FAQ, I think.

    Best wishes,
    Tobias

    P.S.: In case you haven’t, please rate TablePress here in the plugin directory. Thanks!

Viewing 10 replies - 1 through 10 (of 10 total)
  • The topic ‘Display table in a new full screen window?’ is closed to new replies.