game_name = $title; $gameData->game_link = $gameFileNewName; $gameData->description = $desc; $gameData->img = $thumbnailFileNewName; $gameData->is_web_Based = $isWebBased; $gameData->save(); rename($gameFileTmp,"../../Games/".$gameFileNewName); rename($thumbnailFileTmp,"../../../Frontend/images/".$fileActualExtThumb); } }else{ echo "Der var en fejl med at uploade din file"; } }else{ echo "Wrong file type"; } }