Extended Form Questions

Permalink Browser Info Environment
Hi

Firstly Thanks for the great add-on it has really enabled the client to get 95% of the way to their ideal, however the last 5% is causing a headache for me and I hope you can help.

A few Questions

1. Can the user be sent an email confirmation (how?)
2. In the results the user name is shown can we change this to the users email address?
3. On the form result page how can we add a date range filter to sort the data?
4. The user record has a custom attribute of Comp_Name can we populate one of the form fields with this?

Thats it for now, please let me know if we should pay for some of your time to help us with the above.

Best

Justin

Type: Discussion
Status: New
darwinje
View Replies:
DeWebmakers replied on at Permalink Reply
DeWebmakers
Thank you for the compliment.

Answers:

1. If you mean the user as the logged in user, then no. The only mail that is being send is to te formfiller (if e-mailaddress field is in the form).

2. That could be changed. The userID is saved in the DB, so I (or you) could use the function to get the users e-mailadress...

3. I see what you mean, it would be nice to add that filter.

4. This is a tricky one. To do this we must link the user details to the formfields. Not so easy. You are the second person that asks for this feature. I'll think about it, and maybe add it in future updates.
darwinje replied on at Permalink Reply
darwinje
Thanks for the reply

Is it possible to engage some of your time to get the above sorted? These are rather urgent for my client

Best

Justin
DeWebmakers replied on at Permalink Reply
DeWebmakers
I would like to change this for you specificly but currently I'm very busy.

If you want these changes I could do them for you in Januari not any sooner...
darwinje replied on at Permalink Reply
darwinje
Hi Buddy,

I am putting this in to the controller php to add the user email to the database record and it is appending the row with the ID but not with the email value what am I doing wrong?

if (intval($this->captureUser) != 0 && intval($_SESSION['uID']) != 0) 
         {      
            $v=array('9997', $answerSetID, $_SESSION['uEmail'], $answerLong);
            $q="insert into {$this->btAnswersTablename} (msqID, asID, answer, answerLong) values (?, ?, ?, ?)";
            $db->query($q,$v);   
            $v=array('9998', $answerSetID, $_SESSION['uID'], $answerLong);
            $q="insert into {$this->btAnswersTablename} (msqID, asID, answer, answerLong) values (?, ?, ?, ?)";
            $db->query($q,$v);
            $v=array('9999', $answerSetID, $_SESSION['uName'], $answerLong);
            $q="insert into {$this->btAnswersTablename} (msqID, asID, answer, answerLong) values (?, ?, ?, ?)";
            $db->query($q,$v);
            $questionAnswerPairs[9997]['question'] = 'uEmail';
            $questionAnswerPairs[9997]['type'] = 'field';
            $questionAnswerPairs[9997]['answer'] = $_SESSION['uEmail'].' ('.$_SESSION['uID'].')';            
            $counter++;


Thanks

Happy xmas

Justin
DeWebmakers replied on at Permalink Reply
DeWebmakers
Does it save the new line to the database?

Check the single_pages/dashboard/reports/extended_form.php, there are some lines there who need to be changed.

Go to line 155, you'll figure it out.

Regards
darwinje replied on at Permalink Reply
darwinje
Hi

Thanks for your reply,

Yes the field gets added to the database but without a value is the code above correct? is there any other file I need to edit to get this all working once this is done I will be ready to assign this to the site! and give a review ;)

THanks for your help thus far I hope you have had a great holiday break!

Best

Justin
DeWebmakers replied on at Permalink Reply
DeWebmakers
So, the field is insert into the database but the data is empty? So the user_email isn't saved into the database.

Did you change the dashboard file?
darwinje replied on at Permalink Reply
darwinje
Hi

Yes I did what you advised but to no avail :( any help you could offer would be great I am under a little pressure now to get this working

Cheers buddy

Justin
DeWebmakers replied on at Permalink Reply
DeWebmakers
Hi,

I think I made a mistake in the explanation...

I told you to edit the single_page at line 155, but it should be line 177, there you see the following code:

if($answerSet['answers'][9999]['answer'] != '') {
               $questions[9999] = 'user'; ?>
<tr class="extraQuestionRow<?php echo $answerSetId?> noDisplay">
                  <td width="33%">User</td>
                  <td><a href="<?php echo $this->url('/dashboard/users/search?uID=' . $answerSet['answers'][9998]['answer']) ?>"><?php echo $answerSet['answers'][9999]['answer']; ?></a></td>               </tr>
<?php } ?>


Add your new field here. This should do the trick!

concrete5 Environment Information

Browser User-Agent String

Hide Post Content

This will replace the post content with the message: "Content has been removed by an Administrator"

Hide Content

Request Refund

You have not specified a license for this support ticket. You must have a valid license assigned to a support ticket to request a refund.