google_forms/application/views/responses/response_summary.php

18 lines
625 B
PHP
Raw Normal View History

2024-08-09 12:04:48 +00:00
<div class="container">
<h2>Select a form to view summary</h2>
<?php foreach ($forms as $form) : ?>
<div class="form-section" data-form-id="<?php echo $form->id; ?>">
<h3><?php echo $form->title; ?></h3>
</div>
<?php endforeach; ?>
</div>
<script>
document.querySelectorAll('.form-section').forEach(function(section) {
section.addEventListener('click', function() {
var formId = this.getAttribute('data-form-id');
window.location.href = '<?php echo base_url('response_submit/response_summary_by_form/'); ?>' + formId;
});
});
</script>