<?php 
/*
  reset($languages_arr);
  foreach( $languages_arr as $lang ) {
    echo $lang['name'].'  ';
  }
*/
?>
      <td valign="top" class="BillSavedProfiles" width="7%"><?php 
echo PDFBILL_LOAD_PROFILE;
?>
</td>
  <td>
<?php 
$profile_list = profile_list();
foreach ($profile_list as $p) {
    ?>
            <a id="SelectCat" onFocus="if(this.blur)this.blur()" class='btn btn-default' href="<?php 
    echo $PHP_SELF;
    ?>
?profile_name=<?php 
    echo $p['profile_name'];
    ?>
">
              <?php 
    echo $p['profile_name'];
    ?>
            </a>
            
            <?php 
Exemple #2
0
					<div>
						<label for="id_username">Username / User ID</label>
						<input id="id_username" type="text" name="username" maxlength="32" value="<?php 
echo isset($_POST['username']) ? $_POST['username'] : '';
?>
" />
						<p>Bebo, Facebook? Use the number in the URL of your 'Profile' page (e.g. <?php 
$rand = rand(100000000, 999999999);
echo $rand;
?>
)</p>
					</div>
					<div><input type="submit" name="save" id="id_save_2" value="Add Social Network" class="button" /></div>
					<div class="networks">
						<?php 
echo profile_list(true);
?>
					</div>
				</fieldset>
			</form>
			
			<form id="profile2" method="post" action="<?php 
echo $_SERVER['PHP_SELF'];
?>
#profile2">
				<fieldset>
					<legend>Avatar</legend>
					<input type="hidden" name="form_name" id="id_form_name" value="profile_form" />
					<div>
						<label for="id_photo_url">Profile Photo URL</label>
						<input type="text" name="photo_url" id="id_photo_url" value="<?php 
function profile_automatic_select($order)
{
    #Getting all pdf profiles with rules
    $pdf_profiles = profile_list();
    #Getting comparation data from order
    $order_data = array('country' => str_replace(' ', '', $order->billing['country']), 'shipping' => str_replace(' ', '', $order->info['shipping_method']), 'payment' => str_replace(' ', '', get_payment_name($order->info['payment_method'])), 'order' => str_replace(' ', '', xtc_get_order_status_name($order->info['orders_status'])), 'customer' => str_replace(' ', '', $order->info['status_name']));
    #Going trough profiles with rules and comparing rule data with order data
    foreach ($pdf_profiles as $pdf_profile) {
        $found = false;
        if (($profile_rules = $pdf_profile['rules']) != '') {
            $profile_name = $pdf_profile['profile_name'];
            $compare_results_array = array();
            $rules_complete_array = explode(' ', $profile_rules);
            $rules_groups_array = array_chunk($rules_complete_array, 4);
            foreach ($rules_groups_array as $rule) {
                foreach (compare_rule_values($rule, $order_data[$rule[0]]) as $compare_results) {
                    array_push($compare_results_array, $compare_results);
                }
            }
            #Split array in groups
            $results_array = array();
            $x = 0;
            foreach ($compare_results_array as $value) {
                if ($value === 1) {
                    $x++;
                }
                if ($value !== 1 && $value !== 0) {
                    $results_array[$x][] = $value;
                }
            }
            foreach ($results_array as $final_check) {
                if (check_conditions($final_check)) {
                    $found = true;
                    return $profile_name;
                    #break;
                }
            }
        }
        if ($found) {
            return $profile_name;
            # break;
        }
    }
    return 'default';
}
Exemple #4
0
    ?>
							</div>
						</div>
					</div>
<?php 
}
?>

<?php 
if (isset($data_sources->profiles) && count($data_sources->profiles) > 0) {
    ?>
					<div id="profiles" class="module">
						<h2 class="module-header"><span>Where You Can Find Me:</span></h2>
						<div class="module-content links">
							<?php 
    echo profile_list();
    ?>
						</div>
						<div class="clear"></div>
					</div>
<?php 
}
?>
					
				</div>
			</div>
			<div id="footer">
				<p>Powered by <a href="http://pez.bogdind.com/" title="Pez">Pez</a>.</p>
			</div>
		</div>
<?php