Okay
  Public Ticket #3568764
Table
Closed

Comments

  • Josy started the conversation

    how to add a download button in the wpdatatable popup in wordpress

  •  1,689
    Miloš replied

    Hi Josy,

    Firstly, I would like to sincerely apologize for the delayed response as we have been experiencing an unusually high number of tickets. I am sorry that it has taken longer than usual to respond to your concern and your patience is highly appreciated.

    -

    When you say a 'download button' , can you please elaborate in more details what you need exactly?

    1. For example, if you just need to have a simple link as a 'button', there can be multiple ways to place links in the Table cells.

    Inside the Master-Details PopUp, any links you create will behave the same as if they are in the Table.


    Here is how you can make hyperlinks/ and have them look as a button in our Table :

    It depends if your Table is Editable or not.

    -

    For example, if we connect/link a Google Spreadsheet with our table in the plugin,

    our plugin can not read the hyperlinks directly like that from the source sheet.


    You would have to change the format of the data in the cells coming from the sheet in order for our plugin to properly render them as links.

    Now, it depends if you have one link per cell, or if you have multiple links in the same cell.


    1. If you have one link per cell,  perhaps the easiest way is to use our URL Columns.

    They have specific rendering rules :

    Rendering rules: If the content of the cells contains a combination of “two sticks” – || – everything to the left of this combination is used as an URL address for the link, and everything to the right as displayed text. For example:

    https://wpdatatables.com||Check out wpDataTables

    will be rendered as: Check out wpDataTables

    If the “||” combination is not found in the content, the entire content will be used both for the link and as the display value. For example: https://wpdatatables.com will be rendered as: https://wpdatatables.com

    -

    With the URL Column you can make it look as a button from the built-in Column options, you can also customize the button later on, etc.


    2.

    Alternatively, you can use String Columns.

    They can render custom HTML,  in that case, you would have to wrap the links in the source data as HTML anchor tags, for example :

    <a href="https://www.w3schools.com">Visit W3Schools.com!</a>
    

    will be rendered as hyperlink of displayed text : " Visit W3Schools.com! "

     if you use String Columns, you will also be able to have multiple links in the same cell,  and combinations or images with links, etc ( if needed).

    -



    2. But if you need something different, like Table Tools download in the master-Details, that is currently not possible.

    So if you can clarify the use-case, and we will advise.

    Thank you.

    Kind Regards, 

    Miloš Jovanović
    [email protected]

    Rate my support

    wpDataTables: FAQ | Facebook | Twitter | InstagramFront-end and back-end demo | Docs

    Amelia: FAQ | Facebook | Twitter | InstagramAmelia demo sites | Docs | Discord Community

    You can try wpDataTables add-ons before purchasing on these sandbox sites:

    Powerful Filters | Gravity Forms Integration for wpDataTables | Formidable Forms Integration for wpDataTables | Master-Detail Tables