private void PerformReplacements() { var output = _writer.ToString(); //do replacements var replaced = DependencyRenderer.GetInstance(_httpContext).ParseHtmlPlaceholders(output); //write to original _originalWriter.Write(replaced); }
/// <summary> /// Updates the html js/css templates rendered temporarily by the controls into real js/css html tags. /// </summary> /// <param name="html"></param> /// <returns></returns> /// <remarks> /// This will also validate whether the rogue script handler should run and if so does. /// </remarks> public string UpdateOutputHtml(string html) { //first we need to check if this is MVC! if (CurrentContext.CurrentHandler is MvcHandler) { //parse the html output with the renderer var r = DependencyRenderer.GetInstance(CurrentContext); if (r != null) { var output = r.ParseHtmlPlaceholders(html); //get the rogue filter going if (_rogueFileFilter.CanExecute()) { output = _rogueFileFilter.UpdateOutputHtml(output); } return(output); } } return(html); }