Formatting and submitting comments in WordPress

0

I have two sections on my site, one shows the comments and the other is a form for comments:

Section sec-aval - Show comment

  <section id="sec-aval">
     <aside class="sec-aval-asd first">
        <h1>Título do comentário</h1>
        <span class="autor">Autor do comentário</span>
        <p>Comentário</p>
     </aside>
  </section>

Section "sec-contact" - Get the comment

  <section id="sec-contato">
     <h1>Contato</h1>
     <p>Deixe sua mensagem, sugestão ou crítica</p>
     <form action="">
        <input type="text" placeholder="Seu nome">
        <input type="text" placeholder="Título da mensagem">
        <textarea cols="0" rows="0">Sua mensagem...</textarea>
        <button type="submit">Enviar</button>
     </form>
  </section>

How to make this system using the php functions of WordPress? Note: I need section sec-aval to show only the last three comments.

    
asked by anonymous 10.03.2014 / 14:49

1 answer

1

Read the WordPress Codex on the following functions:

A good code example can be taken from the Twenty Fourteen default theme: Listing Comments and adding comment_form .

    
21.03.2014 / 19:26