@@ -5,26 +5,26 @@ This extension allows submitting contact/callback/feedback forms from frontend s
5
5
## Installation
6
6
7
7
1 . Add to Gemfile:
8
-
9
- gem "kms_feedback"
10
- # or for edge version:
11
- gem "kms_feedback", github: "webgradus/kms_feedback"
8
+
9
+ gem "kms_feedback"
10
+ # or for edge version:
11
+ gem "kms_feedback", github: "webgradus/kms_feedback"
12
12
13
13
2 . Run generator:
14
14
15
- rails g kms_feedback: install
15
+ rails g kms_feedback:install
16
16
17
17
3 . Copy migrations:
18
18
19
- rails kms_feedback:install: migrations
19
+ rails kms_feedback:install:migrations
20
20
21
21
4 . Migrate:
22
22
23
- rails db: migrate
23
+ rails db:migrate
24
24
25
25
5 . Recompile assets:
26
26
27
- rails assets: precompile
27
+ rails assets:precompile
28
28
29
29
6 . Restart KMS instance
30
30
@@ -50,6 +50,7 @@ Form validation should happen completely on client side (you could use HTML5 att
50
50
You can use only some of fields - only ` name ` and ` phone ` for example.
51
51
52
52
To make AJAX submit you would have something like this JavaScript code:
53
+
53
54
<script>
54
55
$(document).ready(function(){
55
56
$('input[type="button"]').click(function(){
@@ -64,11 +65,11 @@ This extension also provides adding Recaptcha to forms. For adding validation wi
64
65
65
66
1 . Insert this fragment before closing </head > in your HTML:
66
67
67
- <script src =' https://www.google.com/recaptcha/api.js ' ></script >
68
+ <script src='https://www.google.com/recaptcha/api.js'></script>
68
69
69
70
2 . Insert this fragment at the bottom of <form > contents (where you need to place reCAPTCHA widget):
70
71
71
- <div class =" g-recaptcha " data-sitekey =" RECAPTCHA_PUBLIC_KEY " ></div >
72
+ <div class="g-recaptcha" data-sitekey="RECAPTCHA_PUBLIC_KEY"></div>
72
73
73
74
3 . Enable Recaptcha under "Settings" (check dropdown menu on avatar clicking)
74
75
0 commit comments