• Resolved njwp

    (@njwp)


    When adding packages to a page you get a shotcode like this:

    [wpdm_package id=79 template="link-template-default.php"]

    When you have lots of those on a page it can be hard to know what the package is.

    Can I add a comment to the shotcode like this:

    [wpdm_package id=79 template="link-template-default.php" "this is my package"]

    I have tried and it doesn’t seem to cause an error, so I’m just checking if you can see any problem with it.

    This would help a lot when there are lots of packages on a page and you want to find a specific one to delete for example

    Thanks

Viewing 12 replies - 1 through 12 (of 12 total)
  • Plugin Support Nayeem Hyder

    (@nriddhi)

    No such parameter with the shortcode. You can set before-after text comment of every shortcode, it will recognize the shortcode corresponding file. and if it for your editor looking and no content get a break for this parameter, you can use it.

    Thanks.

    • This reply was modified 6 years, 5 months ago by Nayeem Hyder.
    Thread Starter njwp

    (@njwp)

    Thanks so much for your reply. I can’t quite understand what you have said (I guess English isn’t your first language)

    So is this OK?
    [wpdm_package id=79 template="link-template-default.php" "this is my package"]

    Plugin Support Nayeem Hyder

    (@nriddhi)

    Do you want to use it from your editor’s view? and identify which your package is

    Thread Starter njwp

    (@njwp)

    yes
    Thanks

    Plugin Contributor Shafaet Alam

    (@shafayat-alam)

    @njwp you can write it like this:

    this is my package
    [wpdm_package id=79 template="link-template-default.php"]

    But you can’t add it with shortcode.

    However, if you want to add such static text inside the download link template, you will need the pro version. As pro version has an integrated template editor. Doc: https://www.wpdownloadmanager.com/doc/templates/creating-a-new-template/

    Thread Starter njwp

    (@njwp)

    If I write it like this :

    this is my package
    [wpdm_package id=79 template="link-template-default.php"]

    Then the words ‘this is my package’ appear on the website. I don’t want that

    I only want the words in the editor so I know what the packages are when I’m editing

    This :
    [wpdm_package id=79 template="link-template-default.php" "this is my package"]

    is exactly what I want.

    I don’t need anything else

    It does what I want.

    I don’t need the words ‘this is my package’ to be added by the shortcode. I’m happy to type them in

    My question is:

    Will it casue errors?

    Thanks

    Hi:
    Used Content Views – Post Grid & List for WordPress
    https://ww.wp.xz.cn/plugins/content-views-query-and-display-post-page/
    and &
    WordPress Download Manager
    https://ww.wp.xz.cn/plugins/download-manager/

    After clicking the second image download file, it cannot be downloaded directly
    Will jump to the third picture and download
    Ask how to download the file directly when you click Download

    Img1
    https://prnt.sc/qbvdsb

    Img2
    https://prnt.sc/qbve8a

    img3
    https://prnt.sc/

    • This reply was modified 6 years, 5 months ago by iamvictor.
    Plugin Contributor Shafaet Alam

    (@shafayat-alam)

    @njwp, Yes, you can do that like this:
    [wpdm_package id=79 template="link-template-default.php" note="this is my package"]

    Additionally, if you are already using Gutenberg, you can use ww.wp.xz.cn/plugins/wpdm-gutenberg-blocks/ where you will not need any such note as you will see the package preview in the editor.

    @iamvictor, please create a separate post for your issue.

    Thread Starter njwp

    (@njwp)

    @shafayat-alam
    Perfect! Thank you so much.

    I did not know about the Gutenberg block – that is an even better solution to the problem! I was not using Gutenberg but I can turn it on for the download pages – a perfect solution.

    Thread Starter njwp

    (@njwp)

    resolved

    Plugin Contributor Shafaet Alam

    (@shafayat-alam)

    Awesome :).
    [and a request] if you get some free moments, please give us a 5* review https://ww.wp.xz.cn/support/plugin/download-manager/reviews/?rate=5#new-post. It will inspire us a lot.

    Thread Starter njwp

    (@njwp)

    no problem – I’ve left you a review

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

The topic ‘can you put a comment in shortcode’ is closed to new replies.