File Upload - Posting the Renamed image instead of the original name
I have my file uploads working and if the file name already exists, it correctly adds an increment. ie image 1 = IMG_0415.jpg image 2 = IMG_0415_1.jpg
My problem is that the file name being posted to my database uses the file name being uploaded rather than the renamed file, so both entries have the file name as IMG_0415.jpg.
In the insert record behaviour the field 'filename' has a value of
<?php echo ((isset($_FILES["filename"]))?$_FILES["filename"]["name"]:""); ?>
What should I change that to.