Customizing apps/frappe/frappe/website/doctype/web_form/templates/web_form.html

Hello, I’m trying to customize the web_form.html that is under directory “apps/frappe/frappe/website/doctype/web_form/templates/web_form.html”, what I have done without success, it is creating a ‘web_form.html’ under my application directory “apps/myapp/myapp/templates”.

does anybody know if it is possible to customize the web_form.html?

hi @tundebabzy , have you done that?

thanks for any info you could provider, regards,

Are you trying to modify the template or the instance of webform?
I think (I don’t have the system handy now) the web_form.html is the template for creating web form via the Website>Web Form doctype.

The instance is in your app directory.

Not sure if related to this, but where can we modify the customer portal pages. Like for example to show and sort by the customer PO number instead of our Sales Order number on the orders portal, show the customer PO number in addition to our invoice number on the invoices portal, etc.

Thanks in advance.

I’m trying to modify the template of the web form doctype, I could modify this one apps/frappe/frappe/website/doctype/web_form/templates/web_form.html directly but my changes will be lost if I update ERPNEXT, I was wondering if web_form.html could work the same way as base.html and web.html, where you can just copy them under myapp/templates directory.

I’m not sure but if there is a py file with the same name (web_form.py) maybe you can copy it as well to your custom app directory.
I had succeed customizing a html file this way when just copying the html didn’t work (but I forgot which one so please don’t ask :slight_smile:)

If someone still not sure how to customize the webform, then we need to create the custom app and place the web_form.html exactly like the below folder structure in our custom app

website/doctype/web_form/templates/web_form.html