• Resolved danielbtherafin

    (@danielbtherafin)


    Hello.

    I want to display a dynamic total of the table “Seeds Scattered” on the homepage of the website. Right now, for testing, I have two inputs, each set to 5. I want the function to display “10” on the homepage of the website for end user, real-time tracking of the campaign. This function would update dynamically whenever a new input is calculated. So if a user filled the form and put “7” for “seeds scattered”, the number would calculate 10+7 and then display “17”.

    How do I do this? I have tried everything I can think of.

    The page I need help with: [log in to see the link]

Viewing 7 replies - 1 through 7 (of 7 total)
  • Plugin Author Roland Barker

    (@xnau)

    There is a shortcode for this purpose, the “total” shortcode…take a look at the documentation for the details:

    The Total Shortcode

    Thread Starter danielbtherafin

    (@danielbtherafin)

    Thanks for your quick response. That method is a bit confusing to me… I read the pdb-total-default.php file but I’m wondering if this function can be done with a simple shortcode? When I used [pdb_total filter=”seedsscattered=yes”] the total calculated referred to the amount of records and not the sum of the column within the record. Do you know how I might change it to do what I’m describing?

    Plugin Author Roland Barker

    (@xnau)

    The summing function requires that you tell it which field you want summed…for example:

    [pdb_total filter="seedsscattered=yes" fields="seedsscattered" ]

    It is a bit complex. I know, but it’s designed to cover most of the different ways people need to use the shortcode.

    Thread Starter danielbtherafin

    (@danielbtherafin)

    Thanks again. I used that shortcode as written and it shows “0” even though I have three test records that should total 20 at the moment.

    Records shown are here:

    http://southlandcampaign.com/about/

    And the shortcode I’m putting appears here directly above the percentage load bar at the bottom of the page. http://southlandcampaign.com/

    Not sure why it isn’t working…

    Plugin Author Roland Barker

    (@xnau)

    The only thing I can think to check is that the values in those fields must only be numbers.

    Thread Starter danielbtherafin

    (@danielbtherafin)

    They are only numbers. Is there any way you can look into my webpage to find the issue?

    Thread Starter danielbtherafin

    (@danielbtherafin)

    I have finally figured it out. The shortcode is this:

    [pdb_total filter=”seeds_scattered-filter=yes” fields=”seeds_scattered”]

    Thank you for your help!

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

The topic ‘Display Count Total Sum’ is closed to new replies.