# Capturing the value of an input field within a collection

**URL:** <https://community.weweb.io/t/capturing-the-value-of-an-input-field-within-a-collection/4462>\
**Category:** Ask us anything\
**Created:** [September 20, 2023, 5:11am UTC](https://community.weweb.io/t/capturing-the-value-of-an-input-field-within-a-collection/4462 "2023-09-20T05:11:37Z")\
**Posts on this page:** 1\
**Showing post:** 4

<div class="post-metadata">

**Author:** ![dorilama](https://sea2.discourse-cdn.com/flex016/user_avatar/community.weweb.io/dorilama/32/10403_2.png) [@dorilama](https://community.weweb.io/u/dorilama)\
**Post date:** [September 20, 2023, 7:02am UTC](https://community.weweb.io/t/capturing-the-value-of-an-input-field-within-a-collection/4462/4 "2023-09-20T07:02:45Z")

</div>

if you want to use js you need to replace `document` with `wwLib.getFrontDocument()`

Anyway it’s not ideal to do this just to get the input value. You can keep track of the value 100% with nocode. See [this example](https://community.weweb.io/t/are-form-variables-not-visible-while-the-form-is-in-a-collection-item/1138/6).

---

_[View the full topic](https://community.weweb.io/t/capturing-the-value-of-an-input-field-within-a-collection/4462)._
