Adding php to form action breaks code

Closed. This question is off-topic. It is not currently accepting answers.Questions that are too localized (such as synt

Closed. This question is off-topic. It is not currently accepting answers.

Questions that are too localized (such as syntax errors, code with restricted access, hacked sites, hosting or support issues) are not in scope. See how do I ask a good question?

Closed 5 years ago.

Improve this question

I have a form that is a button to link to a product but for some reason when I add php to the form action it's breaking the block of code. I'm not sure what I am missing. It's a very simple block and I've checked and double checked everything above it and it's all working perfectly until I get to this piece.

Here is the block that is breaking

<form action="<?php echo get_permalink( get_option( 'pctg_wc_meal_choice_page') ); ?>" method="post">
        <input type="hidden" name="meal_plan" value="<?php echo $product->id; ?>" />
        <button type="submit" id="btn_load" class="btn btn-secondary" data-loaing-text="Loading...">Get Started</button>
      </form>

Right it's not recognizing that I've closed the " so the rest of the block of code doesn't work.

Closed. This question is off-topic. It is not currently accepting answers.

Questions that are too localized (such as syntax errors, code with restricted access, hacked sites, hosting or support issues) are not in scope. See how do I ask a good question?

Closed 5 years ago.

Improve this question

I have a form that is a button to link to a product but for some reason when I add php to the form action it's breaking the block of code. I'm not sure what I am missing. It's a very simple block and I've checked and double checked everything above it and it's all working perfectly until I get to this piece.

Here is the block that is breaking

<form action="<?php echo get_permalink( get_option( 'pctg_wc_meal_choice_page') ); ?>" method="post">
        <input type="hidden" name="meal_plan" value="<?php echo $product->id; ?>" />
        <button type="submit" id="btn_load" class="btn btn-secondary" data-loaing-text="Loading...">Get Started</button>
      </form>

Right it's not recognizing that I've closed the " so the rest of the block of code doesn't work.

Share Improve this question asked Jun 5, 2019 at 14:46 kemmiegkemmieg 313 bronze badges 1
  • Breaking how? What does the generated HTML look like on the page? – Rup Commented Jun 5, 2019 at 14:51
Add a comment  | 

1 Answer 1

Reset to default 1

Disregard the entire question. I've found my answer. I was missing a closing tag on the wrapping div. Go figure.

发布者:admin,转转请注明出处:http://www.yc00.com/questions/1745435600a4627593.html

相关推荐

  • Adding php to form action breaks code

    Closed. This question is off-topic. It is not currently accepting answers.Questions that are too localized (such as synt

    12小时前
    20

发表回复

评论列表(0条)

  • 暂无评论

联系我们

400-800-8888

在线咨询: QQ交谈

邮件:admin@example.com

工作时间:周一至周五,9:30-18:30,节假日休息

关注微信