4jd
09-22-2011, 11:26 AM
Hi All
<div class="wrapperAttribsOptions">
<h4 class="optionName back"><label class="attribsUploads" for="attrib-5-0">photo</label></h4>
<div class="back">
<input name="id[TEXT_PREFIX5]" id="attrib-5-0" type="file"><br>
<input name="UPLOAD_PREFIX1" value="5" type="hidden">
<input name="TEXT_PREFIXUPLOAD_PREFIX1" type="hidden"> ( +£0.50 )
</div>
<br class="clearBoth">
</div>
This pice of code is dynamically created by my shopping carts admin section which is an attribute for a certain product.
The problem I have is that all the attributes are displayed in an array and positioning each is not possible (well, I have posted a query in another forum with regards to that). I have taken the code, as viewed in the source code, and added it in where I please e.g. radio buttons, checkboxes etc, which function perfectly.
This does make 'duplicate' field but I have used display:none on the generated code which hides it. I have found a snippet of code which fixes issues will type=text fields....
$('#message').change(function() {
$('#attrib-4-0').val($(this).val());
});
but this can not be done when it comes to type=file.
Once you browse and select your image, i need the directory to be entered into the 'real' field for uploading when submitted.
Could anyone help me with this?
Thanks in advance if anyone can....
--------------
Jay
<div class="wrapperAttribsOptions">
<h4 class="optionName back"><label class="attribsUploads" for="attrib-5-0">photo</label></h4>
<div class="back">
<input name="id[TEXT_PREFIX5]" id="attrib-5-0" type="file"><br>
<input name="UPLOAD_PREFIX1" value="5" type="hidden">
<input name="TEXT_PREFIXUPLOAD_PREFIX1" type="hidden"> ( +£0.50 )
</div>
<br class="clearBoth">
</div>
This pice of code is dynamically created by my shopping carts admin section which is an attribute for a certain product.
The problem I have is that all the attributes are displayed in an array and positioning each is not possible (well, I have posted a query in another forum with regards to that). I have taken the code, as viewed in the source code, and added it in where I please e.g. radio buttons, checkboxes etc, which function perfectly.
This does make 'duplicate' field but I have used display:none on the generated code which hides it. I have found a snippet of code which fixes issues will type=text fields....
$('#message').change(function() {
$('#attrib-4-0').val($(this).val());
});
but this can not be done when it comes to type=file.
Once you browse and select your image, i need the directory to be entered into the 'real' field for uploading when submitted.
Could anyone help me with this?
Thanks in advance if anyone can....
--------------
Jay