Answers.Body: <p>You are in the right path, if you look at the <code>CRM_Core_Session</code> class you'll see the method <a href="https://github.com/civicrm/civicrm-core/blob/4.6.19/CRM/Core/Session.php#L450" rel="nofollow">getStatus</a> which takes a boolean as a parameter, if <code>TRUE</code>then it will reset the status.</p>
  
  <p>That said, I would create a <a href="https://wiki.civicrm.org/confluence/display/CRMDOC/Create+a+Module+Extension" rel="nofollow">extension</a> or use an existing one and implement <a href="https://wiki.civicrm.org/confluence/display/CRMDOC/hook_civicrm_postProcess" rel="nofollow">hook_civicrm_postProcess</a>. </p>
  
  <p>You'll need to know what is the class/form name of the form you are targeting, an easy way would be to inspect the source of the form/page from which you want to remove/replace the notification and search for <code>.tpl</code> </p>
  
  <p>Example: <code>CRM/Contact/Form/Task/Email.tpl</code>, its class/form name would be  <code>CRM_Contact_Form_Task_Email</code></p>
  
  <p>Then in your extension:</p>
  
  <pre><code>function myextension_civicrm_postProcess( $formName, &amp;$form ) {
      if($formName == 'CRM_Contact_Form_Task_Email') {
          $session = CRM_Core_Session::singleton();
          // Reomve status message from form
          $session-&gt;getStatus( $reset = TRUE );
          // Set your new message
          $session::setStatus(ts('This is a custom message.'), ts('Custom Message'), 'success');
      }
  }
  </code></pre>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2016-08-19T14:21:10.890Z
Answers.LastActivityDate: 2016-08-19T14:21:10.890Z
Answers.UserDisplayName: Andrei
Answers.Body: <p>I don't think Civi has a setting to turn OFF the notification </p>
  
  <p>But If you still need to turn Off the message or need to change the content of the message then you need to look for these files </p>
  
  <p>~\civicrm\templates\CRM\Member\Form\Membership.tpl </p>
  
  <p>~\civicrm\templates\CRM\Member\Form\MembershipStandalone.js</p>
  
  <p>you can override the files to your custom template folder and you can make changes or you can also disable the alert </p>
  
  <p>I guess this helps !!!</p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2016-08-18T15:41:12.110Z
Answers.LastActivityDate: 2016-08-18T15:41:12.110Z
Answers.UserDisplayName: Ramesh - ARTECH Consultancy
Body: <p>What's the best way to alter or remove specific popup notification messages? I have a situation where the duplicate membership warning when creating a membership from the backend is not relevant for a client, and would like to suppress the warning so as not to confuse users or clutter the interface.</p>
  
  <p>I've played with CRM_Core_Session::getStatus() but it doesn't appear to be aware of this notification (likely because it's triggered via the tpl file rather than PHP).</p>
  
Tags: <jquery>
Title: alter/remove specific popup notifications
ThreadText: # alter/remove specific popup notifications
  
  (Asked by: username_0 on 2016-08-18)
  
  What's the best way to alter or remove specific popup notification messages? I have a situation where the duplicate membership warning when creating a membership from the backend is not relevant for a client, and would like to suppress the warning so as not to confuse users or clutter the interface.
  
  I've played with CRM\_Core\_Session::getStatus() but it doesn't appear to be aware of this notification (likely because it's triggered via the tpl file rather than PHP).
  
  **Tags:** jquery
  
  
  ---
  
  ## 2 answers
  
  ### Answer by username_1 on 2016-08-19. Score: 1
  
  You are in the right path, if you look at the `CRM_Core_Session` class you'll see the method [getStatus](https://github.com/civicrm/civicrm-core/blob/4.6.19/CRM/Core/Session.php#L450) which takes a boolean as a parameter, if `TRUE`then it will reset the status.
  
  That said, I would create a [extension](https://wiki.civicrm.org/confluence/display/CRMDOC/Create+a+Module+Extension) or use an existing one and implement [hook\_civicrm\_postProcess](https://wiki.civicrm.org/confluence/display/CRMDOC/hook_civicrm_postProcess).
  
  You'll need to know what is the class/form name of the form you are targeting, an easy way would be to inspect the source of the form/page from which you want to remove/replace the notification and search for `.tpl`
  
  Example: `CRM/Contact/Form/Task/Email.tpl`, its class/form name would be `CRM_Contact_Form_Task_Email`
  
  Then in your extension:
  
  ```
  function myextension_civicrm_postProcess( $formName, &$form ) {
      if($formName == 'CRM_Contact_Form_Task_Email') {
          $session = CRM_Core_Session::singleton();
          // Reomve status message from form
          $session->getStatus( $reset = TRUE );
          // Set your new message
          $session::setStatus(ts('This is a custom message.'), ts('Custom Message'), 'success');
      }
  }
  
  ```
  
  
  ---
  
  ### Answer by username_2 on 2016-08-18. Score: 0
  
  I don't think Civi has a setting to turn OFF the notification
  
  But If you still need to turn Off the message or need to change the content of the message then you need to look for these files
  
  ~\civicrm\templates\CRM\Member\Form\Membership.tpl
  
  ~\civicrm\templates\CRM\Member\Form\MembershipStandalone.js
  
  you can override the files to your custom template folder and you can make changes or you can also disable the alert
  
  I guess this helps !!!
  
  
  ---
  
  