# Results in alphabetical order?

**URL:** <https://community.gravityforms.com/t/results-in-alphabetical-order/20228>\
**Category:** Get Help\
**Tags:** fields-list, alphabetical-order, gform\_save\_field\_value\
**Created:** [April 26, 2026, 10:16am UTC](https://community.gravityforms.com/t/results-in-alphabetical-order/20228 "2026-04-26T10:16:08Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![smcc](https://sea2.discourse-cdn.com/flex020/user_avatar/community.gravityforms.com/smcc/32/17246_2.png) [@smcc](https://community.gravityforms.com/u/smcc)\
**Post date:** [April 26, 2026, 10:16am UTC](https://community.gravityforms.com/t/results-in-alphabetical-order/20228/1 "2026-04-26T10:16:08Z")

</div>

In the form, I added a LIST field for entering the names of the guests. After the website visitor fills out the form and submits it, I receive a table in my email. I really need these names to be in alphabetical order. Is there any way to do this?

 ![Captura de tela 2026-04-25 113806](https://us1.discourse-cdn.com/flex020/uploads/gravityforms1/original/3X/1/c/1cfd8102389bf9140453266f495b92fd3eb5c9d7.png)

---

<div class="post-metadata">

**Author:** ![faisalahammad](https://sea2.discourse-cdn.com/flex020/user_avatar/community.gravityforms.com/faisalahammad/32/13948_2.png) [@faisalahammad](https://community.gravityforms.com/u/faisalahammad)\
**Post date:** [April 26, 2026, 2:54pm UTC](https://community.gravityforms.com/t/results-in-alphabetical-order/20228/2 "2026-04-26T14:54:59Z")

</div>

Hi there,

Could you please export the form and upload it to a file-sharing website such as File Mail?

> **[Send Large Files - Any Size - Up To 5 GB Free - Filemail](https://www.filemail.com/)**
>
> Send large files of any size fast. Share files up to 5 GB free with no account required. Trusted on all platforms for secure file transfers and sharing.

Then, send me the link so I can download the form and test it on my sandbox website to take a closer look at the issue. Thank you

> **[Exporting a Form](https://docs.gravityforms.com/exporting-a-form-from-gravity-forms/)**
>
> In this article, we will show you how to export any forms you have created using Gravity Forms easily.

---

<div class="post-metadata">

**Author:** ![smcc](https://sea2.discourse-cdn.com/flex020/user_avatar/community.gravityforms.com/smcc/32/17246_2.png) [@smcc](https://community.gravityforms.com/u/smcc)\
**Post date:** [April 27, 2026, 12:50pm UTC](https://community.gravityforms.com/t/results-in-alphabetical-order/20228/3 "2026-04-27T12:50:03Z")

</div>

Thank you very much for your reply. I was unable to create an account on Filemail, however, here is the exported form file and also the test results we ran using TransferXL. The form is in Portuguese (Brazil).

> **[Send large files free | File sharing | File upload | File transfer](https://www.transferxl.com/download/06gH1TW3M6wX3)**
>
> Send large files for free with TransferXL ✔ without registration ✔ secure & fast file upload ✔ file transfer up to 200 GB ✔ via e-mail or link

---

<div class="post-metadata">

**Author:** ![j-yeager-1](https://sea2.discourse-cdn.com/flex020/user_avatar/community.gravityforms.com/j-yeager-1/32/16388_2.png) [@j-yeager-1](https://community.gravityforms.com/u/j-yeager-1)\
**Post date:** [April 27, 2026, 5:16pm UTC](https://community.gravityforms.com/t/results-in-alphabetical-order/20228/4 "2026-04-27T17:16:42Z")

</div>

Hey there,

Thanks for uploading the form export!

For sorting those list field rows alphabetically, you should be able to achieve this with a PHP snippet, like [this](https://gist.github.com/j-yeager-1/1e1e1f2f12b58366c117baf5ab20bc23).

If you’ve never worked with a snippet before, we have a great article that goes over the different ways you can get started with the code: [Where do I put snippets?](https://gravitywiz.com/documentation/managing-snippets/#where-do-i-put-snippets)

Finally, please note that this will run any time that the list field is **saved** , including the initial submission as well as entry editing.

Please give that a try, and let me know if that does the trick for you! 😀

---

<div class="post-metadata">

**Author:** ![smcc](https://sea2.discourse-cdn.com/flex020/user_avatar/community.gravityforms.com/smcc/32/17246_2.png) [@smcc](https://community.gravityforms.com/u/smcc)\
**Post date:** [April 28, 2026, 11:09pm UTC](https://community.gravityforms.com/t/results-in-alphabetical-order/20228/5 "2026-04-28T23:09:25Z")

</div>

Wonderful!!! You have no idea how much this will help us! It worked perfectly for the Guests field!  
I noticed that at the beginning I indicated the field that should be organized, and I ask, is there a possibility of it organizing other list fields as well?  
In our form, we have the names of “member’s dependents” (the first one in red), another for “Guests” (in green) and another for “outsourced workers” (second in red). I indicated the ID of the Guests field, and I would also like to organize the other two fields. Can I insert other IDs, or create other snippets for the other fields without affecting the one that is already working?

Once again, thank you very much for your feedback!

 ![Clipboard_04-28-2026_01](https://us1.discourse-cdn.com/flex020/uploads/gravityforms1/original/3X/d/6/d6705f72dca1e8bb1cf390078b0d57fc970e277f.jpeg)

The field shown in green is already organized alphabetically, and I would like to organize the other two shown in red as well.

---

<div class="post-metadata">

**Author:** ![j-yeager-1](https://sea2.discourse-cdn.com/flex020/user_avatar/community.gravityforms.com/j-yeager-1/32/16388_2.png) [@j-yeager-1](https://community.gravityforms.com/u/j-yeager-1)\
**Post date:** [April 30, 2026, 5:15pm UTC](https://community.gravityforms.com/t/results-in-alphabetical-order/20228/6 "2026-04-30T17:15:49Z")

</div>

Sweet!! Glad to hear that it’s working for you so far.

Since all of those List fields in the screenshot are on the **same form** , you can just broaden the scope by changing the name of the filter.

Please try switching

```auto
gform_save_field_value_123_4

```

to

```auto
gform_save_field_value_123

```

The snippet will then apply to **all** the List fields on form ID 123.

---

<div class="post-metadata">

**Author:** ![smcc](https://sea2.discourse-cdn.com/flex020/user_avatar/community.gravityforms.com/smcc/32/17246_2.png) [@smcc](https://community.gravityforms.com/u/smcc)\
**Post date:** [May 3, 2026, 1:08pm UTC](https://community.gravityforms.com/t/results-in-alphabetical-order/20228/7 "2026-05-03T13:08:38Z")

</div>

> [@j-yeager-1](#):
>
> ```auto
> gform_save_field_value_123
> 
> ```

Perfect! Thank you very much again!!

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex020/uploads/gravityforms1/original/2X/f/fef63f0599c45e0218c30d9f5d7ca8bff9b00189.png) [@system](https://community.gravityforms.com/u/system)\
**Post date:** [May 4, 2026, 1:09pm UTC](https://community.gravityforms.com/t/results-in-alphabetical-order/20228/8 "2026-05-04T13:09:25Z")

</div>

Closed on May 4, 2026, 1:09pm UTC

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.
