Skip to content

Commit

Permalink
Page -> Site variables
Browse files Browse the repository at this point in the history
  • Loading branch information
finanalyst committed May 10, 2018
1 parent 42bb26d commit 0e31e4e
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# v1.0.2
## 10 May 2018
1. [](#update)
* change TwigPageVariables to onTwigSiteVariables
# v1.0.1
## 10 May 2018
1. [](#update)
Expand Down
2 changes: 1 addition & 1 deletion blueprints.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: Sequential Form
version: 1.0.1
version: 1.0.2
description: A sequence of pages, each with a form is linked, with all form data processed according to the final process
icon: link
author:
Expand Down
4 changes: 2 additions & 2 deletions sequential-form.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ public function onPluginsInitialized()
// Enable the main event we are interested in
$this->enable([
'onTwigTemplatePaths' => ['onTwigTemplatePaths',0],
'onTwigPageVariables' => ['onTwigPageVariables',0],
'onTwigSiteVariables' => ['onTwigSiteVariables',0],
'onFormProcessed' => ['onFormProcessed', 0]
]);
}
Expand All @@ -41,7 +41,7 @@ public function onTwigTemplatePaths()
$this->grav['assets']->addCss('plugin://sequential-form/css/sqforms.css');
}
}
public function onTwigPageVariables() {
public function onTwigSiteVariables() {
// Is there a form with a sequence on this page?
$sequence = $this->grav['page']->header()->{'form'}['process'][0]['sequence'];
if ( $sequence ) {
Expand Down

0 comments on commit 0e31e4e

Please sign in to comment.