Google Forms - Version 0.51

Version Description

No known upgrade issues.

Download this release

Release Info

Developer mpwalsh8
Plugin Icon wp plugin Google Forms
Version 0.51
Comparing to
See all releases

Code changes from version 0.50 to 0.51

Files changed (3) hide show
  1. index.php +3 -3
  2. readme.txt +68 -3
  3. wpgform-options.php +1 -1
index.php CHANGED
@@ -4,8 +4,8 @@
4
  * Plugin Name: WordPress Google Form
5
  * Plugin URI: http://michaelwalsh.org/wordpress/wordpress-plugins/wpgform/
6
  * Description: Add Google Forms to a WordPress web site. Display a Google Form directly into your posts, pages or sidebar. Style the Google Form to match your existing theme and display a custom confirmation page after form submission.
7
- * Version: 0.50
8
- * Build: 0.50.$WCREV$
9
  * Last Modified: $WCDATE$
10
  * Author: Mike Walsh
11
  * Author URI: http://www.michaelwalsh.org
@@ -25,7 +25,7 @@
25
  *
26
  */
27
 
28
- define('WPGFORM_VERSION', '0.50') ;
29
 
30
  require_once('wpgform-core.php') ;
31
  require_once('wpgform-post-type.php') ;
4
  * Plugin Name: WordPress Google Form
5
  * Plugin URI: http://michaelwalsh.org/wordpress/wordpress-plugins/wpgform/
6
  * Description: Add Google Forms to a WordPress web site. Display a Google Form directly into your posts, pages or sidebar. Style the Google Form to match your existing theme and display a custom confirmation page after form submission.
7
+ * Version: 0.51
8
+ * Build: 0.51.$WCREV$
9
  * Last Modified: $WCDATE$
10
  * Author: Mike Walsh
11
  * Author URI: http://www.michaelwalsh.org
25
  *
26
  */
27
 
28
+ define('WPGFORM_VERSION', '0.51') ;
29
 
30
  require_once('wpgform-core.php') ;
31
  require_once('wpgform-post-type.php') ;
readme.txt CHANGED
@@ -4,7 +4,7 @@ Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_i
4
  Tags: Google Forms, Google Docs, Google, Spreadsheet, shortcode, forms
5
  Requires at least: 3.3
6
  Tested up to: 3.5.1
7
- Stable tag: 0.50
8
 
9
  Embeds a published, public Google Form in a WordPress post, page, or widget.
10
 
@@ -79,12 +79,36 @@ Yes, there are two ways to change the style (aka apearance) of the form.
79
 
80
  Google Forms include plenty of [CSS](http://en.wikipedia.org/wiki/Cascading_Style_Sheets) hooks. Refer to the **CSS** section for further details on styling the form. There are also some CSS solutions posted to questions users have raised in the Tips and Tricks section of [this page](http://michaelwalsh.org/wordpress/wordpress-plugins/wpgform/tips-and-tricks/).
81
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
82
  = Why do I get a 403 error? =
83
 
84
  There a number of reasons to get a 403 error but by far the most common one encountered so far is due to ModSecurity being installed by your web hosting provider. Not all providers deploy ModSecurity but enough do that it comes up every once in a while. If your provider is running ModSecurity and your version of the plugin is v0.30 or lower, you will likely see odd behavior where when the form is submitted, the page is simply rendered again and the data is never actually sent to Google. There isn't any error message to indicate what might be wrong.
85
 
86
  Version 0.31 fixes this problem for *most* cases but there is still a chance that it could crop up. If your provider has enabled ModSecurity AND someone answers one of the questions on your form with a URL (e.g. http://www.example.com), then very likely ModSecurity will kick in an issue a 403 error. The plugin is now smart enough to detect when the error is issued and let you know what is wrong. Unfortunately there isn't currently a solution to allow URLs as responses when ModSecurity issues a 403 error.
87
 
 
 
88
  = No matter what I do, I always get the "Unable to retrieve Google Form. Please try reloading this page." error message. Why is this? =
89
 
90
  1. The most common reason for this error is from pasting the Google Form URL into the WordPress WYSIWYG Editor while in "Visual" mode. When you paste the URL, the Visual Editor recognizes at a link and wraps the text in the apprpriate HTML tags so the link will work. Visually you'll trypically see the URL in a different color than the rest of the short code text. If this happens, simply click anywhere in the link and use the "Break Link" icon (broken chain) on the tool bar to remove the link. The other alternative is to toggle to HTML mode and manually remove the HTML which is wrapped around the URL.
@@ -128,7 +152,7 @@ This isn't possible. The process of splitting the form into columns is automati
128
 
129
  == CSS ==
130
 
131
- As of 2011-09-21, Google Forms make use of 20+ CSS class definitions. By default, the WordPress Google Form plugin includes CSS declarations for all of the classes however the bulk of them are empty. The default CSS sets the font and makes the entry boxes wider. The default CSS that ships with WordPress Google Form can optionally be turned off via the WordPress Google Form settings.
132
 
133
  = Customizing Google Form CSS =
134
 
@@ -139,9 +163,19 @@ There are two ways to customize the Google Form CSS.
139
 
140
  = Default Google Form CSS =
141
 
142
- As of 2012-12-15, the following is are the CSS classes which Google Forms make use of. The CSS below represents the default CSS provided by WordPress Google Form. These CSS definitions can be copied and pasted into your theme CSS or the WordPress Google Form custom CSS setting and changed as desired.
143
 
144
  `
 
 
 
 
 
 
 
 
 
 
145
  label.gform-error,
146
  label.wpgform-error {
147
  float: right;
@@ -241,6 +275,33 @@ textarea.ss-q-long {
241
  font-family: "Trebuchet MS", Verdana, Arial, Helvetica, sans-serif;
242
  }
243
  tr.ss-gridrow {}
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
244
  `
245
 
246
  == Screenshots ==
@@ -255,6 +316,10 @@ No known upgrade issues.
255
 
256
  == Changelog ==
257
 
 
 
 
 
258
  = Version 0.50 =
259
  * Fixed jQuery syntax error which happens when validation is on but CAPTCHA and Email User is off.
260
  * Added new CSS to hide the "Never submit passwords through Google Forms." message by default.
4
  Tags: Google Forms, Google Docs, Google, Spreadsheet, shortcode, forms
5
  Requires at least: 3.3
6
  Tested up to: 3.5.1
7
+ Stable tag: 0.51
8
 
9
  Embeds a published, public Google Form in a WordPress post, page, or widget.
10
 
79
 
80
  Google Forms include plenty of [CSS](http://en.wikipedia.org/wiki/Cascading_Style_Sheets) hooks. Refer to the **CSS** section for further details on styling the form. There are also some CSS solutions posted to questions users have raised in the Tips and Tricks section of [this page](http://michaelwalsh.org/wordpress/wordpress-plugins/wpgform/tips-and-tricks/).
81
 
82
+ = Why are the buttons and some other text on form in Chinese (or some other language)? =
83
+
84
+ This problem occurred fairly infrequently with the older version of Google Forms but with the upgrade in early 2013, it seems to happen much more often. The solution to this problem depends on which URL format your published Google Form takes on (old or new).
85
+
86
+ If your form URL looks like this, then you are using the older version of Google Forms:
87
+
88
+ `https://docs.google.com/spreadsheet/viewform?formkey=dE56R1ZldXo4a0N3VTNMNEpSemdGV3c6MQ#gid=0`
89
+
90
+ To force the language to English, you need to include the parameter **hl=en**. Placement doesn't matter except it must appear before the #gid=0 (or similar syntax depending on which sheet you're using). You will either need to prefix or append the & character to ensure the parameter is passed correctly.
91
+
92
+ `https://docs.google.com/spreadsheet/viewform?formkey=dE56R1ZldXo4a0N3VTNMNEpSemdGV3c6MQ&hl=en#gid=0`
93
+
94
+ If your form URL looks like this, then you are using the new version of Google Forms:
95
+
96
+ `https://docs.google.com/forms/d/1iQndtNhFFiLHPdTpvuYKifdsxN7XQSFa9D8CsTU8aTc/viewform`
97
+
98
+ To force the form to use English you would append **"?hl=en"** to the URL so it looks like this:
99
+
100
+ `https://docs.google.com/forms/d/1iQndtNhFFiLHPdTpvuYKifdsxN7XQSFa9D8CsTU8aTc/viewform?hl=en`
101
+
102
+ You can find an [example Google Form with French buttons](http://michaelwalsh.org/wordpress/wordpress-plugins/wpgform/sample-form-in-french/) on the plugin web site.
103
+
104
  = Why do I get a 403 error? =
105
 
106
  There a number of reasons to get a 403 error but by far the most common one encountered so far is due to ModSecurity being installed by your web hosting provider. Not all providers deploy ModSecurity but enough do that it comes up every once in a while. If your provider is running ModSecurity and your version of the plugin is v0.30 or lower, you will likely see odd behavior where when the form is submitted, the page is simply rendered again and the data is never actually sent to Google. There isn't any error message to indicate what might be wrong.
107
 
108
  Version 0.31 fixes this problem for *most* cases but there is still a chance that it could crop up. If your provider has enabled ModSecurity AND someone answers one of the questions on your form with a URL (e.g. http://www.example.com), then very likely ModSecurity will kick in an issue a 403 error. The plugin is now smart enough to detect when the error is issued and let you know what is wrong. Unfortunately there isn't currently a solution to allow URLs as responses when ModSecurity issues a 403 error.
109
 
110
+ Some themes filter page content which could potentially affect forms. If the filter modifies the Google Form HTML in such a way (e.g. changing the value of a hidden form variable) such that it is different that what Google is expecting upon form submission, a 403 error may result.
111
+
112
  = No matter what I do, I always get the "Unable to retrieve Google Form. Please try reloading this page." error message. Why is this? =
113
 
114
  1. The most common reason for this error is from pasting the Google Form URL into the WordPress WYSIWYG Editor while in "Visual" mode. When you paste the URL, the Visual Editor recognizes at a link and wraps the text in the apprpriate HTML tags so the link will work. Visually you'll trypically see the URL in a different color than the rest of the short code text. If this happens, simply click anywhere in the link and use the "Break Link" icon (broken chain) on the tool bar to remove the link. The other alternative is to toggle to HTML mode and manually remove the HTML which is wrapped around the URL.
152
 
153
  == CSS ==
154
 
155
+ Google Forms make use of 20+ CSS class definitions. By default, the WordPress Google Form plugin includes CSS declarations for all of the classes however the bulk of them are empty. The default CSS sets the font and makes the entry boxes wider. The default CSS that ships with WordPress Google Form can optionally be turned off via the WordPress Google Form settings.
156
 
157
  = Customizing Google Form CSS =
158
 
163
 
164
  = Default Google Form CSS =
165
 
166
+ As of 2013-05-17, the following is are the CSS classes which Google Forms make use of. The CSS below represents the default CSS provided by WordPress Google Form. These CSS definitions can be copied and pasted into your theme CSS or the WordPress Google Form custom CSS setting and changed as desired. Some of the classes are redundant to account for both the new and old style of Google Forms.
167
 
168
  `
169
+ /* vim: set expandtab tabstop=4 shiftwidth=4: */
170
+ /**
171
+ * CSS declarations for Google Docs Forms
172
+ *
173
+ * These can be copied and modified to fit the needs of
174
+ * a theme. By default the only change is to make all of
175
+ * the fields wider than their default width and to set the
176
+ * default font.
177
+ */
178
+
179
  label.gform-error,
180
  label.wpgform-error {
181
  float: right;
275
  font-family: "Trebuchet MS", Verdana, Arial, Helvetica, sans-serif;
276
  }
277
  tr.ss-gridrow {}
278
+
279
+ /**
280
+ * New Google Forms CSS 2013-04-30
281
+ */
282
+
283
+ div.ss-form-container div.disclaimer {
284
+ display: none;
285
+ }
286
+
287
+ div.ss-q-help {
288
+ }
289
+
290
+ div.ss-secondary-text {
291
+ }
292
+
293
+ /* This hides the "Never submit passwords through Google Forms." warning. */
294
+ div.ss-form-entry > div.ss-secondary-text {
295
+ display: none;
296
+ }
297
+
298
+ div.password-warning {
299
+ display: none;
300
+ }
301
+
302
+ div.ss-form-container li {
303
+ list-style-type: none;
304
+ }
305
  `
306
 
307
  == Screenshots ==
316
 
317
  == Changelog ==
318
 
319
+ = Version 0.51 =
320
+ * Added FAQ content for common questions.
321
+ * Updated CSS information to account for CSS changes in new Google Forms.
322
+
323
  = Version 0.50 =
324
  * Fixed jQuery syntax error which happens when validation is on but CAPTCHA and Email User is off.
325
  * Added new CSS to hide the "Never submit passwords through Google Forms." message by default.
wpgform-options.php CHANGED
@@ -171,7 +171,7 @@ function wpgform_options_page()
171
  <div class="inside">
172
  <div style="text-align: center; font-size: 0.75em;padding:0px 5px;margin:0px auto;"><!-- PayPal box wrapper -->
173
  <div><!-- PayPal box-->
174
- <p style="margin: 0.25em 0"><b>WordPress Goolge Forms <?php echo WPGFORM_VERSION; ?></b></p>
175
  <p style="margin: 0.25em 0"><a href="http://wordpress.org/extend/plugins/wpgform/" target="_blank"><?php _e('Plugin\'s Home Page', MAILUSERS_I18N_DOMAIN); ?></a></p>
176
  <form action="https://www.paypal.com/cgi-bin/webscr" method="post">
177
  <input type="hidden" name="cmd" value="_s-xclick">
171
  <div class="inside">
172
  <div style="text-align: center; font-size: 0.75em;padding:0px 5px;margin:0px auto;"><!-- PayPal box wrapper -->
173
  <div><!-- PayPal box-->
174
+ <p style="margin: 0.25em 0"><b>WordPress Goolge Forms v<?php echo WPGFORM_VERSION; ?></b></p>
175
  <p style="margin: 0.25em 0"><a href="http://wordpress.org/extend/plugins/wpgform/" target="_blank"><?php _e('Plugin\'s Home Page', MAILUSERS_I18N_DOMAIN); ?></a></p>
176
  <form action="https://www.paypal.com/cgi-bin/webscr" method="post">
177
  <input type="hidden" name="cmd" value="_s-xclick">