From 6d480a1bdf2e5374aaaa9a35575a9a81eb744a57 Mon Sep 17 00:00:00 2001 From: Jonathon Menz Date: Fri, 11 Mar 2016 10:47:21 -0800 Subject: [PATCH] Support front-end use --- code/TextTargetLengthExtension.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/code/TextTargetLengthExtension.php b/code/TextTargetLengthExtension.php index 3c8f295..9de9d35 100755 --- a/code/TextTargetLengthExtension.php +++ b/code/TextTargetLengthExtension.php @@ -35,6 +35,8 @@ public function setTargetLength($idealCharCount, $minCharCount = null, $maxCharC $field->setAttribute('data-target-ideal-length', $idealCharCount); $field->setAttribute('data-target-min-length', $minCharCount); $field->setAttribute('data-target-max-length', $maxCharCount); + Requirements::javascript(FRAMEWORK_DIR.'/thirdparty/jquery/jquery.js'); + Requirements::javascript(FRAMEWORK_DIR.'/thirdparty/jquery-entwine/dist/jquery.entwine-dist.js'); Requirements::javascript(TEXTTARGETLENGTH_DIR.'/javascript/text-target-length.js'); Requirements::css(TEXTTARGETLENGTH_DIR.'/css/text-target-length.css');