Not a bugAdd a class to download, delete, and detach links

This topic contains 5 replies, has 2 voices, and was last updated by  memoryexpress 7 months, 3 weeks ago.

  • Creator
    Topic
  • #55149

    memoryexpress
    Participant

    Hi Milan,
    I hope you’re well.

    I was hoping you could add a CSS class to the download, delete, and detach links for the file attachments.

    I noticed that the download link looks like this:

    <a class download href="http://www.website.com">

    Is it supposed to be this?:

    <a class="download" href="http://www.website.com">

    Including a unique class for the three clickable links would let your plugin users style those links more directly.
    For my purposes, I need a class on the link itself to deal with a compatibility issue between GD bbPress Attachments and Slim Stat Analytics. Currently, when one of my users clicks the download link, two copies of the file are pulled down. I need a class on the

    <a>

    itself so I can filter out that click in the analytics program.

    Let me know what you think.

    Thanks for all your hard work!

    -Mike

    Topic Information
    Feature Request
    7.0
    4.7
    2.4
    Attachments:
Viewing 5 replies - 1 through 5 (of 5 total)
  • Author
    Replies
  • #55153

    MillaN
    Keymaster

    In this case, ‘download’ is an attribute for the A tag that tells the browser to download the file, and not open it, and ‘class’ attribute is empty. Right now, the plugin has no option to set custom CSS class on the link. And, there is no need to have class on that A tag, all of them can be accessed in JavaScript via selector ‘.bbp-attachments a’.

    Milan

    Dev4Press - Premium plugins for WordPress.

    #55154

    memoryexpress
    Participant

    Hi Milan,

    Thanks for the quick reply, and the clarification on the ‘download’ attribute.

    It’s true that I your users can already select those elements using ‘.bbp-attachments a’.

    Unfortunately I can’t use that method of selection to add a filter in the Slim Stat Analytics’ plugin.
    Would you be able to add a class anyway?
    It would save me from having to hack the bbPress Attachments plugin any time I update it.

    I recognize it’s a change that will only benefit your users that also use analytics software, but it’s an extremely low-cost change to make on your end.

    Thanks for your help!

    #55156

    MillaN
    Keymaster

    I will add this to the list for the next version (I can’t say exactly when it will be out, but it should be soon once I finish tests with upcoming bbPress 2.6).

    Milan

    Dev4Press - Premium plugins for WordPress.

    #55158

    memoryexpress
    Participant

    That’s incredible. Thank you very much, Milan.

    I know you have a lot on your to-do list already. Little things like this go to show how amazingly you support your products.

    #55557

    memoryexpress
    Participant

    Hi Milan,

    I just wanted to come back and say thanks a lot for adding those classes to the download links. My issue is totally resolved.

    I really appreciate the support.

    Mike Bolton
    Memory Express

Viewing 5 replies - 1 through 5 (of 5 total)

You must be logged in to reply to this topic.