我已經在routing 設定
{ path: ‘ivp/:id’, component: IpvComponent}
在TS有接到值
該如何傳到PHP?
public id:any=[];
this.id = this.route.snapshot.paramMap.get(‘id’);
this.id=JSON.stringify(this.id);
this.http.post(‘http://localhost:8088/php/123.php’, this.id, { responseType: ‘text’}).subscribe(id=> {
console.log(this.id);
})
謝謝