Skip to content

Releases: rotexsoft/file-renderer

Updated dev dependencies

21 Feb 20:48
Compare
Choose a tag to compare

No user impacting changes

Minor Tweak

07 Feb 00:25
Compare
Choose a tag to compare

Minor Tweak

Added hasPath

21 Sep 21:17
Compare
Choose a tag to compare

Added hasPath

Exception specificity

03 May 22:23
Compare
Choose a tag to compare

Changed exception thrown by __get from \Exception to \OutOfBoundsException.

Bug Fix.

26 Apr 21:05
Compare
Choose a tag to compare

Tweaked renderToString to truly make the five escaper methods available via $this->escape($string)* inside view files.

Added 5 escaper methods for manual escaping

25 Apr 18:58
Compare
Choose a tag to compare

Added 5 escaper methods to the Renderer Class:

  • $this->escapeHtml(string $some_string_variable): an alias for PHP's htmlspecialchars() for escaping data which may contain html markup.
  • $this->escapeHtmlAttr(string $some_string_variable): for escaping data which is meant to be rendered as an attribute value within an html element in a view.
  • $this->escapeCss(string $some_string_variable): for escaping data which is meant to be rendered within <style> tags or inside the style attribute of any html element.
  • $this->escapeJs(string $some_string_variable): for escaping data which is meant to be rendered as string literals or digits within Javascript code in a view.
  • $this->escapeUrl(string $some_string_variable): an alias for PHP's rawurlencode() for escaping data being inserted into a URL and not to the whole URL itself.

These methods can be called directly within views.

Also added __toString() which calls renderToString with no args.

Changed the visibility of Renderer::multi_escape_prevention_guard from public to protected.

23 Apr 00:42
Compare
Choose a tag to compare

Changed the visibility of Renderer::multi_escape_prevention_guard from public to protected.

Optimizations and Completed Documentation

22 Apr 21:36
Compare
Choose a tag to compare
  • Optimized escapeData
  • Improved API documentation in Renderer.php
  • README.md Documentation is now complete
  • Updated removeFirstNPaths and removeLastNPaths to return an array of the removed items.

Fixed warning message that occurs in escapeData if an empty data array is passed.

22 Apr 17:01
Compare
Choose a tag to compare
  • Fixed warning message that occurs in escapeData if an empty data array is passed.

Wild card operator for Escape Specification

22 Apr 16:57
Compare
Choose a tag to compare
  • Added ability to specify escaping on all fields using a wild card string.
  • Fixed warning message that occurs in escapeData if an empty data array is passed.