1 Reply Latest reply on Oct 12, 2008 1:06 AM by Waleed Barakat

    What does this error mean?

    jefferisp7 Level 1
      I have tried and tried to reset this field and no matter what I do, I get an
      error. It is not a file, but a text field and I'm trying to add the value of
      the image's file name to this field. It seems to be working for medium and
      large images, but not for this thumbnail

      //start Trigger_ImageUpload2 trigger
      //remove this line if you want to edit the code by hand
      function Trigger_ImageUpload2(&$tNG) {
      $uploadObj = new tNG_ImageUpload($tNG);
      $uploadObj->setFormFieldName("ThumbLocat");
      $uploadObj->setDbFieldName("ItemThumb");
      $uploadObj->setFolder("../thumbs/");
      $uploadObj->setResize("true", 99, 99);
      $uploadObj->setMaxSize(1500);
      $uploadObj->setAllowedExtensions("gif, jpg, jpe, jpeg");
      $uploadObj->setRename("auto");
      return $uploadObj->Execute();

      Developer Details:
      File upload error. Field "ItemThumb" does not have the "Submit as" property
      set to "file". (FILE_UPLOAD_WRONG_COLTYPE)
      tNG Execution Trace - VIEW

      * tNG_insert.executeTransaction
      o STARTER.Trigger_Default_Starter
      o tNG_insert.doTransaction
      + BEFORE.Trigger_Default_FormValidation
      + tNG_insert.prepareSQL
      + tNG_insert.executeTransaction - execute sql
      + tNG_insert.postExecuteSql
      + AFTER.Trigger_ImageUpload2*
      + ERROR.Trigger_Default_Insert_RollBack
      * tNG_insert.getRecordset
      * tNG_insert.getFakeRsArr
      * tNG_insert.getLocalRecordset
      * tNG_insert.getFakeRecordset
      * tNG_insert.getFakeRecordset

      ~~~~~~~~~~~~
      Jefferis Peterson, Pres.
      Web Design and Marketing
      http://www.PetersonSales.com