コード例 #1
0
						<div class="field-wrap">
							<input type="text" name="sale_price" value="<?php 
                    echo esc_attr(ThemexWoo::$data['product']['sale_price']);
                    ?>
" />
						</div>
					</td>
				</tr>
				<?php 
                }
                ?>
				<?php 
                if (in_array(ThemexCore::getOption('product_type', 'all'), array('all', 'physical'))) {
                    ?>
				<?php 
                    if (themex_taxonomy('product_shipping_class') && ThemexWoo::isShipping()) {
                        ?>
				<tr class="trigger-type-physical">
					<th><?php 
                        _e('Shipping Class', 'makery');
                        ?>
</th>
					<td>
						<div class="element-select">
							<span></span>
							<?php 
                        echo ThemexInterface::renderOption(array('id' => 'shipping_class', 'type' => 'select_category', 'taxonomy' => 'product_shipping_class', 'value' => ThemexWoo::$data['product']['shipping_class'], 'wrap' => false));
                        ?>
						</div>
					</td>
				</tr>
コード例 #2
0
ファイル: themex.user.php プロジェクト: qhuit/UrbanPekor
 /**
  * Gets user
  *
  * @access public
  * @param int $ID
  * @param bool $extended
  * @return array
  */
 public static function getUser($ID, $extended = false)
 {
     $data = get_userdata($ID);
     if ($data != false) {
         $user['login'] = $data->user_login;
         $user['email'] = $data->user_email;
         $user['date'] = $data->user_registered;
     }
     $user['ID'] = $ID;
     $user['profile'] = self::getProfile($ID);
     $user['settings'] = self::getSettings($ID);
     $user['shop'] = self::getShop($ID);
     $user['favorites'] = array_reverse(ThemexCore::getUserRelations($ID, 0, 'product'));
     $user['shops'] = ThemexCore::getUserRelations($ID, 0, 'shop');
     $user['updates'] = ThemexWoo::getRelations($user['shops']);
     $user['clicks'] = intval(ThemexCore::getUserMeta($ID, 'clicks'));
     $user['profit'] = round(floatval(ThemexCore::getUserMeta($ID, 'profit')), 2);
     $user['balance'] = round(floatval(ThemexCore::getUserMeta($ID, 'balance')), 2);
     if ($extended) {
         $user['links'] = self::getLinks($ID, array('shops' => !ThemexCore::checkOption('shop_multiple'), 'shop' => themex_status($user['shop']) == 'publish', 'referrals' => !ThemexCore::checkOption('shop_referrals'), 'woocommerce' => ThemexWoo::isActive(), 'address' => !ThemexCore::checkOption('profile_address'), 'links' => !ThemexCore::checkOption('profile_links'), 'shipping' => !ThemexCore::checkOption('shop_shipping') && ThemexWoo::isShipping()));
     }
     return $user;
 }