当我尝试这个命令时,我得到了正确的道路
find /home/*/*/*/*.log
结果是
/home/blross23/karthi/mmw/sample.log
但是当我尝试这个命令时
find /home/*/*/*/*.log -mtime +1 -type f -size +2 -printf "%s %h%f\n"
我得到的结果是
7950 /home/blross23/karthi/mmwsample.log
在路径的尽头" /" (mmwsample.log )两个目录之间缺少
正确的路径是/..../mmw/sample.log 我得到的是/..../ mmwsample.log
命令???
中的错误是什么答案 0 :(得分:2)
在命令中指定格式:
<?php if ( have_posts() ) : while ( have_posts() ) : the_post();
$terms = get_terms( 'product_type' );
$image = get_field('product_type_tax_image');
$hero_image = $image['sizes']['medium'];
foreach ( $terms as $term ) {
// The $term is an object, so we don't need to specify the $taxonomy.
$term_link = get_term_link( $term );
// If there was an error, continue to the next term.
if ( is_wp_error( $term_link ) ) {
continue;
}
var_dump($hero_image);
// We successfully got a link. Print it out.
echo '<a href="' . esc_url( $term_link ) . '" class="product-grid- block" style="' . $hero_image[0] . '">';
echo '<div class="product-grid-inner-txt-wrap">';
echo '<h4>' . $term->name . '</h4>';
echo '<p>' . $term->description . '</p>';
echo '</div>';
echo '</a>';
}
?>
<?php endwhile; endif; ?>
<?php wp_reset_query(); ?>
您具体告诉它打印这两个值,它们之间没有'/'。要更正它,请尝试:
find /home/*/*/*/*.log -mtime +1 -type f -size +2 -printf "%s %h%f\n"