PHP Snippet on page and it's working - I can validate the php code is calulating the correct dates with the source code.
echo '<select id="selweekend">
<option value="'.$lastwkSunday.'">Last Week</option>
<option value="'.$thiswkSunday.'">This Week</option>
<option value="'.$nextwkSunday.'">Next Week</option>
</select>';
javascript onload event code: (I tried inserting an alert to see if anything was happening with no response)
this.on('beforeSave', function(formObj, fieldControlsArr, pageObj){
var val = $("#selweekend").val();
formObj.baseParams['selweekend'] = val;
});
Before record added: (passed on to another page later - not getting anything as of now)
$_SESSION['weekenddate'] = $_REQUEST['selweekend'];