title: SQL Server change font in html string
body: <p>I have a strings stored in my database formatted as html, and users can change the font size.  That's fine, but I need to make a report and the font sizes all need to be the same.  So, if I have the following html, I want to modify it to have a font size of 10:</p>
  
  <pre><code>&lt;HTML&gt;&lt;BODY&gt;&lt;DIV STYLE="text-align:Left;font-family:Tahoma;font-style:normal;font-weight:normal;font-size:11;color:#000000;"&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;P&gt;&lt;SPAN&gt;This is my text to display.&lt;/SPAN&gt;&lt;/P&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/BODY&gt;&lt;/HTML&gt;
  </code></pre>
  
  <p>I have a user defined function, but apparently, I can't use wildcards in a REPLACE, so it doesn't actually do anything:</p>
  
  <pre><code>ALTER FUNCTION [dbo].[udf_SetFont]
  (@HTMLText VARCHAR(MAX))
  RETURNS VARCHAR(MAX)
  AS
  BEGIN
  RETURN REPLACE (@HTMLText, 'font-size:%;', 'font-size:10;')
  END
  </code></pre>
  
  <p>(Of course, it would be even better if I sent the font size as a parameter, so I could change it to whatever.)</p>
  
  <p>How do I modify this to change any string so the font size is 10?</p>