• 1

Read this first!

We do not monitor these forums. The forum is provided to exchange information and experience with other users ONLY. Forum responses are not guaranteed.

However, please submit a ticket if you have an active subscription and wish to receive support. Our ticketing system is the only way of getting in touch with RSJoomla! and receiving the official RSJoomla! Customer Support.

For more information, the Support Policy is located here.

Thank you!

TOPIC: Dynamically count the number of submissions

Dynamically count the number of submissions 1 week 2 days ago #39391

Hi,

I would like to dynamically count the number of submissions to a specific form on a site.

I went through the forum and found this and combined it to below:
<?php
$db = JFactory::getDbo();
$user = JFactory::getUser();
 
$db->setQuery("SELECT COUNT(*) FROM #__rsform_submissions WHERE `FormId`='".(int) $formId."'");
$submissions = $db->loadResult();
echo $submissions;
?>

First question: would this work?

Second question: how do I make this dynamic? Id est: now it will probably only update on reloading the page. Can I make it such that it will auto-refresh?

Thanks!

Sander
The administrator has disabled public write access.
  • 1

Read this first!

We do not monitor these forums. The forum is provided to exchange information and experience with other users ONLY. Forum responses are not guaranteed.

However, please submit a ticket if you have an active subscription and wish to receive support. Our ticketing system is the only way of getting in touch with RSJoomla! and receiving the official RSJoomla! Customer Support.

For more information, the Support Policy is located here.

Thank you!