• Resolved Wesley Silva

    (@wesleydeveloper)


    Hello, I would like to know if there is a hook to edit the Downloads button or some way to retrieve the album id and the specific track by clicking the Downloads button?

    Example:

    <ul class="track-store">
    <li>
    <a href="#" target="_blank"><i class="fa fas fa-download"></i><spam>Download</spam></a>
    </li>
    </ul>

    Update for

    <ul class="track-store">
    <li>
    <a href="PATH_TO_DOWNLOAD" target="_blank" data-album="ALBUM_ID" data-track="TRACK_ID" download><i class="fa fas fa-download"></i><spam>Download</spam></a>
    </li>
    </ul>
    • This topic was modified 3 years, 9 months ago by Wesley Silva.
Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author sonaar

    (@sonaar)

    I dont quiet understand your question. Straight out of the box, there is no specific hook to do this.

    What are you trying to do exactly?

    Thread Starter Wesley Silva

    (@wesleydeveloper)

    Sorry for my forced English via Google Translate.

    But I already decided! I checked your code and saw that it doesn’t have a specific hook, so the solution was to create a post request to get the current track and search for it in the post type albums, that way I can get the id of the artist I wanted to log to the download. My goal was to limit the number of daily downloads by the user and manage the number of downloads per artist.

    Result present at https://hypetracks.io/

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Recover specific album and track via click on the Downloads button’ is closed to new replies.