如何路由* ngfor案例方法

时间:2019-04-20 17:02:02

标签: angular ngfor routerlink

我在路由器链接* ngFor方法上遇到编译错误

HTML

Menu:  string[] = ['Login', 'Data Table', 'Google Map', 'Input Form', 'Web View', 'Image Viewers', 'Video Viewers', 'Video Viewers',
   'PDF Viewers', 'Chat Vox' ];

Main.JS

Error
ERROR Error: Uncaught (in promise): Error: Cannot match any routes. URL Segment: 'mnu'
Error: Cannot match any routes. URL Segment: 'mnu'
    at ApplyRedirects.push../node_modules/@angular/router/fesm5/router.js.ApplyRedirects.noMatchError (router.js:2469)`enter code here`
    at CatchSubscriber.selector (router.js:2450)
<!DOCTYPE html>
<html lang="en" dir="ltr">
  <head>
    <meta charset="utf-8">
    <title>Sign In</title>
  </head>
  <body>
    <a href="?x=signin">Sign In</a><a href="?x=signup">Sign Up</a>
    <?php $x = $_GET['x']; if ($x == "signin"){ ?>
    <form class="" action="" method="post">
      <h1>Sign In</h1>
      <input type="text" name="" placeholder="username">
      <input type="text" name="" placeholder="password">
    </form>
  <?php } $x = $_GET['x']; if ($x == "signup"){?>
    <form class="" action="" method="post">
      <h1>Sign Up</h1>
      <input type="text" name="" placeholder="create username">
      <input type="text" name="" placeholder="create password">
    </form>
  <?php } ?>
  </body>
</html>

0 个答案:

没有答案