You're almost there! Please answer a few more questions for access to the Applications content. Complete registration
Interested in joining? Complete your registration by providing Areas of Interest here. Register

Display Alert Box in Customer Portal

Received Response
35
Views
3
Comments
edited Jun 7, 2022 1:23PM in General Technical Discussions 3 comments

Content

Hi,

We have a requirement to display alert box("Please fill date") whenever the user selects country (menu type custom field)  as India and clicks on submit with out filling the date field. For this initially, I wrote java script code to check for empty date value in the page . Please find the code snippet:-

Please let me know if I have to change/modify/add any part of the code. 

 
Thanks & Regards,
Bindu

Code Snippet

<form id="rn_QuestionSubmit" method="post" action="/ci/ajaxRequest/sendForm" onsubmit = "return checkforblank()">

function checkforblank() {
  if(document.getElementById('invoicedateid').value == null) {
    alert('please enter invoice date');
return false;
  }
<rn:widget path="input/FormSubmit" label_button=Submit" onclick="javascript: return checkforblank()" on_success_url="/app/ask_confirm" error_location="rn_ErrorLocation"/>

Howdy, Stranger!

Log In

To view full details, sign in.

Register

Don't have an account? Click here to get started!