[jQuery] MultiFile plugin
I can't get the MultiFile plugin to work at all for me. I have a
dropdown list of real estate properties and use ajax to bring up the
correct data and all that works. They need the capabilty to add
multiple photos to a property. Ive tried all combinations of things
to get this to work and can't. I will post a condensed version of the
code and hope someone can see what I can't.
Also, I'm not getting how, when you add a file, it lists it with a
"remove" link. Is this automatic or do I code a hidden div for a
callback function or what? I have googled and viewed source from
http://www.fyneworks.com/jquery/multiple-file-upload but I must be
really dense. tia!
Tim :o]
<!-- MAIN PROGRAM -->
<script language="JavaScript" src="/scripts/jquery.js" type="text/
javascript"></script>
<script language="JavaScript" src="/scripts/form.js" type="text/
javascript"></script>
<script language="JavaScript" src="/scripts/jquery.MultiFile.js"
type="text/javascript"></script>
<script language="JavaScript" src="/scripts/jquery.MetaData.js"
type="text/javascript"></script>
<script language="javascript">
$(document).ready(function() {
$('#listings').change(function(){
var listing_id = $(this).val();
$('#record').load('get_listing.php',{id:listing_id});
$('#frmListing').MultiFile();
}).change();
});
</script>
<body>
<div id="main">
<div id="message_box"></div>
<span id="address_dropdown">
<select tabindex='1' id='listings' name='listings'>
<option value='0'>Add New Listing</option>
<option value='28'> 1011 Hildreth Street, Charles City</
option>
<option value='22'> 102 Park Avenue, Charles City</option>
<option value='14'> 104 Sixteenth Avenue, Charles City</
option>
</select>
</span>
<div id="record"></div>
</div>
</body>
<!-- get_listing.php -->
<form id='frmListing' action=''>
<table border='0'>
<tr><td width='125'></td><td width='75'></td><td width='125'></td><td
width='175'></td></tr>
<tr><td colspan='4' class='record-row-head'>BASIC DATA</td></tr>
<tr><td class='record-row-name'>Address:</td><td colspan='3'
class='record-row-data'><input tabindex='2' type='text' name='address'
size='48' maxlength='50' /></td></tr>
<tr><td class='record-row-name'>City:</td><td colspan='3'
class='record-row-data'><input tabindex='3' type='text' name='city'
size='48' maxlength='50' value='Charles City' /></td></tr>
<tr><td colspan='4'><input type='file' class='multi'/></td></tr>
</table>
</form>
<div style='height:4px;border-top:dotted;margin:0 15px;'></div><li
class='abutton'><a href='javascript:save_listing();'>Save Listing</a></
li>