# Conditional Save and Continue

**URL:** <https://community.gravityforms.com/t/conditional-save-and-continue/1293>\
**Category:** Get Help\
**Tags:** save-and-continue\
**Created:** [March 14, 2019, 5:29am UTC](https://community.gravityforms.com/t/conditional-save-and-continue/1293 "2019-03-14T05:29:23Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Parkbum](https://sea2.discourse-cdn.com/flex020/user_avatar/community.gravityforms.com/parkbum/32/810_2.png) [@Parkbum](https://community.gravityforms.com/u/Parkbum)\
**Post date:** [March 14, 2019, 5:29am UTC](https://community.gravityforms.com/t/conditional-save-and-continue/1293/1 "2019-03-14T05:29:23Z")

</div>

Hey Homies,  
So this is actually a different form, but my last resolution opened the door to doing this. Is there a way to activate the Save and Continue, like on the second page of a form. In example, hiding it from some users.

I have an invoice system, but I want Admin to be able to Save and Email the invoices and be able to come back and apply a credit card.

I just had the thought that I COULD try to hide the link by adding the Style in Javascript to “display:none;” but let’s see if there are any other ideas hanging out there…

---

<div class="post-metadata">

**Author:** ![Parkbum](https://sea2.discourse-cdn.com/flex020/user_avatar/community.gravityforms.com/parkbum/32/810_2.png) [@Parkbum](https://community.gravityforms.com/u/Parkbum)\
**Post date:** [May 28, 2019, 11:01pm UTC](https://community.gravityforms.com/t/conditional-save-and-continue/1293/2 "2019-05-28T23:01:40Z")

</div>

Hey, so I’m coming back around to this here. What API/Function would I use to preform an action after Save and Continue is clicked?

i.e. I’ve been messing around with:

```
add_filter( 'gform_incomplete_submission_pre_save', 'save_submission_37', 10, 3 );
function save_submission_37( $submission_json, $resume_token, $form){
  if( $form['id'] == 37 ){
		echo '<script>alert("BOOM");</script>';
	    return $submission_json;
  }
}

```

And it keeps mucking up the Save. I’ve tried removing the `echo`, and moving around the `return`. Any ideas on how I could make this work properly?

---

<div class="post-metadata">

**Author:** ![Parkbum](https://sea2.discourse-cdn.com/flex020/user_avatar/community.gravityforms.com/parkbum/32/810_2.png) [@Parkbum](https://community.gravityforms.com/u/Parkbum)\
**Post date:** [May 28, 2019, 11:49pm UTC](https://community.gravityforms.com/t/conditional-save-and-continue/1293/3 "2019-05-28T23:49:20Z")

</div>

nvm, accidentally had two similar functions going. Anywho, anyone needing something similar, it should look something like this:

```
add_filter( 'gform_incomplete_submission_pre_save', 'save_submission_37', 10, 3 );
function save_submission_37( $submission_json, $resume_token, $form){
  if( $form['id'] == 37 ){
	$updated_json = json_decode( $submission_json );
	$test = var_dump($updated_json);		
  }
  return $submission_json;
}
```

---

<div class="post-metadata">

**Author:** ![chrishajer](https://sea2.discourse-cdn.com/flex020/user_avatar/community.gravityforms.com/chrishajer/32/88_2.png) [@chrishajer](https://community.gravityforms.com/u/chrishajer)\
**Post date:** [May 30, 2019, 3:56am UTC](https://community.gravityforms.com/t/conditional-save-and-continue/1293/4 "2019-05-30T03:56:46Z")

</div>


