gta6/prompts
ui
Vaultintermediateui

Input Dialog (Form Fields to Lua Values)

A NUI form dialog with text/number/select/checkbox fields that coerces inputs to typed Lua values and submits them to a server-authoritative handler.

NON-TESTÉ — the reference Lua is syntax-validated, not run in a live FiveM server. Adapt and test on your own dev server before shipping.
Est. Lua
~74 loc
Claude
Claude Opus 4.x / Sonnet 4.x
Validation
syntax-validated
Updated
2026-06-25

Description

A NUI input dialog: open it with a title and a list of fields (text / number / select / checkbox), the player fills it in, and a callback returns the values coerced to the right Lua types. It is the ox_lib inputDialog pattern servers reuse everywhere — registrations, admin tools, job forms.

Prompt Template

You are writing a FiveM NUI input dialog for the <esx|qbcore|qbox framework.

🔒 Eyes-only — locked prompt body

The full prompt template and its reference Lua are part of a one-time pack. Pick your depth — both are lifetime access, no subscription, ever.

Core$49one-time
  • 60 prompts + syntax-validated reference Lua
  • Lifetime access — pay once
Most Popular · Best Value
Vault$199one-time
  • All 510 prompts — the full library
  • Per-prompt profit/trend intelligence (CSV + playbook)
  • Lifetime free updates — new niches as the market moves
Get the Vault — $199

$49 for 60 · $199 for all 510 + intelligence — one-time, no subscription.

Expected Output

The reference Lua lives at content/expected-outputs/ui/13-input-dialog-form.lua.

🔒 Eyes-only — locked prompt body

The full prompt template and its reference Lua are part of a one-time pack. Pick your depth — both are lifetime access, no subscription, ever.

Core$49one-time
  • 60 prompts + syntax-validated reference Lua
  • Lifetime access — pay once
Most Popular · Best Value
Vault$199one-time
  • All 510 prompts — the full library
  • Per-prompt profit/trend intelligence (CSV + playbook)
  • Lifetime free updates — new niches as the market moves
Get the Vault — $199

$49 for 60 · $199 for all 510 + intelligence — one-time, no subscription.

Known Failure Modes & Corrective Prompt

  • Client-trusted values — the server must re-check length/range/type; a tampered NUI payload is the default attack.
  • No result registration — the client must RegisterNetEvent the result reply.
  • Cursor stuck — the cancel path must SetNuiFocus(false, false).

Corrective re-prompt: "The server stored the form values without checking them — re-validate fullname length and age >= 18 in server.lua before acting, and reply with a reject notify on failure. Make sure the cancel NUI callback also calls SetNuiFocus(false,false)."

Framework Integration

  • ESX: validate and persist with xPlayer accessors after getSharedObject(); sanitize strings before any DB write.
  • QBCore: GetCoreObject() then store on Player.PlayerData.metadata or a DB table; re-validate server-side.
  • QBox: exports.qbx_core:GetPlayer(src); the dialog client code is framework-agnostic, only the persistence differs.

Profit Potential

$150–$2000/mo on Tebex (expected ~$600). [INFERRED] priced in the $50-389 script band against the signal-scraper tebex_snapshot corpus (n=100, median seller $11.85K/mo); a stable utility lands low-mid.

Trend Signal

stable — corpus: ox_lib inputDialog is a standard form primitive reused by countless ox-ecosystem scripts; mature, steady demand.

Sales Angle

Position as the dependable typed-form primitive every job and admin script reuses — a utility buy, not a flashy feature. Recommended Tebex price $99.

Difficulty & Ship Time

intermediate · ships in 2-4h.