You can convert easily your .po
(WordPress translation files) to .mo
once
just go to > http://tools.konstruktors.com/
upload your .po
file and download the converted .mo
<?php | |
$link = mysql_connect('localhost', 'root', 'password'); | |
if (!$link) { | |
die('Could not connect: ' . mysql_error()); | |
} | |
echo 'Connected!'; | |
mysql_close($link); | |
?> | |
<?php // define ?> | |
<?php $thumb_id = get_post_thumbnail_id(); $thumb_url = wp_get_attachment_image_src($thumb_id,'steecky', true);?> | |
<?php // get ?> | |
<?php echo $thumb_url[0]; ?> |
<ul> | |
<?php | |
$store_id = Mage::app()->getStore()->getId(); | |
$_productCollection = Mage::getResourceModel('reports/product_collection') | |
->addStoreFilter($store_id) | |
->addAttributeToFilter('visibility', 4) | |
->addAttributeToFilter('status', 1) | |
->addAttributeToSelect('*') | |
->setVisibility(array(2,3,4)) | |
->setOrder('created_at', 'desc') |
<?php | |
// Change default e-mail address and name on outgoing e-mails sent by WordPress. | |
// code goes in your theme functions.php | |
// New Email | |
function sb_new_mail_from( $email ) { | |
$email = 'info@yoursite.com'; // change | |
return $email; | |
} | |
add_filter( 'wp_mail_from', 'sb_new_mail_from' ); |
<?php | |
/* | |
+ If you need to include a file only for lets say, Italian stores, you can use the code below: | |
+ You can change it_IT with; | |
- de_DE // German | |
- fr_FR // French | |
- bg_BG // Bulgarian | |
- es_ES // Spanish | |
- en_US // USA English |
<?php // Displaying post from this week! | |
$week = date('W'); | |
$year = date('Y'); | |
$args=array( | |
'w'=> $week, | |
'year'=> $year, | |
'post_type' => 'post', | |
'post_status' => 'publish', | |
'posts_per_page' => -1, | |
'caller_get_posts'=> 1 |
<?php | |
$current_date = time(); | |
$start_date = strtotime('2014-05-05 00:00:00'); // year-month-day hours:minutes:seconds | |
$end_date = strtotime('2014-05-06 00:00:00'); // year-month-day hours:minutes:seconds | |
if($current_date > $start_date && $current_date < $end_date){ | |
// show the content you need in between these two dates | |
} else { | |
// show something else | |
} |
You can convert easily your .po
(WordPress translation files) to .mo
once
just go to > http://tools.konstruktors.com/
upload your .po
file and download the converted .mo
<?php | |
// path to directory | |
$directory = "../images/harry/legs/"; | |
// get all image files with a .jpg extension. | |
$images = glob($directory . "*.jpg"); | |
// print each file name | |
foreach($images as $image) { | |
echo $image; |
! function(a, b, c) { | |
var d = a[c.k] = { | |
w: a, | |
d: b, | |
a: c, | |
s: {}, | |
f: function() { | |
return { | |
callback: [], | |
get: function(a, b) { |