Help with While loops |
5/2/2019 3:48:35 PM |
PHPRunner General questions | |
M
Melanie authorDevClub member
Sorry all - I am not a php programmer which is why I love PHPRunner, but sometimes I do want something custom. I have 3 records that I want to use in sending an e-mail when the user clicks a button (after choosing the 3 records) so on the list page I added a custom button and using the documentation I can get the e-mail to send and it includes the 3 records, but I want some data for only 1 of the records to just repeat once - |
|
M
|
Melanie authorDevClub member 5/2/2019 |
OK so I am seeing now that getnextselectedrecord is not really a loop but an array? And that I don't have access to the fields ($data) outside of the {} so hmmm is there some way to do this? Can I somehow get access to the key of the first record and then grab the data to use somehow? |
![]() |
Admin 5/2/2019 |
The main question here - if three records were selected, where the following is coming from? hotel name |
M
|
Melanie authorDevClub member 5/3/2019 |
The main question here - if three records were selected, where the following is coming from? hotel name
|
![]() |
Admin 5/3/2019 |
Try something like this: $email_msg = ""; |
M
|
Melanie authorDevClub member 5/3/2019 |
Try something like this: $email_msg = "";
|
M
|
Mark Kramer 5/5/2019 |
Closer I think with the above I got this: 05-03-2019 Holiday Inn & Suites Hotel Bellingham Bellingham, WA 98226 RE: Reservation Request We would like to make the following reservations on Direct Bill for the room & tax only, at the rate of 05-03-2019 Holiday Inn & Suites Hotel Bellingham Bellingham, WA 98226 RE: Reservation Request We would like to make the following reservations on Direct Bill for the room & tax only, at the rate of 05-03-2019 Holiday Inn & Suites Hotel Bellingham Bellingham, WA 98226 RE: Reservation Request We would like to make the following reservations on Direct Bill for the room & tax only, at the rate of Name: Peder, person Check In: 05-18-2019 Check Out: 05-20-2019 So I got only 1 reservation record, but got the hotel name etc 3 times (there are 3 reservation records).
|