Hi guys,
I have a error in my app development. I am using the rss2json site to convert my code but returns the 'rssurl' parameter is missing.
And paste the following code
Rss.ts
export class RssProvider {
private API_URL: string;
constructor(public http: Http) {
this.API_URL = "https://api.rss2json.com/v1/api.json";
}
GetRSS() {
const params = { params: new HttpParams().set('rss_url', 'http://feeds.feedburner.com/Puthiyathalaimurai_Head_News').set('api_key', 'orpt2zbnecd3lo1sz1ahvfzypoqemcedsfy3awan')
}
return this.http.get(this.API_URL, params);
}
}
Home.ts
export class HomePage {
rssDataArray: any = ;
// Woocommerce: any;
constructor(public navCtrl: NavController, public navParams: NavParams, public rssProvider: RssProvider) {
}
ionViewDidLoad() {
console.log(‘ionViewDidLoad Menu’);
this.Get_RSS_Data();
}
Get_RSS_Data(){
this.rssProvider.GetRSS().subscribe(
data => {
this.rssDataArray = data;
console.log(data);
}
);
}
}