[pLog-svn] r5096 - in plugins/branches/lifetype-1.2: authimage/templates contentfilter/templates gravatar/templates hiddeninput/templates iconize/templates moderate/templates nofollow/templates openid/templates recentcomments/templates smileys/templates tagcloud/templates

Jon Daley plogworld at jon.limedaley.com
Thu Mar 15 15:44:32 EDT 2007


 	This is partially incorrect.  Checkboxes need to be disabled, and 
not readonly.  (At least on Firefox).

On Thu, 15 Mar 2007, oscar at devel.lifetype.net wrote:

> Author: oscar
> Date: 2007-03-15 15:29:43 -0400 (Thu, 15 Mar 2007)
> New Revision: 5096
>
> Modified:
>   plugins/branches/lifetype-1.2/authimage/templates/authimage.template
>   plugins/branches/lifetype-1.2/contentfilter/templates/filteredcontentsettings.template
>   plugins/branches/lifetype-1.2/gravatar/templates/gravatar.template
>   plugins/branches/lifetype-1.2/hiddeninput/templates/hiddeninput.template
>   plugins/branches/lifetype-1.2/iconize/templates/iconize.template
>   plugins/branches/lifetype-1.2/moderate/templates/pluginsettings.template
>   plugins/branches/lifetype-1.2/nofollow/templates/nofollow.template
>   plugins/branches/lifetype-1.2/openid/templates/openid.template
>   plugins/branches/lifetype-1.2/recentcomments/templates/recentcomments.template
>   plugins/branches/lifetype-1.2/smileys/templates/smileys.template
>   plugins/branches/lifetype-1.2/tagcloud/templates/tagcloud.template
> Log:
> Replaced "disabled" with "readonly" in all templates so that the browser sends the value of the field even if it cannot be overriden by the user.
>
>
> Modified: plugins/branches/lifetype-1.2/authimage/templates/authimage.template
> ===================================================================
> --- plugins/branches/lifetype-1.2/authimage/templates/authimage.template	2007-03-15 18:31:40 UTC (rev 5095)
> +++ plugins/branches/lifetype-1.2/authimage/templates/authimage.template	2007-03-15 19:29:43 UTC (rev 5096)
> @@ -9,7 +9,7 @@
>   <div class="field">
>    <label for="pluginEnabled">{$locale->tr("label_enable")}</label>
>    <div class="formHelp">
> -     <input class="checkbox" type="checkbox" name="pluginEnabled" id="pluginEnabled" {if $pluginEnabled}checked="checked"{/if} value="1" {user_cannot_override key=plugin_authimage_enabled}disabled="disabled"{/user_cannot_override} />{$locale->tr("authimage_plugin_enabled")}
> +     <input class="checkbox" type="checkbox" name="pluginEnabled" id="pluginEnabled" {if $pluginEnabled}checked="checked"{/if} value="1" {user_cannot_override key=plugin_authimage_enabled}readonly="readonly"{/user_cannot_override} />{$locale->tr("authimage_plugin_enabled")}
>    </div>
>   </div>
>
>
> Modified: plugins/branches/lifetype-1.2/contentfilter/templates/filteredcontentsettings.template
> ===================================================================
> --- plugins/branches/lifetype-1.2/contentfilter/templates/filteredcontentsettings.template	2007-03-15 18:31:40 UTC (rev 5095)
> +++ plugins/branches/lifetype-1.2/contentfilter/templates/filteredcontentsettings.template	2007-03-15 19:29:43 UTC (rev 5096)
> @@ -8,7 +8,7 @@
>   <div class="field">
>    <label for="pluginEnabled">{$locale->tr("label_enable")}</label>
>    <div class="formHelp">
> -    <input class="checkbox" type="checkbox" name="pluginEnabled" id="pluginEnabled" {if $pluginEnabled} checked="checked" {/if} value="1"  {user_cannot_override key=plugin_contentfilter_enabled}disabled="disabled"{/user_cannot_override} />{$locale->tr("contentfilter_plugin_enabled")}
> +    <input class="checkbox" type="checkbox" name="pluginEnabled" id="pluginEnabled" {if $pluginEnabled} checked="checked" {/if} value="1"  {user_cannot_override key=plugin_contentfilter_enabled}readonly="readonly"{/user_cannot_override} />{$locale->tr("contentfilter_plugin_enabled")}
>    </div>
>   </div>
>
>
> Modified: plugins/branches/lifetype-1.2/gravatar/templates/gravatar.template
> ===================================================================
> --- plugins/branches/lifetype-1.2/gravatar/templates/gravatar.template	2007-03-15 18:31:40 UTC (rev 5095)
> +++ plugins/branches/lifetype-1.2/gravatar/templates/gravatar.template	2007-03-15 19:29:43 UTC (rev 5096)
> @@ -10,7 +10,7 @@
>    <span class="required"></span>
>    <div class="formHelp">
>
> -     <input class="checkbox" type="checkbox" name="pluginEnabled" id="pluginEnabled" {if $pluginEnabled} checked="checked" {/if} value="1" {user_cannot_override key=plugin_gravatar_enabled}disabled="disabled"{/user_cannot_override}/>{$locale->tr("gravatar_plugin_enabled")}
> +     <input class="checkbox" type="checkbox" name="pluginEnabled" id="pluginEnabled" {if $pluginEnabled} checked="checked" {/if} value="1" {user_cannot_override key=plugin_gravatar_enabled}readonly="readonly"{/user_cannot_override}/>{$locale->tr("gravatar_plugin_enabled")}
>    </div>
>   </div>
>
> @@ -18,7 +18,7 @@
>    <label for="rating">{$locale->tr("label_rating")}</label>
>    <span class="required"></span>
>    <div class="formHelp">{$locale->tr("gravatar_rating")}</div>
> -   <select name="rating" id="rating" {user_cannot_override key=plugin_gravatar_rating}disabled="disabled"{/user_cannot_override}>
> +   <select name="rating" id="rating" {user_cannot_override key=plugin_gravatar_rating}readonly="readonly"{/user_cannot_override}>
>     <option value="G" {if $rating=="G"}selected="selected"{/if}>G</option>
>     <option value="PG" {if $rating=="PG"}selected="selected"{/if}>PG</option>
>     <option value="R" {if $rating=="R"}selected="selected"{/if}>R</option>
> @@ -30,7 +30,7 @@
>    <label for="size">{$locale->tr("label_size")}</label>
>    <div class="formHelp">{$locale->tr("gravatar_size")}</div>
>    <span class="required"></span>
> -   <select name="size" id="size" {user_cannot_override key=plugin_gravatar_size}disabled="disabled"{/user_cannot_override}>
> +   <select name="size" id="size" {user_cannot_override key=plugin_gravatar_size}readonly="readonly"{/user_cannot_override}>
>     <option value="30" {if $size==30}selected="selected"{/if}>30x30</option>
>     <option value="40" {if $size==40}selected="selected"{/if}>40x40</option>
>     <option value="50" {if $size==50}selected="selected"{/if}>50x50</option>
> @@ -56,7 +56,7 @@
>      {foreach from=$avatars item=avatar}
>      <tr>
>       <td>
> -       <input class="radio" type="radio" name="default" id="default" value="{$avatar}" {if $default==$avatar} checked="checked" {/if}  {user_cannot_override key=plugin_gravatar_default}disabled="disabled"{/user_cannot_override}/>
> +       <input class="radio" type="radio" name="default" id="default" value="{$avatar}" {if $default==$avatar} checked="checked" {/if}  {user_cannot_override key=plugin_gravatar_default}readonly="readonly"{/user_cannot_override}/>
>       </td>
>       <td>
>        {$avatar}
>
> Modified: plugins/branches/lifetype-1.2/hiddeninput/templates/hiddeninput.template
> ===================================================================
> --- plugins/branches/lifetype-1.2/hiddeninput/templates/hiddeninput.template	2007-03-15 18:31:40 UTC (rev 5095)
> +++ plugins/branches/lifetype-1.2/hiddeninput/templates/hiddeninput.template	2007-03-15 19:29:43 UTC (rev 5096)
> @@ -13,7 +13,7 @@
>            id="pluginEnabled" {if $pluginEnabled} checked="checked"
>            {/if}
>            {user_cannot_override
> -              key=plugin_hiddeninput_enabled}disabled="disabled"
> +              key=plugin_hiddeninput_enabled}readonly="readonly"
>            {/user_cannot_override}
>            value="1" />
>         {$locale->tr("hiddeninput_plugin_enabled")}
>
> Modified: plugins/branches/lifetype-1.2/iconize/templates/iconize.template
> ===================================================================
> --- plugins/branches/lifetype-1.2/iconize/templates/iconize.template	2007-03-15 18:31:40 UTC (rev 5095)
> +++ plugins/branches/lifetype-1.2/iconize/templates/iconize.template	2007-03-15 19:29:43 UTC (rev 5096)
> @@ -12,7 +12,7 @@
>    <label for="pluginEnabled">{$locale->tr("iconize_plugin_enabled")}</label>
>
>    <div class="formHelp">
> -    <input class="checkbox" type="checkbox" name="pluginEnabled" id="pluginEnabled" {if $pluginEnabled} checked="checked" {/if} value="1" {user_cannot_override key=plugin_iconize_enabled}disabled="disabled"{/user_cannot_override}/>{$locale->tr("iconize_plugin_enabled")}
> +    <input class="checkbox" type="checkbox" name="pluginEnabled" id="pluginEnabled" {if $pluginEnabled} checked="checked" {/if} value="1" {user_cannot_override key=plugin_iconize_enabled}readonly="readonly"{/user_cannot_override}/>{$locale->tr("iconize_plugin_enabled")}
>    </div>
>   </div>
>
>
> Modified: plugins/branches/lifetype-1.2/moderate/templates/pluginsettings.template
> ===================================================================
> --- plugins/branches/lifetype-1.2/moderate/templates/pluginsettings.template	2007-03-15 18:31:40 UTC (rev 5095)
> +++ plugins/branches/lifetype-1.2/moderate/templates/pluginsettings.template	2007-03-15 19:29:43 UTC (rev 5096)
> @@ -8,7 +8,7 @@
>   <div class="field">
>    <label for="pluginEnabled">{$locale->tr("label_enable")}</label>
>    <div class="formHelp">
> -    <input class="checkbox" type="checkbox" name="pluginEnabled" id="pluginEnabled" {if $pluginEnabled} checked="checked" {/if} value="1"  {user_cannot_override key=plugin_moderate_enabled}disabled="disabled"{/user_cannot_override}/>{$locale->tr("moderate_plugin_enabled")}
> +    <input class="checkbox" type="checkbox" name="pluginEnabled" id="pluginEnabled" {if $pluginEnabled} checked="checked" {/if} value="1"  {user_cannot_override key=plugin_moderate_enabled}readonly="readonly"{/user_cannot_override}/>{$locale->tr("moderate_plugin_enabled")}
>    </div>
>   </div>
>
>
> Modified: plugins/branches/lifetype-1.2/nofollow/templates/nofollow.template
> ===================================================================
> --- plugins/branches/lifetype-1.2/nofollow/templates/nofollow.template	2007-03-15 18:31:40 UTC (rev 5095)
> +++ plugins/branches/lifetype-1.2/nofollow/templates/nofollow.template	2007-03-15 19:29:43 UTC (rev 5096)
> @@ -8,7 +8,7 @@
>   <div class="field">
>    <label for="pluginEnabled">{$locale->tr("label_enable")}</label>
>    <div class="formHelp">
> -    <input class="checkbox" type="checkbox" name="pluginEnabled" id="pluginEnabled" {if $pluginEnabled} checked="checked" {/if} value="1" {user_cannot_override key=plugin_nofollow_enabled}disabled="disabled"{/user_cannot_override}/>{$locale->tr("nofollow_plugin_enabled")}
> +    <input class="checkbox" type="checkbox" name="pluginEnabled" id="pluginEnabled" {if $pluginEnabled} checked="checked" {/if} value="1" {user_cannot_override key=plugin_nofollow_enabled}readonly="readonly"{/user_cannot_override}/>{$locale->tr("nofollow_plugin_enabled")}
>    </div>
>   </div>
>
>
> Modified: plugins/branches/lifetype-1.2/openid/templates/openid.template
> ===================================================================
> --- plugins/branches/lifetype-1.2/openid/templates/openid.template	2007-03-15 18:31:40 UTC (rev 5095)
> +++ plugins/branches/lifetype-1.2/openid/templates/openid.template	2007-03-15 19:29:43 UTC (rev 5096)
> @@ -11,7 +11,7 @@
>     <input class="checkbox" type="checkbox" name="pluginEnabled"
>            id="pluginEnabled" {if $pluginEnabled} checked="checked" {/if}
>            {user_cannot_override
> -              key=plugin_openid_enabled}disabled="disabled"
> +              key=plugin_openid_enabled}readonly="readonly"
>            {/user_cannot_override}
>            value="1" />
>        {$locale->tr("openid_plugin_enabled")}
>
> Modified: plugins/branches/lifetype-1.2/recentcomments/templates/recentcomments.template
> ===================================================================
> --- plugins/branches/lifetype-1.2/recentcomments/templates/recentcomments.template	2007-03-15 18:31:40 UTC (rev 5095)
> +++ plugins/branches/lifetype-1.2/recentcomments/templates/recentcomments.template	2007-03-15 19:29:43 UTC (rev 5096)
> @@ -12,7 +12,7 @@
>     <input class="checkbox" type="checkbox" name="pluginEnabled"
>            id="pluginEnabled" {if $pluginEnabled} checked="checked" {/if}
>            {user_cannot_override
> -             key=plugin_recentcomments_enabled}disabled="disabled"
> +             key=plugin_recentcomments_enabled}readonly="readonly"
>            {/user_cannot_override}
>            value="1"
>      />{$locale->tr("recentcomments_plugin_enabled")}
> @@ -26,7 +26,7 @@
>    <div class="formHelp">{$locale->tr("recentcomments_maxcomments")}</div>
>    <input class="text" type="text" name="maxComments" id="maxComments"
>           {user_cannot_override
> -            key=plugin_recentcomments_maxcomments}disabled="disabled"
> +            key=plugin_recentcomments_maxcomments}readonly="readonly"
>           {/user_cannot_override}
>           value="{$maxComments}" width="10" />
>   </div>
>
> Modified: plugins/branches/lifetype-1.2/smileys/templates/smileys.template
> ===================================================================
> --- plugins/branches/lifetype-1.2/smileys/templates/smileys.template	2007-03-15 18:31:40 UTC (rev 5095)
> +++ plugins/branches/lifetype-1.2/smileys/templates/smileys.template	2007-03-15 19:29:43 UTC (rev 5096)
> @@ -9,7 +9,7 @@
>    <label for="pluginEnabled">{$locale->tr("label_enable")}</label>
>    <span class="required"></span>
>    <div class="formHelp">
> -     <input class="checkbox" type="checkbox" name="pluginEnabled" id="pluginEnabled" {if $pluginEnabled} checked="checked" {/if} value="1" {user_cannot_override key=plugin_smileys_enabled}disabled="disabled"{/user_cannot_override} /> {$locale->tr("smileys_plugin_enabled")}
> +     <input class="checkbox" type="checkbox" name="pluginEnabled" id="pluginEnabled" {if $pluginEnabled} checked="checked" {/if} value="1" {user_cannot_override key=plugin_smileys_enabled}readonly="readonly"{/user_cannot_override} /> {$locale->tr("smileys_plugin_enabled")}
>    </div>
>   </div>
>
>
> Modified: plugins/branches/lifetype-1.2/tagcloud/templates/tagcloud.template
> ===================================================================
> --- plugins/branches/lifetype-1.2/tagcloud/templates/tagcloud.template	2007-03-15 18:31:40 UTC (rev 5095)
> +++ plugins/branches/lifetype-1.2/tagcloud/templates/tagcloud.template	2007-03-15 19:29:43 UTC (rev 5096)
> @@ -12,7 +12,7 @@
>     <input class="checkbox" type="checkbox" name="pluginEnabled"
>            id="pluginEnabled" {if $pluginEnabled} checked="checked" {/if}
>            {user_cannot_override
> -               key=plugin_tagcloud_enabled}disabled="disabled"
> +               key=plugin_tagcloud_enabled}readonly="readonly"
>            {/user_cannot_override}
>            value="1" />{$locale->tr("tagcloud_plugin_enabled")}
>    </div>
> @@ -24,7 +24,7 @@
>    <div class="formHelp">{$locale->tr("tagcloud_articles")}</div>
>    <input class="text" type="text" name="articles" id="articles"
>           {user_cannot_override
> -              key=plugin_tagcloud_max_articles}disabled="disabled"
> +              key=plugin_tagcloud_max_articles}readonly="readonly"
>           {/user_cannot_override}
>           value="{$articles}" width="10" />
>   </div>
> @@ -35,7 +35,7 @@
>    <div class="formHelp">{$locale->tr("tagcloud_keywords")}</div>
>    <input class="text" type="text" name="keyword" id="keyword"
>            {user_cannot_override
> -               key=plugin_tagcloud_max_keywords}disabled="disabled"
> +               key=plugin_tagcloud_max_keywords}readonly="readonly"
>            {/user_cannot_override}
>           value="{$keyword}" width="10" />
>   </div>
> @@ -46,7 +46,7 @@
>    <div class="formHelp">{$locale->tr("tagcloud_min_font")}</div>
>    <input class="text" type="text" name="minFont" id="minFont"
>            {user_cannot_override
> -               key=plugin_tagcloud_min_size}disabled="disabled"
> +               key=plugin_tagcloud_min_size}readonly="readonly"
>            {/user_cannot_override}
>            value="{$minFont}" width="10" />
>   </div>
> @@ -57,7 +57,7 @@
>    <div class="formHelp">{$locale->tr("tagcloud_max_font")}</div>
>    <input class="text" type="text" name="maxFont" id="maxFont"
>            {user_cannot_override
> -               key=plugin_tagcloud_max_size}disabled="disabled"
> +               key=plugin_tagcloud_max_size}readonly="readonly"
>            {/user_cannot_override}
>           value="{$maxFont}" width="10" />
>   </div>
> @@ -68,7 +68,7 @@
>    <div class="formHelp">{$locale->tr("tagcloud_min_weight")}</div>
>    <input class="text" type="text" name="minWeight" id="minWeight"
>            {user_cannot_override
> -               key=plugin_tagcloud_min_weight}disabled="disabled"
> +               key=plugin_tagcloud_min_weight}readonly="readonly"
>            {/user_cannot_override}
>           value="{$minWeight}" width="10" />
>   </div>
> @@ -79,7 +79,7 @@
>    <div class="formHelp">{$locale->tr("tagcloud_max_weight")}</div>
>    <input class="text" type="text" name="maxWeight" id="maxWeight"
>            {user_cannot_override
> -               key=plugin_tagcloud_max_weight}disabled="disabled"
> +               key=plugin_tagcloud_max_weight}readonly="readonly"
>            {/user_cannot_override}
>           value="{$maxWeight}" width="10" />
>   </div>
> @@ -90,7 +90,7 @@
>    <div class="formHelp">{$locale->tr("tagcloud_min_word_length")}</div>
>    <input class="text" type="text" name="minWordLength"
>            {user_cannot_override
> -               key=plugin_tagcloud_min_word_length}disabled="disabled"
> +               key=plugin_tagcloud_min_word_length}readonly="readonly"
>            {/user_cannot_override}
>           id="minWordLength" value="{$minWordLength}" width="3" />
>   </div>
> @@ -102,7 +102,7 @@
>    <div class="formHelp">{$locale->tr("tagcloud_banned_keywords")}</div>
>    <input class="text" type="text" name="bannedKeywords"
>            {user_cannot_override
> -               key=plugin_tagcloud_banned_keywords}disabled="disabled"
> +               key=plugin_tagcloud_banned_keywords}readonly="readonly"
>            {/user_cannot_override}
>           id="bannedKeywords" value="{$bannedKeywords}" width="10" />
>   </div>
>
> _______________________________________________
> pLog-svn mailing list
> pLog-svn at devel.lifetype.net
> http://limedaley.com/mailman/listinfo/plog-svn
>

-- 
Jon Daley
http://jon.limedaley.com/

I always blame the software. Unless I wrote it.
Then I blame the hardware.
-- Forest Godfrey


More information about the pLog-svn mailing list