Re: [PacketFence-users] Storing extra information in the database from a guest portal page
David, That is very interesting/useful information! I’ll make sure to take good note of this while reworking the self-registration workflow. Cheers! dw. -- Derek Wuelfrath dwuelfr...@inverse.ca :: +1.514.447.4918 (x110) :: +1.866.353.6153 (x110) Inverse inc. (www.inverse.ca) :: Leaders behind SOGo (www.sogo.nu) and PacketFence (www.packetfence.org) On May 14, 2015 at 08:25:22, David Murrell (dmurr...@waikato.ac.nz) wrote: Hi, I'm fairly driven by what marketing wants this time, but for things like conference registrations, I'm going to be definitely looking into the OAuth/SSO options. Will be keeping an interested eye out for what you guys come up with though :) Another couple of learnings, thanks to our webteam here: If the span field has an inner label field that has a for reference in it, tapping/clicking on the label text will move the cursor to the associated input box, without having to actually tap/click in the box. Here's whats on our portal page now i've messed with it: spanlabel for=phonePhone Number/label/span input class=field autocomplete=on id=phone name=phone type=text value=[% phone | html %] / Adding the autocomplete pops up a possibly helpful previously entered value as well. For me, for this phone value, its my home phone number, but it might save some people some typing + add accuracy. In terms of an array being added to the database for a custom field, I'm pretty sure I've found the problem area. This isn't a proper patch, because its against possibly the devel branch, but it allowed me to submit an array of answers via a multiselect into the database: I've essentially just replaced inside the foreach loop with a ref test + crappy handling. A push + join probably would be neater, but I tend to write for me a few years in the future looking at my code and going what idiot.. oh.. man Catalyst::Request has details, but the old $request-params call is deprecated, and only returns the first value of a array if called in a scalar context. Figuring out if something is an array without knowing for a way of testing for the array is difficult. I opted for the call it as a reference and test approach. Now: (line 476) in /usr/local/pf/html/captive-portal/lib/captiveportal/PacketFence/Controller/Signup.pm sub setupSelfRegistrationSession : Private { my ( $self, $c ) = @_; my $request = $c-request; foreach my $field (@PERSON_FIELDS) { if(ref($request-parameters-{$field}) eq SCALAR){ $c-session-{$field} = $request-parameters-{$field}; } elsif(ref($request-parameters-{$field}) eq ARRAY){ my $string = ; foreach my $value (@{$request-parameters-{$field}}){ $string .= $value.,; } #get rid of trailing comma chop $string; $c-session-{$field} = $string; } else { #not sure else needed, but might be. $logger-error(ERROR: .__PACKAGE__.::setupSelfRegistrationSession storing first scalar for unhandled datatype for field $field); $c-session-{$field} = $request-parameters-{$field}; } } my $phone = $request-param(phone); $c-session-{company} = $request-param(organization); $c-session-{telephone} = pf::web::util::validate_phone_number( $phone ); $c-session-{phone} = pf::web::util::validate_phone_number( $phone ); $c-session-{sponsor} = lc( $request-param(sponsor_email) ); # guest pid is configurable (defaults to email) $c-session-{guest_pid} = $c-session-{ $Config{'guests_self_registration'}{'guest_pid'} }; } Was: sub setupSelfRegistrationSession : Private { my ( $self, $c ) = @_; my $request = $c-request; foreach my $field (@PERSON_FIELDS) { $c-session-{$field} = $request-param($field); } my $phone = $request-param(phone); $c-session-{company} = $request-param(organization); $c-session-{telephone} = pf::web::util::validate_phone_number( $phone ); $c-session-{phone} = pf::web::util::validate_phone_number( $phone ); $c-session-{sponsor} = lc( $request-param(sponsor_email) ); # guest pid is configurable (defaults to email) $c-session-{guest_pid} = $c-session-{ $Config{'guests_self_registration'}{'guest_pid'} }; } Hope this proves useful, Cheers, David On Thu, May 14, 2015 at 1:34 AM, Derek Wuelfrath dwuelfr...@inverse.ca wrote: David, Peripherally of interest, perhaps: An issue we ran into when doing a bit of user testing: people moaned about having to fill in too many fields. An acquaintance of mine commented on this, and said that they've got research saying that the max fields people hit before they get sick of entering data and start giving up is 3. Interesting! Thinking the same way, I hate having to fill in a lot of info simply to get access to a service. More and more websites are offering SSO based on social networks accounts, or simple
Re: [PacketFence-users] Storing extra information in the database from a guest portal page
Hi, I'm fairly driven by what marketing wants this time, but for things like conference registrations, I'm going to be definitely looking into the OAuth/SSO options. Will be keeping an interested eye out for what you guys come up with though :) Another couple of learnings, thanks to our webteam here: If the span field has an inner label field that has a for reference in it, tapping/clicking on the label text will move the cursor to the associated input box, without having to actually tap/click in the box. Here's whats on our portal page now i've messed with it: spanlabel for=phonePhone Number/label/span input class=field autocomplete=on id=phone name=phone type=text value=[% phone | html %] / Adding the autocomplete pops up a possibly helpful previously entered value as well. For me, for this phone value, its my home phone number, but it might save some people some typing + add accuracy. In terms of an array being added to the database for a custom field, I'm pretty sure I've found the problem area. This isn't a proper patch, because its against possibly the devel branch, but it allowed me to submit an array of answers via a multiselect into the database: I've essentially just replaced inside the foreach loop with a ref test + crappy handling. A push + join probably would be neater, but I tend to write for me a few years in the future looking at my code and going what idiot.. oh.. man Catalyst::Request has details, but the old $request-params call is deprecated, and only returns the first value of a array if called in a scalar context. Figuring out if something is an array without knowing for a way of testing for the array is difficult. I opted for the call it as a reference and test approach. Now: (line 476) in /usr/local/pf/html/captive-portal/lib/captiveportal/PacketFence/Controller/Signup.pm sub setupSelfRegistrationSession : Private { my ( $self, $c ) = @_; my $request = $c-request; foreach my $field (@PERSON_FIELDS) { if(ref($request-parameters-{$field}) eq SCALAR){ $c-session-{$field} = $request-parameters-{$field}; } elsif(ref($request-parameters-{$field}) eq ARRAY){ my $string = ; foreach my $value (@{$request-parameters-{$field}}){ $string .= $value.,; } #get rid of trailing comma chop $string; $c-session-{$field} = $string; } else { #not sure else needed, but might be. $logger-error(ERROR: .__PACKAGE__.::setupSelfRegistrationSession storing first scalar for unhandled datatype for field $field); $c-session-{$field} = $request-parameters-{$field}; } } my $phone = $request-param(phone); $c-session-{company} = $request-param(organization); $c-session-{telephone} = pf::web::util::validate_phone_number( $phone ); $c-session-{phone} = pf::web::util::validate_phone_number( $phone ); $c-session-{sponsor} = lc( $request-param(sponsor_email) ); # guest pid is configurable (defaults to email) $c-session-{guest_pid} = $c-session-{ $Config{'guests_self_registration'}{'guest_pid'} }; } Was: sub setupSelfRegistrationSession : Private { my ( $self, $c ) = @_; my $request = $c-request; foreach my $field (@PERSON_FIELDS) { $c-session-{$field} = $request-param($field); } my $phone = $request-param(phone); $c-session-{company} = $request-param(organization); $c-session-{telephone} = pf::web::util::validate_phone_number( $phone ); $c-session-{phone} = pf::web::util::validate_phone_number( $phone ); $c-session-{sponsor} = lc( $request-param(sponsor_email) ); # guest pid is configurable (defaults to email) $c-session-{guest_pid} = $c-session-{ $Config{'guests_self_registration'}{'guest_pid'} }; } Hope this proves useful, Cheers, David On Thu, May 14, 2015 at 1:34 AM, Derek Wuelfrath dwuelfr...@inverse.ca wrote: David, Peripherally of interest, perhaps: An issue we ran into when doing a bit of user testing: people moaned about having to fill in too many fields. An acquaintance of mine commented on this, and said that they've got research saying that the max fields people hit before they get sick of entering data and start giving up is 3. Interesting! Thinking the same way, I hate having to fill in a lot of info simply to get access to a service. More and more websites are offering SSO based on social networks accounts, or simple email / password field. Like Fabrice said, we are currently in the rework of the self-registration. Phase 1 was to allow custom fields to be displayed and should probably be included in PacketFence 5.1.0. Phase 2 consist in reworking the self-registration completely to remove all unnecessary fields. Cheers! dw. -- Derek Wuelfrath dwuelfr...@inverse.ca :: +1.514.447.4918 (x110) :: +1.866.353.6153 (x110) Inverse inc. (www.inverse.ca) ::
Re: [PacketFence-users] Storing extra information in the database from a guest portal page
David, Peripherally of interest, perhaps: An issue we ran into when doing a bit of user testing: people moaned about having to fill in too many fields. An acquaintance of mine commented on this, and said that they've got research saying that the max fields people hit before they get sick of entering data and start giving up is 3. Interesting! Thinking the same way, I hate having to fill in a lot of info simply to get access to a service. More and more websites are offering SSO based on social networks accounts, or simple email / password field. Like Fabrice said, we are currently in the rework of the self-registration. Phase 1 was to allow custom fields to be displayed and should probably be included in PacketFence 5.1.0. Phase 2 consist in reworking the self-registration completely to remove all unnecessary fields. Cheers! dw. -- Derek Wuelfrath dwuelfr...@inverse.ca :: +1.514.447.4918 (x110) :: +1.866.353.6153 (x110) Inverse inc. (www.inverse.ca) :: Leaders behind SOGo (www.sogo.nu) and PacketFence (www.packetfence.org) On May 11, 2015 at 19:24:26, David Murrell (dmurr...@waikato.ac.nz) wrote: Hi, On this: Also we probably remove name and surname from the default template and this will be part of the mandatory fields configuration Peripherally of interest, perhaps: An issue we ran into when doing a bit of user testing: people moaned about having to fill in too many fields. An acquaintance of mine commented on this, and said that they've got research saying that the max fields people hit before they get sick of entering data and start giving up is 3. For the portal I'm building at the moment, we've turned firstname/lastname into fullname (then stored in firstname), just to try to cut down on the mandatory field count. Cheers, David Regards Fabrice Cheers, David On Fri, May 8, 2015 at 12:37 AM, Fabrice DURAND fdur...@inverse.ca wrote: Hi David, i just did a test on a 4.7 version and there is only 3 conflicts that are really easy to fix. So it's as you want,patch 4.7 or install 5.0.2 and patch it or wait for 5.1. Regards Fabrice Le 2015-05-07 08:06, David Murrell a écrit : Hi, That's awesome. :) I'll apply it tomorrow, and see how it goes. Does it need 5.0.2? Cheers, David On Thu, May 7, 2015 at 11:39 PM, Durand fabrice fdur...@inverse.ca mailto:fdur...@inverse.ca wrote: Hi David, this is exactly what we are working on. We made a branch (fix/mandatory_fields) that fix that. If you want you can try to apply the patch of this branch to your setup (https://patch-diff.githubusercontent.com/raw/inverse-inc/packetfence/pull/516.diff). Also it will be available in the incoming 5.1 release. Regards Fabrice Le 2015-05-06 21:30, David Murrell a écrit : Hi, I'm a bit stuck. For a openday here on campus for prospective students, (using packetfence 4.7.0) marketing wants visting students to have wifi internet access on the day in return for some extra data gathered via a custom portal page. -- this might be important? I'm not using the default portal, but a custom one specific for the day. This is fine. Portal submit + dynamic vlan switch on valid auth + dhcp + dynamic deregister in the gui for bad clients works brilliantly. So brilliantly in fact, I'm going to replace our other radius + eduroam connection handling and NPS wired switch auth backend with it. Where I'm stuck: I'm trying to store extra data from the portal page into the database so that we can give it to marketing to do after-the-event marketing to students. If I add something like this to Portal Profiles and Pages/openday/Files/guest.html: (a contrived example, cough) spanSchool/span input class=field name=custom_field_1 type=custom_field_1 value= /br/ The field pops up on the portal page, I can add data, and mash the register button, and then the custom_field_1 data goes into a black hole somewhere. I can see the page submitting the data via the post request. If I cause the page to not submit by not having all the mandatory fields filled, the custom_field_1 field doesn't include the submitted data in the result page, but the firstname field does. If I extend the mandatory field list to include custom_field_1, then it will show a warning if it does not contain data, but still won't send the submitted data back on the Missing mandatory parameter(s) result page. I see the other data in the form being added to the database, (after enabling TRACE) in the logging files: == logs/packetfence.log == attempt #0 to run query person_add_sql from module person SQL statement (person_add_sql): INSERT INTO person (pid, firstname, lastname, email, telephone, company, address, notes, sponsor, anniversary,
Re: [PacketFence-users] Storing extra information in the database from a guest portal page
Hi, That wasn't me asking about future releases, but good to know anyway :) I've run into another related problem: if posting a multiselect, only the first entry gets pushed into the database. I'm fairly average with Perl, but this Catalyst stuff is well above my skill level. Why a multiselect? Marketing want to capture subjects that prospective student is interested in for targeted marketing stuff. It seems to work well enough after butchering the js and css from https://loudev.com to make it pretty. All I'd be looking for is a pointer at where the POST lands in the code, so I can stick a if/then regexy loop in to concatenate the answers into a single field. Would be happy to share crappy code that I come up with. Thoughts? Cheers, David On Sat, May 9, 2015 at 3:45 AM, Fabrice DURAND fdur...@inverse.ca wrote: Hi David, it's on the way, i did a branch for Trusty Centos7 and Jessy but i have to find time to test that. It will probably be available this summer. regards Fabrice Le 2015-05-08 10:48, holger.patz...@t-systems.com a écrit : Hi Fabrice, do you know if pf5.1 will support ubuntu 14.4 ? thanks, Holger -- Holger Patzelt E-Mail: holger.patz...@t-systems.com -Original Message- From: Fabrice DURAND [mailto:fdur...@inverse.ca] Sent: Thursday, May 07, 2015 3:44 PM To: packetfence-users@lists.sourceforge.net Subject: Re: [PacketFence-users] Storing extra information in the database from a guest portal page Probably in 2 weeks. Le 2015-05-07 09:12, holger.patz...@t-systems.com a écrit : Hi Fabrice, Du you have a planned release date for 5.1, yet? Regards, Holger -Original Message- From: Fabrice DURAND [mailto:fdur...@inverse.ca] Sent: Thursday, May 07, 2015 2:37 PM To: packetfence-users@lists.sourceforge.net Subject: Re: [PacketFence-users] Storing extra information in the database from a guest portal page Hi David, i just did a test on a 4.7 version and there is only 3 conflicts that are really easy to fix. So it's as you want,patch 4.7 or install 5.0.2 and patch it or wait for 5.1. Regards Fabrice Le 2015-05-07 08:06, David Murrell a écrit : Hi, That's awesome. :) I'll apply it tomorrow, and see how it goes. Does it need 5.0.2? Cheers, David On Thu, May 7, 2015 at 11:39 PM, Durand fabrice fdur...@inverse.ca mailto:fdur...@inverse.ca wrote: Hi David, this is exactly what we are working on. We made a branch (fix/mandatory_fields) that fix that. If you want you can try to apply the patch of this branch to your setup ( https://patch-diff.githubusercontent.com/raw/inverse-inc/packetfence/pull/516.diff ). Also it will be available in the incoming 5.1 release. Regards Fabrice Le 2015-05-06 21:30, David Murrell a écrit : Hi, I'm a bit stuck. For a openday here on campus for prospective students, (using packetfence 4.7.0) marketing wants visting students to have wifi internet access on the day in return for some extra data gathered via a custom portal page. -- this might be important? I'm not using the default portal, but a custom one specific for the day. This is fine. Portal submit + dynamic vlan switch on valid auth + dhcp + dynamic deregister in the gui for bad clients works brilliantly. So brilliantly in fact, I'm going to replace our other radius + eduroam connection handling and NPS wired switch auth backend with it. Where I'm stuck: I'm trying to store extra data from the portal page into the database so that we can give it to marketing to do after-the-event marketing to students. If I add something like this to Portal Profiles and Pages/openday/Files/guest.html: (a contrived example, cough) spanSchool/span input class=field name=custom_field_1 type=custom_field_1 value= /br/ The field pops up on the portal page, I can add data, and mash the register button, and then the custom_field_1 data goes into a black hole somewhere. I can see the page submitting the data via the post request. If I cause the page to not submit by not having all the mandatory fields filled, the custom_field_1 field doesn't include the submitted data in the result page, but the firstname field does. If I extend the mandatory field list to include custom_field_1, then it will show a warning if it does not contain data, but still won't send the submitted data back on the Missing mandatory parameter(s) result page. I see the other data in the form being added to the database, (after enabling TRACE) in the logging files: == logs/packetfence.log == attempt #0 to run query person_add_sql from module person SQL statement (person_add_sql): INSERT INTO person
Re: [PacketFence-users] Storing extra information in the database from a guest portal page
Hi, On this: Also we probably remove name and surname from the default template and this will be part of the mandatory fields configuration Peripherally of interest, perhaps: An issue we ran into when doing a bit of user testing: people moaned about having to fill in too many fields. An acquaintance of mine commented on this, and said that they've got research saying that the max fields people hit before they get sick of entering data and start giving up is 3. For the portal I'm building at the moment, we've turned firstname/lastname into fullname (then stored in firstname), just to try to cut down on the mandatory field count. Cheers, David Regards Fabrice Cheers, David On Fri, May 8, 2015 at 12:37 AM, Fabrice DURAND fdur...@inverse.ca wrote: Hi David, i just did a test on a 4.7 version and there is only 3 conflicts that are really easy to fix. So it's as you want,patch 4.7 or install 5.0.2 and patch it or wait for 5.1. Regards Fabrice Le 2015-05-07 08:06, David Murrell a écrit : Hi, That's awesome. :) I'll apply it tomorrow, and see how it goes. Does it need 5.0.2? Cheers, David On Thu, May 7, 2015 at 11:39 PM, Durand fabrice fdur...@inverse.ca mailto:fdur...@inverse.ca wrote: Hi David, this is exactly what we are working on. We made a branch (fix/mandatory_fields) that fix that. If you want you can try to apply the patch of this branch to your setup ( https://patch-diff.githubusercontent.com/raw/inverse-inc/packetfence/pull/516.diff ). Also it will be available in the incoming 5.1 release. Regards Fabrice Le 2015-05-06 21:30, David Murrell a écrit : Hi, I'm a bit stuck. For a openday here on campus for prospective students, (using packetfence 4.7.0) marketing wants visting students to have wifi internet access on the day in return for some extra data gathered via a custom portal page. -- this might be important? I'm not using the default portal, but a custom one specific for the day. This is fine. Portal submit + dynamic vlan switch on valid auth + dhcp + dynamic deregister in the gui for bad clients works brilliantly. So brilliantly in fact, I'm going to replace our other radius + eduroam connection handling and NPS wired switch auth backend with it. Where I'm stuck: I'm trying to store extra data from the portal page into the database so that we can give it to marketing to do after-the-event marketing to students. If I add something like this to Portal Profiles and Pages/openday/Files/guest.html: (a contrived example, cough) spanSchool/span input class=field name=custom_field_1 type=custom_field_1 value= /br/ The field pops up on the portal page, I can add data, and mash the register button, and then the custom_field_1 data goes into a black hole somewhere. I can see the page submitting the data via the post request. If I cause the page to not submit by not having all the mandatory fields filled, the custom_field_1 field doesn't include the submitted data in the result page, but the firstname field does. If I extend the mandatory field list to include custom_field_1, then it will show a warning if it does not contain data, but still won't send the submitted data back on the Missing mandatory parameter(s) result page. I see the other data in the form being added to the database, (after enabling TRACE) in the logging files: == logs/packetfence.log == attempt #0 to run query person_add_sql from module person SQL statement (person_add_sql): INSERT INTO person (pid, firstname, lastname, email, telephone, company, address, notes, sponsor, anniversary, birthday, gender, lang, nickname, cell_phone, work_phone, title, building_number, apartment_number, room_number, custom_field_1, custom_field_2, custom_field_3, custom_field_4, custom_field_5, custom_field_6, custom_field_7, custom_field_8, custom_field_9, portal, source) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?) SQL params (person_add_sql): emailaddr...@gmail.com mailto:emailaddr...@gmail.com, first3, last3, emailaddr...@gmail.com mailto:emailaddr...@gmail.com, 0, org3, null, email activation. Date of arrival: 2015-05-07 12:45:41, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, openday, email person emailaddr...@gmail.com mailto:emailaddr...@gmail.com added This is using the email source as it appears to captures more
Re: [PacketFence-users] Storing extra information in the database from a guest portal page
Hi David, Le 2015-05-08 09:32, David Murrell a écrit : Hi Fabrice, I can happily confirm that the patch worked - thanks :) - I've been able to populate data into the custom_field_[123] columns. Cool :-) I'm assuming that the rej hunks were built from a patch upstream of 5.0.2 and 4.7? I merged the extra but not marked as + code lines , and all seems to be well. Yes, the patch is based on devel branch. There's some weirdness though (and this may be by design?) - the extra form details seem to only be populated for the email source, not the null source. There's also an inconsistency that I haven't quite nailed down about what happens if mandatory fields are filled enabled or not. I think if mandatory isn't ticked, then the extra fields don't get populated. I'll confirm though. We still working on it, we will change a little bit the logic , instead of having a 'use mandatory fields' in authentication source, we will have a select box in the portal profile where you will select the sources who will use mandatory fields. Also we probably remove name and surname from the default template and this will be part of the mandatory fields configuration Regards Fabrice Cheers, David On Fri, May 8, 2015 at 12:37 AM, Fabrice DURAND fdur...@inverse.ca mailto:fdur...@inverse.ca wrote: Hi David, i just did a test on a 4.7 version and there is only 3 conflicts that are really easy to fix. So it's as you want,patch 4.7 or install 5.0.2 and patch it or wait for 5.1. Regards Fabrice Le 2015-05-07 08:06, David Murrell a écrit : Hi, That's awesome. :) I'll apply it tomorrow, and see how it goes. Does it need 5.0.2? Cheers, David On Thu, May 7, 2015 at 11:39 PM, Durand fabrice fdur...@inverse.ca mailto:fdur...@inverse.ca mailto:fdur...@inverse.ca mailto:fdur...@inverse.ca wrote: Hi David, this is exactly what we are working on. We made a branch (fix/mandatory_fields) that fix that. If you want you can try to apply the patch of this branch to your setup (https://patch-diff.githubusercontent.com/raw/inverse-inc/packetfence/pull/516.diff). Also it will be available in the incoming 5.1 release. Regards Fabrice Le 2015-05-06 21:30, David Murrell a écrit : Hi, I'm a bit stuck. For a openday here on campus for prospective students, (using packetfence 4.7.0) marketing wants visting students to have wifi internet access on the day in return for some extra data gathered via a custom portal page. -- this might be important? I'm not using the default portal, but a custom one specific for the day. This is fine. Portal submit + dynamic vlan switch on valid auth + dhcp + dynamic deregister in the gui for bad clients works brilliantly. So brilliantly in fact, I'm going to replace our other radius + eduroam connection handling and NPS wired switch auth backend with it. Where I'm stuck: I'm trying to store extra data from the portal page into the database so that we can give it to marketing to do after-the-event marketing to students. If I add something like this to Portal Profiles and Pages/openday/Files/guest.html: (a contrived example, cough) spanSchool/span input class=field name=custom_field_1 type=custom_field_1 value= /br/ The field pops up on the portal page, I can add data, and mash the register button, and then the custom_field_1 data goes into a black hole somewhere. I can see the page submitting the data via the post request. If I cause the page to not submit by not having all the mandatory fields filled, the custom_field_1 field doesn't include the submitted data in the result page, but the firstname field does. If I extend the mandatory field list to include custom_field_1, then it will show a warning if it does not contain data, but still won't send the submitted data back on the Missing mandatory parameter(s) result page. I see the other data in the form being added to the database, (after enabling TRACE) in the logging files: == logs/packetfence.log == attempt #0 to run query person_add_sql from module person SQL statement (person_add_sql): INSERT INTO person (pid, firstname, lastname, email, telephone, company, address, notes, sponsor, anniversary, birthday, gender, lang, nickname, cell_phone,
Re: [PacketFence-users] Storing extra information in the database from a guest portal page
Hi Fabrice, I can happily confirm that the patch worked - thanks :) - I've been able to populate data into the custom_field_[123] columns. I'm assuming that the rej hunks were built from a patch upstream of 5.0.2 and 4.7? I merged the extra but not marked as + code lines , and all seems to be well. There's some weirdness though (and this may be by design?) - the extra form details seem to only be populated for the email source, not the null source. There's also an inconsistency that I haven't quite nailed down about what happens if mandatory fields are filled enabled or not. I think if mandatory isn't ticked, then the extra fields don't get populated. I'll confirm though. Cheers, David On Fri, May 8, 2015 at 12:37 AM, Fabrice DURAND fdur...@inverse.ca wrote: Hi David, i just did a test on a 4.7 version and there is only 3 conflicts that are really easy to fix. So it's as you want,patch 4.7 or install 5.0.2 and patch it or wait for 5.1. Regards Fabrice Le 2015-05-07 08:06, David Murrell a écrit : Hi, That's awesome. :) I'll apply it tomorrow, and see how it goes. Does it need 5.0.2? Cheers, David On Thu, May 7, 2015 at 11:39 PM, Durand fabrice fdur...@inverse.ca mailto:fdur...@inverse.ca wrote: Hi David, this is exactly what we are working on. We made a branch (fix/mandatory_fields) that fix that. If you want you can try to apply the patch of this branch to your setup ( https://patch-diff.githubusercontent.com/raw/inverse-inc/packetfence/pull/516.diff ). Also it will be available in the incoming 5.1 release. Regards Fabrice Le 2015-05-06 21:30, David Murrell a écrit : Hi, I'm a bit stuck. For a openday here on campus for prospective students, (using packetfence 4.7.0) marketing wants visting students to have wifi internet access on the day in return for some extra data gathered via a custom portal page. -- this might be important? I'm not using the default portal, but a custom one specific for the day. This is fine. Portal submit + dynamic vlan switch on valid auth + dhcp + dynamic deregister in the gui for bad clients works brilliantly. So brilliantly in fact, I'm going to replace our other radius + eduroam connection handling and NPS wired switch auth backend with it. Where I'm stuck: I'm trying to store extra data from the portal page into the database so that we can give it to marketing to do after-the-event marketing to students. If I add something like this to Portal Profiles and Pages/openday/Files/guest.html: (a contrived example, cough) spanSchool/span input class=field name=custom_field_1 type=custom_field_1 value= /br/ The field pops up on the portal page, I can add data, and mash the register button, and then the custom_field_1 data goes into a black hole somewhere. I can see the page submitting the data via the post request. If I cause the page to not submit by not having all the mandatory fields filled, the custom_field_1 field doesn't include the submitted data in the result page, but the firstname field does. If I extend the mandatory field list to include custom_field_1, then it will show a warning if it does not contain data, but still won't send the submitted data back on the Missing mandatory parameter(s) result page. I see the other data in the form being added to the database, (after enabling TRACE) in the logging files: == logs/packetfence.log == attempt #0 to run query person_add_sql from module person SQL statement (person_add_sql): INSERT INTO person (pid, firstname, lastname, email, telephone, company, address, notes, sponsor, anniversary, birthday, gender, lang, nickname, cell_phone, work_phone, title, building_number, apartment_number, room_number, custom_field_1, custom_field_2, custom_field_3, custom_field_4, custom_field_5, custom_field_6, custom_field_7, custom_field_8, custom_field_9, portal, source) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?) SQL params (person_add_sql): emailaddr...@gmail.com mailto:emailaddr...@gmail.com, first3, last3, emailaddr...@gmail.com mailto:emailaddr...@gmail.com, 0, org3, null, email activation. Date of arrival: 2015-05-07 12:45:41, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, openday, email person emailaddr...@gmail.com mailto:emailaddr...@gmail.com added This is using the email source as it appears to captures more
Re: [PacketFence-users] Storing extra information in the database from a guest portal page
Hi David, it's on the way, i did a branch for Trusty Centos7 and Jessy but i have to find time to test that. It will probably be available this summer. regards Fabrice Le 2015-05-08 10:48, holger.patz...@t-systems.com a écrit : Hi Fabrice, do you know if pf5.1 will support ubuntu 14.4 ? thanks, Holger -- Holger Patzelt E-Mail: holger.patz...@t-systems.com -Original Message- From: Fabrice DURAND [mailto:fdur...@inverse.ca] Sent: Thursday, May 07, 2015 3:44 PM To: packetfence-users@lists.sourceforge.net Subject: Re: [PacketFence-users] Storing extra information in the database from a guest portal page Probably in 2 weeks. Le 2015-05-07 09:12, holger.patz...@t-systems.com a écrit : Hi Fabrice, Du you have a planned release date for 5.1, yet? Regards, Holger -Original Message- From: Fabrice DURAND [mailto:fdur...@inverse.ca] Sent: Thursday, May 07, 2015 2:37 PM To: packetfence-users@lists.sourceforge.net Subject: Re: [PacketFence-users] Storing extra information in the database from a guest portal page Hi David, i just did a test on a 4.7 version and there is only 3 conflicts that are really easy to fix. So it's as you want,patch 4.7 or install 5.0.2 and patch it or wait for 5.1. Regards Fabrice Le 2015-05-07 08:06, David Murrell a écrit : Hi, That's awesome. :) I'll apply it tomorrow, and see how it goes. Does it need 5.0.2? Cheers, David On Thu, May 7, 2015 at 11:39 PM, Durand fabrice fdur...@inverse.ca mailto:fdur...@inverse.ca wrote: Hi David, this is exactly what we are working on. We made a branch (fix/mandatory_fields) that fix that. If you want you can try to apply the patch of this branch to your setup (https://patch-diff.githubusercontent.com/raw/inverse-inc/packetfence/pull/516.diff). Also it will be available in the incoming 5.1 release. Regards Fabrice Le 2015-05-06 21:30, David Murrell a écrit : Hi, I'm a bit stuck. For a openday here on campus for prospective students, (using packetfence 4.7.0) marketing wants visting students to have wifi internet access on the day in return for some extra data gathered via a custom portal page. -- this might be important? I'm not using the default portal, but a custom one specific for the day. This is fine. Portal submit + dynamic vlan switch on valid auth + dhcp + dynamic deregister in the gui for bad clients works brilliantly. So brilliantly in fact, I'm going to replace our other radius + eduroam connection handling and NPS wired switch auth backend with it. Where I'm stuck: I'm trying to store extra data from the portal page into the database so that we can give it to marketing to do after-the-event marketing to students. If I add something like this to Portal Profiles and Pages/openday/Files/guest.html: (a contrived example, cough) spanSchool/span input class=field name=custom_field_1 type=custom_field_1 value= /br/ The field pops up on the portal page, I can add data, and mash the register button, and then the custom_field_1 data goes into a black hole somewhere. I can see the page submitting the data via the post request. If I cause the page to not submit by not having all the mandatory fields filled, the custom_field_1 field doesn't include the submitted data in the result page, but the firstname field does. If I extend the mandatory field list to include custom_field_1, then it will show a warning if it does not contain data, but still won't send the submitted data back on the Missing mandatory parameter(s) result page. I see the other data in the form being added to the database, (after enabling TRACE) in the logging files: == logs/packetfence.log == attempt #0 to run query person_add_sql from module person SQL statement (person_add_sql): INSERT INTO person (pid, firstname, lastname, email, telephone, company, address, notes, sponsor, anniversary, birthday, gender, lang, nickname, cell_phone, work_phone, title, building_number, apartment_number, room_number, custom_field_1, custom_field_2, custom_field_3, custom_field_4, custom_field_5, custom_field_6, custom_field_7, custom_field_8, custom_field_9, portal, source) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?) SQL params (person_add_sql): emailaddr...@gmail.com mailto:emailaddr...@gmail.com, first3, last3, emailaddr...@gmail.com mailto:emailaddr...@gmail.com, 0, org3, null, email activation. Date of arrival: 2015-05-07 12:45:41, null, null, null, null, null, null, null, null, null, null, null, null, null, null
Re: [PacketFence-users] Storing extra information in the database from a guest portal page
Hi David, it's on the way, i did a branch for Trusty Centos7 and Jessy but i have to find time to test that. It will probably be available this summer. regards Fabrice Le 2015-05-08 10:48, holger.patz...@t-systems.com a écrit : Hi Fabrice, do you know if pf5.1 will support ubuntu 14.4 ? thanks, Holger -- Holger Patzelt E-Mail: holger.patz...@t-systems.com -Original Message- From: Fabrice DURAND [mailto:fdur...@inverse.ca] Sent: Thursday, May 07, 2015 3:44 PM To: packetfence-users@lists.sourceforge.net Subject: Re: [PacketFence-users] Storing extra information in the database from a guest portal page Probably in 2 weeks. Le 2015-05-07 09:12, holger.patz...@t-systems.com a écrit : Hi Fabrice, Du you have a planned release date for 5.1, yet? Regards, Holger -Original Message- From: Fabrice DURAND [mailto:fdur...@inverse.ca] Sent: Thursday, May 07, 2015 2:37 PM To: packetfence-users@lists.sourceforge.net Subject: Re: [PacketFence-users] Storing extra information in the database from a guest portal page Hi David, i just did a test on a 4.7 version and there is only 3 conflicts that are really easy to fix. So it's as you want,patch 4.7 or install 5.0.2 and patch it or wait for 5.1. Regards Fabrice Le 2015-05-07 08:06, David Murrell a écrit : Hi, That's awesome. :) I'll apply it tomorrow, and see how it goes. Does it need 5.0.2? Cheers, David On Thu, May 7, 2015 at 11:39 PM, Durand fabrice fdur...@inverse.ca mailto:fdur...@inverse.ca wrote: Hi David, this is exactly what we are working on. We made a branch (fix/mandatory_fields) that fix that. If you want you can try to apply the patch of this branch to your setup (https://patch-diff.githubusercontent.com/raw/inverse-inc/packetfence/pull/516.diff). Also it will be available in the incoming 5.1 release. Regards Fabrice Le 2015-05-06 21:30, David Murrell a écrit : Hi, I'm a bit stuck. For a openday here on campus for prospective students, (using packetfence 4.7.0) marketing wants visting students to have wifi internet access on the day in return for some extra data gathered via a custom portal page. -- this might be important? I'm not using the default portal, but a custom one specific for the day. This is fine. Portal submit + dynamic vlan switch on valid auth + dhcp + dynamic deregister in the gui for bad clients works brilliantly. So brilliantly in fact, I'm going to replace our other radius + eduroam connection handling and NPS wired switch auth backend with it. Where I'm stuck: I'm trying to store extra data from the portal page into the database so that we can give it to marketing to do after-the-event marketing to students. If I add something like this to Portal Profiles and Pages/openday/Files/guest.html: (a contrived example, cough) spanSchool/span input class=field name=custom_field_1 type=custom_field_1 value= /br/ The field pops up on the portal page, I can add data, and mash the register button, and then the custom_field_1 data goes into a black hole somewhere. I can see the page submitting the data via the post request. If I cause the page to not submit by not having all the mandatory fields filled, the custom_field_1 field doesn't include the submitted data in the result page, but the firstname field does. If I extend the mandatory field list to include custom_field_1, then it will show a warning if it does not contain data, but still won't send the submitted data back on the Missing mandatory parameter(s) result page. I see the other data in the form being added to the database, (after enabling TRACE) in the logging files: == logs/packetfence.log == attempt #0 to run query person_add_sql from module person SQL statement (person_add_sql): INSERT INTO person (pid, firstname, lastname, email, telephone, company, address, notes, sponsor, anniversary, birthday, gender, lang, nickname, cell_phone, work_phone, title, building_number, apartment_number, room_number, custom_field_1, custom_field_2, custom_field_3, custom_field_4, custom_field_5, custom_field_6, custom_field_7, custom_field_8, custom_field_9, portal, source) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?) SQL params (person_add_sql): emailaddr...@gmail.com mailto:emailaddr...@gmail.com, first3, last3, emailaddr...@gmail.com mailto:emailaddr...@gmail.com, 0, org3, null, email activation. Date of arrival: 2015-05-07 12:45:41, null, null, null, null, null, null, null, null, null, null, null, null, null, null
Re: [PacketFence-users] Storing extra information in the database from a guest portal page
Hi David, this is exactly what we are working on. We made a branch (fix/mandatory_fields) that fix that. If you want you can try to apply the patch of this branch to your setup (https://patch-diff.githubusercontent.com/raw/inverse-inc/packetfence/pull/516.diff). Also it will be available in the incoming 5.1 release. Regards Fabrice Le 2015-05-06 21:30, David Murrell a écrit : Hi, I'm a bit stuck. For a openday here on campus for prospective students, (using packetfence 4.7.0) marketing wants visting students to have wifi internet access on the day in return for some extra data gathered via a custom portal page. -- this might be important? I'm not using the default portal, but a custom one specific for the day. This is fine. Portal submit + dynamic vlan switch on valid auth + dhcp + dynamic deregister in the gui for bad clients works brilliantly. So brilliantly in fact, I'm going to replace our other radius + eduroam connection handling and NPS wired switch auth backend with it. Where I'm stuck: I'm trying to store extra data from the portal page into the database so that we can give it to marketing to do after-the-event marketing to students. If I add something like this to Portal Profiles and Pages/openday/Files/guest.html: (a contrived example, cough) spanSchool/span input class=field name=custom_field_1 type=custom_field_1 value= /br/ The field pops up on the portal page, I can add data, and mash the register button, and then the custom_field_1 data goes into a black hole somewhere. I can see the page submitting the data via the post request. If I cause the page to not submit by not having all the mandatory fields filled, the custom_field_1 field doesn't include the submitted data in the result page, but the firstname field does. If I extend the mandatory field list to include custom_field_1, then it will show a warning if it does not contain data, but still won't send the submitted data back on the Missing mandatory parameter(s) result page. I see the other data in the form being added to the database, (after enabling TRACE) in the logging files: == logs/packetfence.log == attempt #0 to run query person_add_sql from module person SQL statement (person_add_sql): INSERT INTO person (pid, firstname, lastname, email, telephone, company, address, notes, sponsor, anniversary, birthday, gender, lang, nickname, cell_phone, work_phone, title, building_number, apartment_number, room_number, custom_field_1, custom_field_2, custom_field_3, custom_field_4, custom_field_5, custom_field_6, custom_field_7, custom_field_8, custom_field_9, portal, source) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?) SQL params (person_add_sql): emailaddr...@gmail.com mailto:emailaddr...@gmail.com, first3, last3, emailaddr...@gmail.com mailto:emailaddr...@gmail.com, 0, org3, null, email activation. Date of arrival: 2015-05-07 12:45:41, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, openday, email person emailaddr...@gmail.com mailto:emailaddr...@gmail.com added This is using the email source as it appears to captures more data, not the null provisioner. - it also causes the guest.html section of the portal to be used, rather than the login.html pages. I don't quite understand that mapping, either. Any help would be much appreciated, Thanks in advance. Cheers, David Murrell Systems Engineer - Linux ITS Infrastructure University of Waikato, NZ Other files that may be of use: [root@pktfence-guest pf]# cat conf/provisioning.conf [accept] type=accept description=accept provisioner oses= category=guest [openday] filter=ssid:Open Day mandatory_fields=email,firstname,lastname,organization,phone,custom_field_1 provisioners=accept always_use_redirecturl=enabled redirecturl=http://www.waikato.ac.nz sources=email logo=/content/images/coat-of-arms.png dot1x_recompute_role_from_portal=0 filter_match_style=all reuse_dot1x_credentials=0 -- One dashboard for servers and applications across Physical-Virtual-Cloud Widest out-of-the-box monitoring support with 50+ applications Performance metrics, stats and reports that give you Actionable Insights Deep dive visibility with transaction tracing using APM Insight. http://ad.doubleclick.net/ddm/clk/290420510;117567292;y ___ PacketFence-users mailing list PacketFence-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/packetfence-users -- One dashboard for servers and applications across Physical-Virtual-Cloud Widest out-of-the-box monitoring support with 50+
Re: [PacketFence-users] Storing extra information in the database from a guest portal page
Hi David, i just did a test on a 4.7 version and there is only 3 conflicts that are really easy to fix. So it's as you want,patch 4.7 or install 5.0.2 and patch it or wait for 5.1. Regards Fabrice Le 2015-05-07 08:06, David Murrell a écrit : Hi, That's awesome. :) I'll apply it tomorrow, and see how it goes. Does it need 5.0.2? Cheers, David On Thu, May 7, 2015 at 11:39 PM, Durand fabrice fdur...@inverse.ca mailto:fdur...@inverse.ca wrote: Hi David, this is exactly what we are working on. We made a branch (fix/mandatory_fields) that fix that. If you want you can try to apply the patch of this branch to your setup (https://patch-diff.githubusercontent.com/raw/inverse-inc/packetfence/pull/516.diff). Also it will be available in the incoming 5.1 release. Regards Fabrice Le 2015-05-06 21:30, David Murrell a écrit : Hi, I'm a bit stuck. For a openday here on campus for prospective students, (using packetfence 4.7.0) marketing wants visting students to have wifi internet access on the day in return for some extra data gathered via a custom portal page. -- this might be important? I'm not using the default portal, but a custom one specific for the day. This is fine. Portal submit + dynamic vlan switch on valid auth + dhcp + dynamic deregister in the gui for bad clients works brilliantly. So brilliantly in fact, I'm going to replace our other radius + eduroam connection handling and NPS wired switch auth backend with it. Where I'm stuck: I'm trying to store extra data from the portal page into the database so that we can give it to marketing to do after-the-event marketing to students. If I add something like this to Portal Profiles and Pages/openday/Files/guest.html: (a contrived example, cough) spanSchool/span input class=field name=custom_field_1 type=custom_field_1 value= /br/ The field pops up on the portal page, I can add data, and mash the register button, and then the custom_field_1 data goes into a black hole somewhere. I can see the page submitting the data via the post request. If I cause the page to not submit by not having all the mandatory fields filled, the custom_field_1 field doesn't include the submitted data in the result page, but the firstname field does. If I extend the mandatory field list to include custom_field_1, then it will show a warning if it does not contain data, but still won't send the submitted data back on the Missing mandatory parameter(s) result page. I see the other data in the form being added to the database, (after enabling TRACE) in the logging files: == logs/packetfence.log == attempt #0 to run query person_add_sql from module person SQL statement (person_add_sql): INSERT INTO person (pid, firstname, lastname, email, telephone, company, address, notes, sponsor, anniversary, birthday, gender, lang, nickname, cell_phone, work_phone, title, building_number, apartment_number, room_number, custom_field_1, custom_field_2, custom_field_3, custom_field_4, custom_field_5, custom_field_6, custom_field_7, custom_field_8, custom_field_9, portal, source) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?) SQL params (person_add_sql): emailaddr...@gmail.com mailto:emailaddr...@gmail.com, first3, last3, emailaddr...@gmail.com mailto:emailaddr...@gmail.com, 0, org3, null, email activation. Date of arrival: 2015-05-07 12:45:41, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, openday, email person emailaddr...@gmail.com mailto:emailaddr...@gmail.com added This is using the email source as it appears to captures more data, not the null provisioner. - it also causes the guest.html section of the portal to be used, rather than the login.html pages. I don't quite understand that mapping, either. Any help would be much appreciated, Thanks in advance. Cheers, David Murrell Systems Engineer - Linux ITS Infrastructure University of Waikato, NZ Other files that may be of use: [root@pktfence-guest pf]# cat conf/provisioning.conf [accept] type=accept description=accept provisioner oses= category=guest [openday] filter=ssid:Open Day mandatory_fields=email,firstname,lastname,organization,phone,custom_field_1 provisioners=accept always_use_redirecturl=enabled redirecturl=http://www.waikato.ac.nz sources=email logo=/content/images/coat-of-arms.png
Re: [PacketFence-users] Storing extra information in the database from a guest portal page
Hi, That's awesome. :) I'll apply it tomorrow, and see how it goes. Does it need 5.0.2? Cheers, David On Thu, May 7, 2015 at 11:39 PM, Durand fabrice fdur...@inverse.ca wrote: Hi David, this is exactly what we are working on. We made a branch (fix/mandatory_fields) that fix that. If you want you can try to apply the patch of this branch to your setup ( https://patch-diff.githubusercontent.com/raw/inverse-inc/packetfence/pull/516.diff ). Also it will be available in the incoming 5.1 release. Regards Fabrice Le 2015-05-06 21:30, David Murrell a écrit : Hi, I'm a bit stuck. For a openday here on campus for prospective students, (using packetfence 4.7.0) marketing wants visting students to have wifi internet access on the day in return for some extra data gathered via a custom portal page. -- this might be important? I'm not using the default portal, but a custom one specific for the day. This is fine. Portal submit + dynamic vlan switch on valid auth + dhcp + dynamic deregister in the gui for bad clients works brilliantly. So brilliantly in fact, I'm going to replace our other radius + eduroam connection handling and NPS wired switch auth backend with it. Where I'm stuck: I'm trying to store extra data from the portal page into the database so that we can give it to marketing to do after-the-event marketing to students. If I add something like this to Portal Profiles and Pages/openday/Files/guest.html: (a contrived example, cough) spanSchool/span input class=field name=custom_field_1 type=custom_field_1 value= /br/ The field pops up on the portal page, I can add data, and mash the register button, and then the custom_field_1 data goes into a black hole somewhere. I can see the page submitting the data via the post request. If I cause the page to not submit by not having all the mandatory fields filled, the custom_field_1 field doesn't include the submitted data in the result page, but the firstname field does. If I extend the mandatory field list to include custom_field_1, then it will show a warning if it does not contain data, but still won't send the submitted data back on the Missing mandatory parameter(s) result page. I see the other data in the form being added to the database, (after enabling TRACE) in the logging files: == logs/packetfence.log == attempt #0 to run query person_add_sql from module person SQL statement (person_add_sql): INSERT INTO person (pid, firstname, lastname, email, telephone, company, address, notes, sponsor, anniversary, birthday, gender, lang, nickname, cell_phone, work_phone, title, building_number, apartment_number, room_number, custom_field_1, custom_field_2, custom_field_3, custom_field_4, custom_field_5, custom_field_6, custom_field_7, custom_field_8, custom_field_9, portal, source) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?) SQL params (person_add_sql): emailaddr...@gmail.com, first3, last3, emailaddr...@gmail.com, 0, org3, null, email activation. Date of arrival: 2015-05-07 12:45:41, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, openday, email person emailaddr...@gmail.com added This is using the email source as it appears to captures more data, not the null provisioner. - it also causes the guest.html section of the portal to be used, rather than the login.html pages. I don't quite understand that mapping, either. Any help would be much appreciated, Thanks in advance. Cheers, David Murrell Systems Engineer - Linux ITS Infrastructure University of Waikato, NZ Other files that may be of use: [root@pktfence-guest pf]# cat conf/provisioning.conf [accept] type=accept description=accept provisioner oses= category=guest [openday] filter=ssid:Open Day mandatory_fields=email,firstname,lastname,organization,phone,custom_field_1 provisioners=accept always_use_redirecturl=enabled redirecturl=http://www.waikato.ac.nz sources=email logo=/content/images/coat-of-arms.png dot1x_recompute_role_from_portal=0 filter_match_style=all reuse_dot1x_credentials=0 -- One dashboard for servers and applications across Physical-Virtual-Cloud Widest out-of-the-box monitoring support with 50+ applications Performance metrics, stats and reports that give you Actionable Insights Deep dive visibility with transaction tracing using APM Insight.http://ad.doubleclick.net/ddm/clk/290420510;117567292;y ___ PacketFence-users mailing listPacketFence-users@lists.sourceforge.nethttps://lists.sourceforge.net/lists/listinfo/packetfence-users
Re: [PacketFence-users] Storing extra information in the database from a guest portal page
Hi Fabrice, Du you have a planned release date for 5.1, yet? Regards, Holger -Original Message- From: Fabrice DURAND [mailto:fdur...@inverse.ca] Sent: Thursday, May 07, 2015 2:37 PM To: packetfence-users@lists.sourceforge.net Subject: Re: [PacketFence-users] Storing extra information in the database from a guest portal page Hi David, i just did a test on a 4.7 version and there is only 3 conflicts that are really easy to fix. So it's as you want,patch 4.7 or install 5.0.2 and patch it or wait for 5.1. Regards Fabrice Le 2015-05-07 08:06, David Murrell a écrit : Hi, That's awesome. :) I'll apply it tomorrow, and see how it goes. Does it need 5.0.2? Cheers, David On Thu, May 7, 2015 at 11:39 PM, Durand fabrice fdur...@inverse.ca mailto:fdur...@inverse.ca wrote: Hi David, this is exactly what we are working on. We made a branch (fix/mandatory_fields) that fix that. If you want you can try to apply the patch of this branch to your setup (https://patch-diff.githubusercontent.com/raw/inverse-inc/packetfence/pull/516.diff). Also it will be available in the incoming 5.1 release. Regards Fabrice Le 2015-05-06 21:30, David Murrell a écrit : Hi, I'm a bit stuck. For a openday here on campus for prospective students, (using packetfence 4.7.0) marketing wants visting students to have wifi internet access on the day in return for some extra data gathered via a custom portal page. -- this might be important? I'm not using the default portal, but a custom one specific for the day. This is fine. Portal submit + dynamic vlan switch on valid auth + dhcp + dynamic deregister in the gui for bad clients works brilliantly. So brilliantly in fact, I'm going to replace our other radius + eduroam connection handling and NPS wired switch auth backend with it. Where I'm stuck: I'm trying to store extra data from the portal page into the database so that we can give it to marketing to do after-the-event marketing to students. If I add something like this to Portal Profiles and Pages/openday/Files/guest.html: (a contrived example, cough) spanSchool/span input class=field name=custom_field_1 type=custom_field_1 value= /br/ The field pops up on the portal page, I can add data, and mash the register button, and then the custom_field_1 data goes into a black hole somewhere. I can see the page submitting the data via the post request. If I cause the page to not submit by not having all the mandatory fields filled, the custom_field_1 field doesn't include the submitted data in the result page, but the firstname field does. If I extend the mandatory field list to include custom_field_1, then it will show a warning if it does not contain data, but still won't send the submitted data back on the Missing mandatory parameter(s) result page. I see the other data in the form being added to the database, (after enabling TRACE) in the logging files: == logs/packetfence.log == attempt #0 to run query person_add_sql from module person SQL statement (person_add_sql): INSERT INTO person (pid, firstname, lastname, email, telephone, company, address, notes, sponsor, anniversary, birthday, gender, lang, nickname, cell_phone, work_phone, title, building_number, apartment_number, room_number, custom_field_1, custom_field_2, custom_field_3, custom_field_4, custom_field_5, custom_field_6, custom_field_7, custom_field_8, custom_field_9, portal, source) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?) SQL params (person_add_sql): emailaddr...@gmail.com mailto:emailaddr...@gmail.com, first3, last3, emailaddr...@gmail.com mailto:emailaddr...@gmail.com, 0, org3, null, email activation. Date of arrival: 2015-05-07 12:45:41, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, openday, email person emailaddr...@gmail.com mailto:emailaddr...@gmail.com added This is using the email source as it appears to captures more data, not the null provisioner. - it also causes the guest.html section of the portal to be used, rather than the login.html pages. I don't quite understand that mapping, either. Any help would be much appreciated, Thanks in advance. Cheers, David Murrell Systems Engineer - Linux ITS Infrastructure University of Waikato, NZ Other files that may be of use: [root@pktfence-guest pf]# cat conf/provisioning.conf [accept] type=accept description=accept
Re: [PacketFence-users] Storing extra information in the database from a guest portal page
Probably in 2 weeks. Le 2015-05-07 09:12, holger.patz...@t-systems.com a écrit : Hi Fabrice, Du you have a planned release date for 5.1, yet? Regards, Holger -Original Message- From: Fabrice DURAND [mailto:fdur...@inverse.ca] Sent: Thursday, May 07, 2015 2:37 PM To: packetfence-users@lists.sourceforge.net Subject: Re: [PacketFence-users] Storing extra information in the database from a guest portal page Hi David, i just did a test on a 4.7 version and there is only 3 conflicts that are really easy to fix. So it's as you want,patch 4.7 or install 5.0.2 and patch it or wait for 5.1. Regards Fabrice Le 2015-05-07 08:06, David Murrell a écrit : Hi, That's awesome. :) I'll apply it tomorrow, and see how it goes. Does it need 5.0.2? Cheers, David On Thu, May 7, 2015 at 11:39 PM, Durand fabrice fdur...@inverse.ca mailto:fdur...@inverse.ca wrote: Hi David, this is exactly what we are working on. We made a branch (fix/mandatory_fields) that fix that. If you want you can try to apply the patch of this branch to your setup (https://patch-diff.githubusercontent.com/raw/inverse-inc/packetfence/pull/516.diff). Also it will be available in the incoming 5.1 release. Regards Fabrice Le 2015-05-06 21:30, David Murrell a écrit : Hi, I'm a bit stuck. For a openday here on campus for prospective students, (using packetfence 4.7.0) marketing wants visting students to have wifi internet access on the day in return for some extra data gathered via a custom portal page. -- this might be important? I'm not using the default portal, but a custom one specific for the day. This is fine. Portal submit + dynamic vlan switch on valid auth + dhcp + dynamic deregister in the gui for bad clients works brilliantly. So brilliantly in fact, I'm going to replace our other radius + eduroam connection handling and NPS wired switch auth backend with it. Where I'm stuck: I'm trying to store extra data from the portal page into the database so that we can give it to marketing to do after-the-event marketing to students. If I add something like this to Portal Profiles and Pages/openday/Files/guest.html: (a contrived example, cough) spanSchool/span input class=field name=custom_field_1 type=custom_field_1 value= /br/ The field pops up on the portal page, I can add data, and mash the register button, and then the custom_field_1 data goes into a black hole somewhere. I can see the page submitting the data via the post request. If I cause the page to not submit by not having all the mandatory fields filled, the custom_field_1 field doesn't include the submitted data in the result page, but the firstname field does. If I extend the mandatory field list to include custom_field_1, then it will show a warning if it does not contain data, but still won't send the submitted data back on the Missing mandatory parameter(s) result page. I see the other data in the form being added to the database, (after enabling TRACE) in the logging files: == logs/packetfence.log == attempt #0 to run query person_add_sql from module person SQL statement (person_add_sql): INSERT INTO person (pid, firstname, lastname, email, telephone, company, address, notes, sponsor, anniversary, birthday, gender, lang, nickname, cell_phone, work_phone, title, building_number, apartment_number, room_number, custom_field_1, custom_field_2, custom_field_3, custom_field_4, custom_field_5, custom_field_6, custom_field_7, custom_field_8, custom_field_9, portal, source) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?) SQL params (person_add_sql): emailaddr...@gmail.com mailto:emailaddr...@gmail.com, first3, last3, emailaddr...@gmail.com mailto:emailaddr...@gmail.com, 0, org3, null, email activation. Date of arrival: 2015-05-07 12:45:41, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, openday, email person emailaddr...@gmail.com mailto:emailaddr...@gmail.com added This is using the email source as it appears to captures more data, not the null provisioner. - it also causes the guest.html section of the portal to be used, rather than the login.html pages. I don't quite understand that mapping, either. Any help would be much appreciated, Thanks in advance. Cheers, David Murrell Systems Engineer - Linux ITS Infrastructure University of Waikato, NZ Other files that may be of use: [root
[PacketFence-users] Storing extra information in the database from a guest portal page
Hi, I'm a bit stuck. For a openday here on campus for prospective students, (using packetfence 4.7.0) marketing wants visting students to have wifi internet access on the day in return for some extra data gathered via a custom portal page. -- this might be important? I'm not using the default portal, but a custom one specific for the day. This is fine. Portal submit + dynamic vlan switch on valid auth + dhcp + dynamic deregister in the gui for bad clients works brilliantly. So brilliantly in fact, I'm going to replace our other radius + eduroam connection handling and NPS wired switch auth backend with it. Where I'm stuck: I'm trying to store extra data from the portal page into the database so that we can give it to marketing to do after-the-event marketing to students. If I add something like this to Portal Profiles and Pages/openday/Files/guest.html: (a contrived example, cough) spanSchool/span input class=field name=custom_field_1 type=custom_field_1 value= /br/ The field pops up on the portal page, I can add data, and mash the register button, and then the custom_field_1 data goes into a black hole somewhere. I can see the page submitting the data via the post request. If I cause the page to not submit by not having all the mandatory fields filled, the custom_field_1 field doesn't include the submitted data in the result page, but the firstname field does. If I extend the mandatory field list to include custom_field_1, then it will show a warning if it does not contain data, but still won't send the submitted data back on the Missing mandatory parameter(s) result page. I see the other data in the form being added to the database, (after enabling TRACE) in the logging files: == logs/packetfence.log == attempt #0 to run query person_add_sql from module person SQL statement (person_add_sql): INSERT INTO person (pid, firstname, lastname, email, telephone, company, address, notes, sponsor, anniversary, birthday, gender, lang, nickname, cell_phone, work_phone, title, building_number, apartment_number, room_number, custom_field_1, custom_field_2, custom_field_3, custom_field_4, custom_field_5, custom_field_6, custom_field_7, custom_field_8, custom_field_9, portal, source) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?) SQL params (person_add_sql): emailaddr...@gmail.com, first3, last3, emailaddr...@gmail.com, 0, org3, null, email activation. Date of arrival: 2015-05-07 12:45:41, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, openday, email person emailaddr...@gmail.com added This is using the email source as it appears to captures more data, not the null provisioner. - it also causes the guest.html section of the portal to be used, rather than the login.html pages. I don't quite understand that mapping, either. Any help would be much appreciated, Thanks in advance. Cheers, David Murrell Systems Engineer - Linux ITS Infrastructure University of Waikato, NZ Other files that may be of use: [root@pktfence-guest pf]# cat conf/provisioning.conf [accept] type=accept description=accept provisioner oses= category=guest [openday] filter=ssid:Open Day mandatory_fields=email,firstname,lastname,organization,phone,custom_field_1 provisioners=accept always_use_redirecturl=enabled redirecturl=http://www.waikato.ac.nz sources=email logo=/content/images/coat-of-arms.png dot1x_recompute_role_from_portal=0 filter_match_style=all reuse_dot1x_credentials=0 -- One dashboard for servers and applications across Physical-Virtual-Cloud Widest out-of-the-box monitoring support with 50+ applications Performance metrics, stats and reports that give you Actionable Insights Deep dive visibility with transaction tracing using APM Insight. http://ad.doubleclick.net/ddm/clk/290420510;117567292;y___ PacketFence-users mailing list PacketFence-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/packetfence-users