web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Pages / Entity Form - Advanced...
Power Pages
Answered

Entity Form - Advanced Settings - Custom javascript --> Not working when JavaScript is disabled by end users on their browsers

(0) ShareShare
ReportReport
Posted on by 20

Hello,

 

I have developed an Entity form and added JavaScript for custom validations and integrating Esri address suggestions API. 

 

When end users have Javascript disabled on their browsers, then these validations and address auto suggestions are not working. 

 

I also have many validations by adding Regex functions in Entity fields metadata. It seems they are working fine. 

 

Questions - 

  1. What is the difference between these two? Aren't they both client side javascript? 
  2. If JavaScript is disabled, how can we make this custom javascript work?
  3. What are the other options to implement custom validations? Any server side validations? liquid tags? 

Any guidance on this? Thank you in advanced. 

Categories:
  • Verified answer
    oliver.rodrigues Profile Picture
    9,482 Most Valuable Professional on at

    Hi, if you need to enforce certain validations you can take a look at Server-side code, which would be Plugin in Dataverse/D365: https://docs.microsoft.com/en-us/dynamics365/customerengagement/on-premises/developer/plugin-development

     

    Liquid code would be processed while rendering the page, however it is also server-side, it always executes before the form is rendered and not when submitting 

  • MittalPatel Profile Picture
    20 on at

    @OliverRodrigues  

     

    Thank you for your response on this! I'm new to PowerApps Portal and hence I'm trying to understand which is the best fit for implementing different things. 

     

    I understood that validations has to be in JavaScript, as Liquid would be executed while rendering the page. So I will keep validations in JavaScript and also will write them in Plug-in as you suggested above so that if JS is disabled, still we'll be able to validate on Form Submit button and restrict users making wrong submissions.

     

    However, there are couple of things I still have in JavaScript, like below

    1. $('#homeaddress').autocomplete({... }) - integrating third-party api which populates address auto-suggestions 
    2. document.getElementById('mobilephonenumber').addEventListener('keyup', function (evt) { ... })  - Auto formatting phone number

    3.  

      Calculate age event on DOB date picker (from my another post)

     

     
    Can I bind these events using Liquid while rendering the page? I'm just trying to improve on this code because there is a huge inflow of form submissions, i.e. 2-3k in a minute and hence getting a lot of bad data due to JS disabled issue. 
     
    Hope this clarifies my questions.  Thank you!

     

  • oliver.rodrigues Profile Picture
    9,482 Most Valuable Professional on at

    Hi, unfortunately you can't bind an event to a control via Liquid, you could if you were designing the HTML from scratch, but nothing would change really. 

    If the user's browser has JS disabled, it won't be triggered, even if the event was already associated to that field/control.

    Your auto-complete API also won't work.

     

    Might be worth to add a message in your page saying something like "We noticed the JS is disabled in your browser, this website works better with JS enabled".

    You can identify that via HTML: https://www.tutorialspoint.com/How-to-detect-if-JavaScript-is-disabled-in-a-browser#:~:text=To%20detect%20if%20JavaScript%20is%20disabled%20in%20a%20web%20browser,display%20an%20alternate%20text%20message.

     

  • MittalPatel Profile Picture
    20 on at

    Thank you @OliverRodrigues , this is helpful! I'll add that HTML message as you suggested. Thank you again for all your help.. 

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Leaderboard > Power Pages

#1
Mohsin Ali Profile Picture

Mohsin Ali 35

#2
M Bilal Khan Profile Picture

M Bilal Khan 29

#3
11manish Profile Picture

11manish 21 Super User 2026 Season 2

Last 30 days Overall leaderboard