當前位置: 首頁>>代碼示例>>PHP>>正文


PHP GFFormDetail::color_picker方法代碼示例

本文整理匯總了PHP中GFFormDetail::color_picker方法的典型用法代碼示例。如果您正苦於以下問題:PHP GFFormDetail::color_picker方法的具體用法?PHP GFFormDetail::color_picker怎麽用?PHP GFFormDetail::color_picker使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在GFFormDetail的用法示例。


在下文中一共展示了GFFormDetail::color_picker方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: field_settings

    public function field_settings($position, $form_id)
    {
        //create settings on position 25 (right after Field Label)
        if ($position == 25) {
            ?>
			<li class="background_color_setting field_setting gform_setting_left_half">
				<label for="field_signature_background_color">
					<?php 
            _e('Background Color', 'gravityformssignature');
            ?>
					<?php 
            gform_tooltip('signature_background_color');
            ?>
				</label>
				<?php 
            GFFormDetail::color_picker('field_signature_background_color', 'SetSignatureBackColor');
            ?>
			</li>
			<li class="border_color_setting field_setting gform_setting_right_half">
				<label for="field_signature_border_color">
					<?php 
            _e('Border Color', 'gravityformssignature');
            ?>
					<?php 
            gform_tooltip('signature_border_color');
            ?>
				</label>
				<?php 
            GFFormDetail::color_picker('field_signature_border_color', 'SetSignatureBorderColor');
            ?>
			</li>
			<li class="border_width_setting field_setting gform_setting_left_half">
				<label for="field_signature_border_width">
					<?php 
            _e('Border Width', 'gravityformssignature');
            ?>
					<?php 
            gform_tooltip('signature_border_width');
            ?>
				</label>
				<select id="field_signature_border_width" onchange="SetSignatureBorderWidth(jQuery(this).val());">
					<option value="0">None</option>
					<option value="1">Small</option>
					<option value="2">Medium</option>
					<option value="3">Large</option>
				</select>
			</li>
			<li class="border_style_setting field_setting gform_setting_right_half">
				<label for="field_signature_border_style">
					<?php 
            _e('Border Style', 'gravityformssignature');
            ?>
					<?php 
            gform_tooltip('signature_border_style');
            ?>
				</label>
				<select id="field_signature_border_style" onchange="SetSignatureBorderStyle(jQuery(this).val());">
					<option>Dotted</option>
					<option>Dashed</option>
					<option>Groove</option>
					<option>Ridge</option>
					<option>Inset</option>
					<option>Outset</option>
					<option>Double</option>
					<option>Solid</option>
				</select>
			</li>

			<li class="pen_color_setting field_setting gform_setting_left_half">
				<label for="field_signature_pen_color">
					<?php 
            _e('Pen Color', 'gravityformssignature');
            ?>
					<?php 
            gform_tooltip('signature_pen_color');
            ?>
				</label>
				<?php 
            GFFormDetail::color_picker('field_signature_pen_color', 'SetSignaturePenColor');
            ?>
			</li>
			<li class="pen_size_setting field_setting gform_setting_right_half">
				<label for="field_signature_pen_size">
					<?php 
            _e('Pen Size', 'gravityformssignature');
            ?>
					<?php 
            gform_tooltip('signature_pen_size');
            ?>
				</label>
				<select id="field_signature_pen_size" onchange="SetSignaturePenSize(jQuery(this).val());">
					<option value="1">Small</option>
					<option value="2">Medium</option>
					<option value="3">Large</option>
				</select>
			</li>

		<?php 
        }
    }
開發者ID:ajay786singh,項目名稱:viriditas-1,代碼行數:100,代碼來源:class-gf-signature.php

示例2: field_settings

    /**
     * Add the custom settings for the Signature field to the Appearance tab.
     *
     * @param int $position The position the settings should be located at.
     * @param int $form_id The ID of the form currently being edited.
     */
    public function field_settings($position, $form_id)
    {
        if ($position == 0) {
            ?>
			<li class="background_color_setting field_setting gform_setting_left_half">
				<label for="field_signature_background_color" class="section_label">
					<?php 
            esc_html_e('Background Color', 'gravityformssignature');
            ?>
					<?php 
            gform_tooltip('signature_background_color');
            ?>
				</label>
				<?php 
            GFFormDetail::color_picker('field_signature_background_color', 'SetSignatureBackColor');
            ?>
			</li>
			<li class="border_color_setting field_setting gform_setting_right_half">
				<label for="field_signature_border_color" class="section_label">
					<?php 
            esc_html_e('Border Color', 'gravityformssignature');
            ?>
					<?php 
            gform_tooltip('signature_border_color');
            ?>
				</label>
				<?php 
            GFFormDetail::color_picker('field_signature_border_color', 'SetSignatureBorderColor');
            ?>
			</li>
			<li class="border_width_setting field_setting gform_setting_left_half">
				<label for="field_signature_border_width" class="section_label">
					<?php 
            esc_html_e('Border Width', 'gravityformssignature');
            ?>
					<?php 
            gform_tooltip('signature_border_width');
            ?>
				</label>
				<select id="field_signature_border_width" onchange="SetSignatureBorderWidth(jQuery(this).val());">
					<option value="0"><?php 
            esc_html_e('None', 'gravityformssignature');
            ?>
</option>
					<option value="1"><?php 
            esc_html_e('Small', 'gravityformssignature');
            ?>
</option>
					<option value="2"><?php 
            esc_html_e('Medium', 'gravityformssignature');
            ?>
</option>
					<option value="3"><?php 
            esc_html_e('Large', 'gravityformssignature');
            ?>
</option>
				</select>
			</li>
			<li class="border_style_setting field_setting gform_setting_right_half">
				<label for="field_signature_border_style" class="section_label">
					<?php 
            esc_html_e('Border Style', 'gravityformssignature');
            ?>
					<?php 
            gform_tooltip('signature_border_style');
            ?>
				</label>
				<select id="field_signature_border_style" onchange="SetSignatureBorderStyle(jQuery(this).val());">
					<option value="dotted"><?php 
            esc_html_e('Dotted', 'gravityformssignature');
            ?>
</option>
					<option value="dashed"><?php 
            esc_html_e('Dashed', 'gravityformssignature');
            ?>
</option>
					<option value="groove"><?php 
            esc_html_e('Groove', 'gravityformssignature');
            ?>
</option>
					<option value="ridge"><?php 
            esc_html_e('Ridge', 'gravityformssignature');
            ?>
</option>
					<option value="inset"><?php 
            esc_html_e('Inset', 'gravityformssignature');
            ?>
</option>
					<option value="outset"><?php 
            esc_html_e('Outset', 'gravityformssignature');
            ?>
</option>
					<option value="double"><?php 
            esc_html_e('Double', 'gravityformssignature');
//.........這裏部分代碼省略.........
開發者ID:wp-premium,項目名稱:gravityformssignature,代碼行數:101,代碼來源:class-gf-signature.php


注:本文中的GFFormDetail::color_picker方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。