Fix comment form processing
This commit is contained in:
		
							parent
							
								
									f1b1f74348
								
							
						
					
					
						commit
						228ac73ba8
					
				
					 3 changed files with 4 additions and 1 deletions
				
			
		| 
						 | 
					@ -4,6 +4,8 @@
 | 
				
			||||||
1. [](#improved)
 | 
					1. [](#improved)
 | 
				
			||||||
    * Added Japanese translation
 | 
					    * Added Japanese translation
 | 
				
			||||||
    * Move captcha over email [#45](https://github.com/getgrav/grav-plugin-comments/issues/45)
 | 
					    * Move captcha over email [#45](https://github.com/getgrav/grav-plugin-comments/issues/45)
 | 
				
			||||||
 | 
					1. [](#bugfix)
 | 
				
			||||||
 | 
					    * Fix comment form processing
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# v1.2.6
 | 
					# v1.2.6
 | 
				
			||||||
## 01/09/2017
 | 
					## 01/09/2017
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -187,7 +187,7 @@ class CommentsPlugin extends Plugin
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        switch ($action) {
 | 
					        switch ($action) {
 | 
				
			||||||
            case 'addComment':
 | 
					            case 'addComment':
 | 
				
			||||||
                $post = !empty($_POST) ? $_POST : [];
 | 
					                $post = isset($_POST['data']) ? $_POST['data'] : [];
 | 
				
			||||||
 | 
					
 | 
				
			||||||
                $lang = filter_var(urldecode($post['lang']), FILTER_SANITIZE_STRING);
 | 
					                $lang = filter_var(urldecode($post['lang']), FILTER_SANITIZE_STRING);
 | 
				
			||||||
                $path = filter_var(urldecode($post['path']), FILTER_SANITIZE_STRING);
 | 
					                $path = filter_var(urldecode($post['path']), FILTER_SANITIZE_STRING);
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -1,4 +1,5 @@
 | 
				
			||||||
{% if grav.twig.enable_comments_plugin %}
 | 
					{% if grav.twig.enable_comments_plugin %}
 | 
				
			||||||
 | 
					    {% set scope = scope ?: 'data.' %}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    <h3>{{'PLUGIN_COMMENTS.ADD_COMMENT'|t}}</h3>
 | 
					    <h3>{{'PLUGIN_COMMENTS.ADD_COMMENT'|t}}</h3>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue