This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public static class Submit | |
| { | |
| [FunctionName("Submit")] | |
| public static async Task<IActionResult> Run( | |
| [HttpTrigger(AuthorizationLevel.Function, "get", "post", Route = null)] HttpRequest req, | |
| ILogger log) | |
| { | |
| // Getting Form Data items from Request | |
| var from = req.Form["fromEmail"].ToString(); | |
| var fromName = req.Form["fromName"].ToString(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import { HttpRequest, HttpHandler, HttpEvent, HttpInterceptor } from '@angular/common/http'; | |
| import { Injectable } from '@angular/core'; | |
| import { Observable } from 'rxjs/Observable'; | |
| @Injectable() | |
| export class JWTInterceptor implements HttpInterceptor { | |
| intercept(req: HttpRequest<any>, next: HttpHandler): Observable<HttpEvent<any>> { | |
| if (req.method === 'DELETE' || req.method === 'POST' || req.method === 'PUT') { | |
| let currentUser = JSON.parse(localStorage.getItem('currentUser')); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| | |
| public static class RedditPoller | |
| { | |
| [FunctionName("TimerTriggerCSharp")] | |
| public static void Run([TimerTrigger("0 */1 * * * *")]TimerInfo myTimer, TraceWriter log) | |
| { | |
| string url = "https://www.reddit.com/r/azure/new/.json"; | |
| List<Child> children = new List<Child>(); | |
| WebClient client = new WebClient(); |
NewerOlder