# Django: How do i remove currently:""image\_url" in django image edit form?

**URL:** <https://forum.djangoproject.com/t/django-how-do-i-remove-currently-image-url-in-django-image-edit-form/16905>\
**Category:** Templates & Frontend\
**Created:** [November 9, 2022, 12:52pm UTC](https://forum.djangoproject.com/t/django-how-do-i-remove-currently-image-url-in-django-image-edit-form/16905 "2022-11-09T12:52:46Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![desphixs](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.djangoproject.com/desphixs/32/6411_2.png) [@desphixs](https://forum.djangoproject.com/u/desphixs)\
**Post date:** [November 9, 2022, 12:52pm UTC](https://forum.djangoproject.com/t/django-how-do-i-remove-currently-image-url-in-django-image-edit-form/16905/1 "2022-11-09T12:52:47Z")

</div>

When editing an object that has an image field, you are presented with the current image path and the standard file upload field. What I want to do is to be able to replace the shown path(the “Currently: /image\_url\_path.jpg” with the actual image or even remove it totallt. How do I do this?

**Template**

```auto
<label class="btn btn-icon btn-circle btn-active-color-primary w-25px h-25px bg-body shadow" data-kt-image-input-action="change" data-bs-toggle="tooltip" title="Change avatar">
    <i class="bi bi-pencil-fill fs-7"></i>
    {{p_form.image}}
    <input type="file" name="avatar" accept=".png, .jpg, .jpeg" />
    <input type="hidden" name="avatar_remove" />
</label>

```

**Output**

 ![image](https://us1.discourse-cdn.com/flex026/uploads/djangoproject/original/2X/d/dfd2ee1c273e3084e7643082f24df3d6f1ea1ee0.jpeg)

---

<div class="post-metadata">

**Author:** ![KenWhitesell](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.djangoproject.com/kenwhitesell/32/280_2.png) [@KenWhitesell](https://forum.djangoproject.com/u/KenWhitesell)\
**Post date:** [November 9, 2022, 1:33pm UTC](https://forum.djangoproject.com/t/django-how-do-i-remove-currently-image-url-in-django-image-edit-form/16905/2 "2022-11-09T13:33:19Z")

</div>

Are you talking about in the Django admin?

If so, then the easiest way to do it would be to override the `url.html` template used by the admin. (It’s located in django.contrib.admin.templates.admin.widgets)

See [Overriding admin templates](https://docs.djangoproject.com/en/4.1/ref/contrib/admin/#overriding-admin-templates)

---

<div class="post-metadata">

**Author:** ![desphixs](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.djangoproject.com/desphixs/32/6411_2.png) [@desphixs](https://forum.djangoproject.com/u/desphixs)\
**Post date:** [November 9, 2022, 1:37pm UTC](https://forum.djangoproject.com/t/django-how-do-i-remove-currently-image-url-in-django-image-edit-form/16905/3 "2022-11-09T13:37:32Z")

</div>

Thanks for your response.

I am tring to do this at the frontend, not the admin template

---

<div class="post-metadata">

**Author:** ![flipdruid](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.djangoproject.com/flipdruid/32/11066_2.png) [@flipdruid](https://forum.djangoproject.com/u/flipdruid)\
**Post date:** [November 27, 2022, 2:05pm UTC](https://forum.djangoproject.com/t/django-how-do-i-remove-currently-image-url-in-django-image-edit-form/16905/4 "2022-11-27T14:05:40Z")

</div>

Hi desphix,  
I solved it using codes below

from django.forms import ImageField, FileInput

class ProfileUpdateForm(ModelForm):  
avatar = ImageField(widget=FileInput)  
class Meta:  
model = Profile  
fields = [“avatar”, “is\_dark\_theme”,“is\_logicmorph\_staff”]

I hope it helps you too.

---

<div class="post-metadata">

**Author:** ![xt-RAVEN](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.djangoproject.com/xt-raven/32/14974_2.png) [@xt-RAVEN](https://forum.djangoproject.com/u/xt-RAVEN)\
**Post date:** [July 24, 2023, 12:03pm UTC](https://forum.djangoproject.com/t/django-how-do-i-remove-currently-image-url-in-django-image-edit-form/16905/6 "2023-07-24T12:03:15Z")

</div>

its working , thanks

---

<div class="post-metadata">

**Author:** ![anshudwivedi135](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.djangoproject.com/anshudwivedi135/32/22444_2.png) [@anshudwivedi135](https://forum.djangoproject.com/u/anshudwivedi135)\
**Post date:** [July 7, 2024, 11:19am UTC](https://forum.djangoproject.com/t/django-how-do-i-remove-currently-image-url-in-django-image-edit-form/16905/8 "2024-07-07T11:19:46Z")

</div>

It’s clearable\_file\_input.html , not url.html. It’s located in the same directors as that in url.html
