diff Lib/IMPL/Web/Application/Action.pm @ 320:28eba7e0c592

*web application action: added method to access HTTP request header.
author sergey
date Thu, 16 May 2013 17:16:41 +0400
parents 4abda21186cd
children 3dc9260017ad
line wrap: on
line diff
--- a/Lib/IMPL/Web/Application/Action.pm	Wed May 15 02:00:42 2013 +0400
+++ b/Lib/IMPL/Web/Application/Action.pm	Thu May 16 17:16:41 2013 +0400
@@ -31,6 +31,16 @@
     $this->_launder(scalar( $this->query->cookie($name) ), $rx );
 }
 
+sub header {
+	my ($this,$header) = @_;
+	
+	$this->query->https ? $this->query->https($header) : $this->query->http($header);
+}
+
+sub isSecure {
+	shift->query->https ? 1 : 0;
+}
+
 sub param {
     my ($this,$name,$rx) = @_;