JS & Code in Wordpress

Out of context: Reply #17

  • Started
  • Last post
  • 21 Responses
  • cherub0

    So here is my formbox that I have hosted on a simple html site, this part will look mundane to most of you, but it was new to me, and not easy to figure out. But this is where the user puts in the entry code.

    Probably QBN will truncate it, so I also include link to pasted code.

    http://controlc.com/e8da40d7

    <div id="admission">
    <H1 style="color: white;">LOGIN</H1>
    <form action="checkuser.php" method="post">
    <input id="t-input" type="text" name="user id" pattern="[a-zA-Z0-9]+" maxlength="4" placeholder="type user id here" required>
    <input id="t-input" type="text" name="entrycode" pattern="[a-zA-Z0-9]+" placeholder="Entry Code" required>
    <input type="submit">
    </div>

    • you don't just call a php script like that in an MVC, in wordpress you write that php part into the theme/child theme function.php file.sted
    • https://wordpress.st…
      here is an example with js
      sted
    • please spend some time and read the basics:
      https://make.wordpre…
      sted
    • I'm just trying to get it working as straight html/php on my mirror site for now... I think wordpress will be too hard for me.cherub
    • "you don't just call a php script like that in an MVC," I'm using the PHP snippets plugin, which I assume writes it to your functions.phpcherub

View thread