# Delete Link on Child Page

> This method can create a scenario where users can delete a record from the child detail or edit page for the given record. Upon deletion, the user is…

Source: https://tadabase.com/docs/snippets/delete-link-on-child-page  
Status: Not yet re-checked. Moved from our previous help site and not yet re-checked against the current product. Last edited Sep 20, 2024.

[Video](https://www.screencast.com/users/stellrechtmegan/folders/Snagit/media/b05a45a6-4c22-432f-b175-eaa080546bf5/embed)

This method can create a scenario where users can delete a record from the child detail or edit page for the given record. Upon deletion, the user is redirected back to the parent page.

**Step 1**

**Download the Tadabase Rest API and plugin API keys.**

![Screenshot for “Delete Link on Child Page”](https://tadabase-docs-assets.s3.amazonaws.com/uploads/images/gallery/2022-09/scaled-1680-/2022-09-13_18-54-29.png)

**Step 2**

**In your child page, create an edit form. Go to the form rules tab and set a submit rule to redirect to the parent page.**

![Screenshot for “Delete Link on Child Page”](https://tadabase-docs-assets.s3.amazonaws.com/uploads/images/gallery/2022-09/scaled-1680-/2022-09-13_23-28-42.png)

**Next, create a record rule to "update this record" with the following settings.**

![Screenshot for “Delete Link on Child Page”](https://tadabase-docs-assets.s3.amazonaws.com/uploads/images/gallery/2022-09/scaled-1680-/2022-09-13_23-29-25.png)

**Step 3**

**You can change your submit button text in the options tab within your edit form. When you change the CSS class to btn-danger, it will change the button to red.**

![Screenshot for “Delete Link on Child Page”](https://tadabase-docs-assets.s3.amazonaws.com/uploads/images/gallery/2022-09/scaled-1680-/2022-09-13_23-44-06.png)

**Step 4**

**Instead of a check mark, you can change the button Icon to a trash can with the following code added to the page's JavaScript tab.**

```
TB.render('component_4', function(data) {
    var icon = $('.btn-danger > .far');
    icon.addClass('fa-trash');
    icon.removeClass('fa-check');
});
```

![Screenshot for “Delete Link on Child Page”](https://tadabase-docs-assets.s3.amazonaws.com/uploads/images/gallery/2022-09/scaled-1680-/2022-09-13_23-59-29.png)

> **Note:** Be sure to change the component ID to your edit forms component ID, which can be found in the image below.

![Screenshot for “Delete Link on Child Page”](https://tadabase-docs-assets.s3.amazonaws.com/uploads/images/gallery/2022-09/scaled-1680-/2022-09-14_00-00-44.png)

**Original Community Post:**

[Delete Link on Child Page - Community Discussions / Tips and Tricks - Tadabase Community](https://community.tadabase.io/t/delete-link-on-child-page/1765)
