[[!NpEditThisButton?
&np_id=`304`
&np_edit_id=`316`
&buttonCaption=`Edit Enterprise News`
]][[!NewsPublisher? &show=`content,pub_date,unpub_date,published` &required=`content` &initrte=`0` &initdatepicker=`1` &rtcontent=`0` &rtsummary=`0` &parentid=`12` &published=`1` ]]
<fieldset id="np-[[+npx.fieldName]]-container" class="np-checkbox" title="[[+npx.help]]"><legend>[[+npx.caption]]</legend> <input type="hidden" name="[[+npx.fieldName]]" value = "" /> <span class="option"><input class="checkbox" type="checkbox" name="[[+npx.fieldName]]" id="np-[[+npx.fieldName]]" value="1" [[+npx.checked]]/></span> </fieldset>
This question has been answered by BobRay. See the first response.
/* correct timestamp resource fields */
foreach ($_POST as $field => $val) {
if (isset($this->resource->_fieldMeta[$field]) &&
$this->resource->_fieldMeta[$field]['phptype'] == 'timestamp') {
$postTime = isset($_POST[$field . '_time'])? $_POST[$field . '_time'] : '';
$_POST[$field] = $val . ' ' . $postTime;
if (empty($_POST[$field]) || $_POST[$field] == ' ') {
$_POST[$field] = 0;
}
}
}