@Soda
I have FDM 0.1b on a production site.
I have the following as my fdmEform chunk:
<script language="javascript" type="text/javascript" src="assets/plugins/tinymce2111/jscripts/tiny_mce/tiny_mce.js"></script>
<script language="javascript" type="text/javascript">
//your configuration detail check http://wiki.moxiecode.com/index.php/TinyMCE:Configuration
tinyMCE.init({
theme : "advanced",
mode : "textareas"
});
</script>
[+validationmessage+]
<form method="post" action="[~[*id*]~]" id="fdmForm">
<fieldset>
<legend>News or Event</legend>
<div><input type="hidden" name="formid" value="fdmForm">
<input type="hidden" name="fdmid" value="[+fdmid+]" eform="::0::"><div>
<p>
<label for="pagetitle">News Headline or Event Title</label>
<input name="pagetitle" id="pagetitle" value="[+pagetitle+]" type="text" eform="Title of the page:string:1" >
</p>
<p>
<label for="introtext">Item Summary</label>
<textarea name="introtext" id="introtext" rows="6" cols="80" eform="Summary of Item:string:1">[+introtext+]</textarea>
</p>
<p>
<label for="tvevent_date">Event Date:</label>
<input name="tvevent_date" id="tvevent_date" type="text" value="[+tvevent_date+]" size="30" readonly="readonly">
<a onClick="nwev_cal1.popup();" title="Select the Date of the Event">
<img align="absmiddle" src="manager/media/calendar/img/cal.gif" width="16" height="16" alt="Select Event Date"></a>
<a onClick="document.forms['fdmForm'].elements['tvevent_date'].value=''; return true;" >
<img align="absmiddle" src="manager/media/style/MODx/images/icons/event3.gif" width="16" height="16" alt="Clear Event Date"></a>
</p>
<p>
<label for="pub_date">Publish Date:</label>
<input name="pub_date" id="pub_date" type="text" value="[+pub_date:date=`%d-%m-%Y %T`+]" size="30" readonly="readonly">
<a onClick="nwpub_cal1.popup();" title="Choose the publish date">
<img align="absmiddle" src="manager/media/calendar/img/cal.gif" width="16" height="16" alt="Select date"></a>
<a onClick="document.forms['fdmForm'].elements['pub_date'].value=''; return true;" >
<img align="absmiddle" src="manager/media/style/MODx/images/icons/event3.gif" width="16" height="16" alt="Remove date"></a>
</p>
<p>
<label for="unpub_date">Unpublish Date:</label>
<input name="unpub_date" id="unpub_date" type="text" value="[+unpub_date+]" size="30" readonly="readonly">
<a onClick="nwunpub_cal1.popup();" title="Choose the unpublish date">
<img align="absmiddle" src="manager/media/calendar/img/cal.gif" width="16" height="16" border="0" alt="Select date"></a>
<a onClick="document.forms['fdmForm'].elements['unpub_date'].value=''; return true;" >
<img align="absmiddle" src="manager/media/style/MODx/images/icons/event3.gif" width="16" height="16" alt="Remove date"></a>
</p>
<p> <label for="doccontent">News or Event Details</label>
<textarea name="content" id="doccontent" rows="6" cols="80" eform="Page Content:string:1">[+content+]</textarea>
</p>
</fieldset>
<p><input name="fdmsubmit" value="Submit" type="submit" /> <a href="[~[*id*]~]" tile="Abort operation">Abort</a></p>
</form>
<form id="abort" style="position:relative;" method="post" action="[~[*id*]~]">
<input type="submit" name="clickabort" value="Abort" />
</form>
<script language="JavaScript" src="manager/media/script/datefunctions.js"></script>
<script type="text/javascript">
var elm_txt = {}; // dummy
var pub = document.forms["fdmForm"].elements["pub_date"];
var nwpub_cal1 = new calendar1(pub,elm_txt);
nwpub_cal1.path="[(base_url)]manager/media/";
nwpub_cal1.year_scroll = true;
nwpub_cal1.time_comp = true;
</script>
<script type="text/javascript">
var evelm_txt = {}; // dummy
var ev = document.forms["fdmForm"].elements["tvevent_date"];
var nwev_cal1 = new calendar1(ev,evelm_txt);
nwev_cal1.path="[(base_url)]manager/media/";
nwev_cal1.year_scroll = true;
nwev_cal1.time_comp = true;
</script>
<script type="text/javascript">
var unelm_txt = {}; // dummy
var unpub = document.forms["fdmForm"].elements["unpub_date"];
var nwunpub_cal1 = new calendar1(unpub,unelm_txt);
nwunpub_cal1.path="[(base_url)]manager/media/";
nwunpub_cal1.year_scroll = true;
nwunpub_cal1.time_comp = true;
</script>
And the call is as follows:
[!FDM? &model=`59` &eform_noemail=`1` &parent=`4` &aliastype=`%pagetitle%`!]
The problem is that the pubdate and unpub date won’t store from the form when value exists. I can certainly edit and change them from the manager but I cannot store from the FDM when a value exists. I can set one from FDM when creating a new doc.
Further to that, the placeholders for the value (to be read from the db returns an unformatted unix timestamp). I tried using PHX to format it but it is not working either.
I can only assume one is causing the other.
Any help would be appreciated.
Jay