Forum Replies Created

Viewing 12 replies - 1 through 12 (of 12 total)
  • Thread Starter webarton

    (@webarton)

    ご回答ありがとうございました、拝見するのが遅くなり、失礼致しました。

    そうですよね、別に書くべきですよね・・・
    まだそこまで知識が至っていなくて、でもやってみます。
    ありがとうございます。

    Thread Starter webarton

    (@webarton)

    以下のようにやってみて、できました。

    もし、どなたかに見ていただいて、変なところがあったら
    ご指摘いただけたら嬉しいので、書きます。

    class.text.phpをコピーして、class.email.phpを作り、適宜変更。

    models/class.form.php の public function text( $name, $options = array() ) {} を複製して
    text → emailに変更。

    ただ、プラグインのアップデートの時は、class.form.phpの追加記述を、また書き直す必要がある。

    Thread Starter webarton

    (@webarton)

    上記のスレッドを参考にやってみようと思ったのですが、
    よくわからず、思うように進みませんでした。

    大変恐縮なのですが、もう少しヒントをいただけませんでしょうか。
    記述は、どのファイルに追記すればよいでしょうか。

    よろしくおねがいいたします。

    Thread Starter webarton

    (@webarton)

    こちらの質問と同じことをお聞きしていたとわかったので、
    私もやってみます。

    https://ww.wp.xz.cn/support/topic/html5-attributes?replies=3

    I’m also facing the same problem.
    The version is 0.9.3.2.

    Forum: Fixing WordPress
    In reply to: Hierarchy of pages
    Thread Starter webarton

    (@webarton)

    Thank you stvwlf, I’ll take a look at the link!

    Forum: Fixing WordPress
    In reply to: Hierarchy of pages
    Thread Starter webarton

    (@webarton)

    Thank a lot, stvwlf!

    I had actually tried to use categories, but I couldn’t choose the same name twice as child name.

    I mean, once I made “tokyo/movies/ginza” directory, I couldn’t make “kanagawa/movies/yokohama” directory because of “movies”. I could use “movies2” or something different with “movies”.

    That’s why I post my question…

    Forum: Fixing WordPress
    In reply to: Hierarchy of pages
    Thread Starter webarton

    (@webarton)

    Thank you stvwlf, I’m sorry if I’ve misunderstood what you kindly said, but categories seem to be provided only for posts.

    Making the web pages by posts is what I had been thinking but I couldn’t make the hierarchical structure(URL) as I preferred( http://www.webarton.com/custompost_en.gif ).

    Would you know if I could do the hierarchical structure by posts?

    Forum: Fixing WordPress
    In reply to: Hierarchy of pages
    Thread Starter webarton

    (@webarton)

    Thank you stvwlf!

    I should have build the pages as parent pages and child pages! I don’t know why I only thought of making it as post(single.php). Thank you!

    One concern is that pages(page.php) don’t seem to have tags, do they? There are some things I should categorize, so I thought tags would help that.

    Thread Starter webarton

    (@webarton)

    Hello, I could solve this and the code is below. LVP8 helped me a lot. Thank you!

    <?php
    /*
    Template Name: Category_Event
    */
    
    get_header(); ?>
    
    <div id="main">
    
    <?php
    $paged = (get_query_var('paged')) ? get_query_var('paged') : 1;
    $posts_per_page = (get_query_var('posts_per_page')) ? get_query_var('posts_per_page') : get_option('posts_per_page');
    $currentTime = date('Y-m-d H:i:s', time()+32400);
    query_posts(array(
    	'posts_per_page' => $posts_per_page,
    	'meta_key' => '_EventStartDate',
    	'meta_compare' => '<=',
    	'meta_value' => $currentTime,
    	'orderby' => 'meta_value',
    	'order' => 'DESC',
    	'paged' => $paged
    ));
    while ( have_posts() ) : the_post();
    ?>
    
    <?php echo get_post_meta($post->ID, '_EventStartDate', true); ?>
    <a href="<?php the_permalink(); ?>"><?php the_title(); ?></a>
    <?php echo get_the_post_thumbnail($post->ID, 'thumbnail'); ?>
    
    <?php endwhile; ?>
    </div>
    
    <?php
    if(function_exists('wp_pagenavi')) { wp_pagenavi(); }
    wp_reset_query();
    ?>
    <?php get_footer(); ?>
    Thread Starter webarton

    (@webarton)

    Hello, I could solve this and the code is below. LVP8 helped me a lot. Thank you!

    <?php
    /*
    Template Name: Category_Event
    */
    
    get_header(); ?>
    
    <div id="main">
    
    <?php
    $paged = (get_query_var('paged')) ? get_query_var('paged') : 1;
    $posts_per_page = (get_query_var('posts_per_page')) ? get_query_var('posts_per_page') : get_option('posts_per_page');
    $currentTime = date('Y-m-d H:i:s', time()+32400);
    query_posts(array(
    	'posts_per_page' => $posts_per_page,
    	'meta_key' => '_EventStartDate',
    	'meta_compare' => '<=',
    	'meta_value' => $currentTime,
    	'orderby' => 'meta_value',
    	'order' => 'DESC',
    	'paged' => $paged
    ));
    while ( have_posts() ) : the_post();
    ?>
    
    <?php echo get_post_meta($post->ID, '_EventStartDate', true); ?>
    <a href="<?php the_permalink(); ?>"><?php the_title(); ?></a>
    <?php echo get_the_post_thumbnail($post->ID, 'thumbnail'); ?>
    
    <?php endwhile; ?>
    </div>
    
    <?php
    if(function_exists('wp_pagenavi')) { wp_pagenavi(); }
    wp_reset_query();
    ?>
    <?php get_footer(); ?>
    Thread Starter webarton

    (@webarton)

    Hello, I could solve this and the code is below. LVP8 helped me a lot. Thank you!

    <?php
    /*
    Template Name: Category_Event
    */
    
    get_header(); ?>
    
    <div id="main">
    
    <?php
    $paged = (get_query_var('paged')) ? get_query_var('paged') : 1;
    $posts_per_page = (get_query_var('posts_per_page')) ? get_query_var('posts_per_page') : get_option('posts_per_page');
    $currentTime = date('Y-m-d H:i:s', time()+32400);
    query_posts(array(
    	'posts_per_page' => $posts_per_page,
    	'meta_key' => '_EventStartDate',
    	'meta_compare' => '<=',
    	'meta_value' => $currentTime,
    	'orderby' => 'meta_value',
    	'order' => 'DESC',
    	'paged' => $paged
    ));
    while ( have_posts() ) : the_post();
    ?>
    
    <?php echo get_post_meta($post->ID, '_EventStartDate', true); ?>
    <a href="<?php the_permalink(); ?>"><?php the_title(); ?></a>
    <?php echo get_the_post_thumbnail($post->ID, 'thumbnail'); ?>
    
    <?php endwhile; ?>
    </div>
    
    <?php
    if(function_exists('wp_pagenavi')) { wp_pagenavi(); }
    wp_reset_query();
    ?>
    <?php get_footer(); ?>
Viewing 12 replies - 1 through 12 (of 12 total)