I am a newbie who is creating a database using wamp. I have managed to create insert and display front-ends that each work fine for text fields. However, I would like to be able to send the contents of a plugin to mysql (as a blob) using php, or to put it another way, I would like to be able to submit an embedded object to the database. The active-x plugin (chemdraw) I am using allows the user to draw and view a chemical structure. I would like to able to send the contents of the plugin to mysql. How do I do this? The code excerpt below will hopefully show you what direction I have been going with the code. I left out all the preceeding php code.
Code:
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Insert</title>
<script language="javascript" src="chemdraw.js"></script>
<script> cd_includeWrapperFile(""); </script>
</head>
<body><!-- <applet code="camsoft.cdp.CDPHelperAppSimple" align="baseline" width="10" height="0" name="CDPHelper"><param name="ID" value="2"></applet> -->
<form action="<?php echo $editFormAction; ?>" method="post" name="form1" id="form1">
<table align="center" border=1>
<tr valign="baseline">
<td nowrap="nowrap" align="right">Api_Anum:</td>
<td><input type="text" name="api_Anum" value="" size="32" /></td>
</tr>
<tr valign="baseline">
<td nowrap="nowrap" align="right">Api_struct:</td>
<td><script language="javascript"> cd_insertObjectStr("<embed src='blank.cdx' align='baseline' border='0' width='360' height='200' type='chemical/x-cdx' viewonly='false' name='api_struct'>")</script><!-- <embed src="blank.cdx" align="baseline" border="0" width="360" height="200" type="chemical/x-cdx" name="api_struct"> --><input type="hidden" name="api_struct" value="" /></td>
</tr>
When I hit the submit button, all the text gets into the db, but the api_struct field is Null. Any guidance on how I can make this plugin work would be appreciated.
Thanks.