• Resolved geekontheroad

    (@geekontheroad)


    Hi, first of all I want to say that you did a great job with this plugin!

    I’m having a suggestion. When using the {bulk_download_link} mergetag in a gravity view then the merge tag shows as the actual mergetag {bulk_download_link} when there are no uploaded files for an entry.

    I had a look at your code and this would be an easy fix. In the DownloadMergeTag.php file, in the method “replace_bulk_download_link” on line 57, when there are no upload fields, instead of returning the $text as is, you could return something like “no files uploaded”? that would solve my problem but I’m not sure if there are other scenarios where this would be a problem?

    Again I want to thank you for this wonderful plugin!

    Kind regards,
    Johan

Viewing 4 replies - 1 through 4 (of 4 total)
  • Thread Starter geekontheroad

    (@geekontheroad)

    Hi I am sorry, I had a second possible solution for the same problem that I forgot to say in my previous message. You could also apply a wp filter to that value. That way developers can easily overwrite the default text that shows when there are no files uploaded.

    Thanks again for the great work!

    Thread Starter geekontheroad

    (@geekontheroad)

    So, I noticed that my previously offered solution actually caused a bug elsewhere in gravity forms. I have solved this with a few more lines of code in your plugin. Same file and method as I mentioned before. I also included the code for the wp filter.
    Please find the full file with all my code changes on github: https://gist.github.com/geekontheroad/1158b18794ddcaf2e4fe9fea60a7afc7

    It would be cool if this can make its way into a future release. I believe it makes the plugin just a little bit more awesome ??

    Thank you very much!

    Plugin Author Torsten H?ndler

    (@shogathu)

    Hello @geekontheroad,

    thanks for your response, we will check the code you gave us and we take a look if we can implement it or find also another solution like the settings option for the filename.

    best regards

    Plugin Author Torsten H?ndler

    (@shogathu)

    Hello @geekontheroad

    we’ve released a new version and like I said, we implement a settings option for this now.

    best regards

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘mergetag in view not resolving if there are no files’ is closed to new replies.