Search box widget

Version 1

    This code can be used in an HTML widget to create a multiple check search box based on tags used within one place.  Our users can click on the product at the top and then filter by collateral type below.

     

    Image-0110.jpg

     

    <script src="//ajax.googleapis.com/ajax/libs/jquery/1.10.1/jquery.min.js"></script>

    <script type="text/javascript">

    setTimeout(resizeMe, 2000);

    resizeMe();

    var thisID;

    // fix height

    if(parent){

          //parent.document.getElementById('widgetIframe279499').height = (document.body.scrollHeight) + "px";

          parent.$j("iframe").each(function(iel, el) {

                if(el.contentWindow === window){

                      // console.log("got it");

                      thisID = el.contentWindow.name;

                      // console.log (thisID);

                      // console.log(el.contentWindow.name);

                      parent.$j("#" + thisID).css('height','1600px');

                      // console.log (parent.document.getElementById(thisID).height);

                }

          });

    }

     

     

    function submitSearch() {

      var search_href = "/community/sales-portal/healthcare-sales/diagnostics/content?filterID=contentstatus%5Bpublished%5D~tag%5B";

      var tag_count = 0;

      $("#nuancesearchform :checked").each(function() {

        if (tag_count > 0) {

          search_href += "%7C";

        }

              search_href += $(this).val();

        tag_count++;

      });

          search_href += "%5D";

      parent.location.href=search_href;

    }

    </script>

     

     

    <form name="nuancesearchform" id="nuancesearchform">

    <div style="font-family: arial; font-weight: bold; font-size: 14px;">Product</div>

    <div style="font-family: arial; font-size: 13px;"><input type="checkbox" value="ps360_analytics"/>PS360 Analytics</div>

    <div style="font-family: arial; font-size: 13px;"><input type="checkbox" value="ps360_criticalresults"/>PS360 Critical Results</div>

    <div style="font-family: arial; font-size: 13px;"><input type="checkbox" value="ps360_reporting"/>PS360 Reporting</div>

    <div style="font-family: arial; font-size: 13px;"><input type="checkbox" value="ps360_mobile"/>PS360 Mobile Radiologist</div>

    <div style="font-family: arial; font-size: 13px;"><input type="checkbox" value="powerscribe"/>PS 4.X/5.0</div>

    <div style="font-family: arial; font-size: 13px;"><input type="checkbox" value="radwhere"/>RadWhere</div>

    <div style="font-family: arial; font-weight: bold; font-size: 14px; margin-top: 20px;">Collateral Type</div>

    <div style="font-family: arial; font-size: 13px;"><input type="checkbox" value="branding"/>Branding</div>

    <div style="font-family: arial; font-size: 13px;"><input type="checkbox" value="brochure"/>Brochures</div>

    <div style="font-family: arial; font-size: 13px;"><input type="checkbox" value="case_study"/>Case Studies</div>

    <div style="font-family: arial; font-size: 13px;"><input type="checkbox" value="competitive_intelligence"/>Competitive Intelligence</div>

    <div style="font-family: arial; font-size: 13px;"><input type="checkbox" value="demo"/>Demo Scripts & Set-up</div>

    <div style="font-family: arial; font-size: 13px;"><input type="checkbox" value="discovery"/>Discovery</div>

    <div style="font-family: arial; font-size: 13px;"><input type="checkbox" value="faq"/>FAQ</div>

    <div style="font-family: arial; font-size: 13px;"><input type="checkbox" value="trend"/>Issue/ Trend Coverage</div>

    <div style="font-family: arial; font-size: 13px;"><input type="checkbox" value="qrc"/>Quick Reference Card</div>

    <div style="font-family: arial; font-size: 13px;"><input type="checkbox" value="Positioning"/>Positioning</div>

    <div style="font-family: arial; font-size: 13px;"><input type="checkbox" value="presentation"/>Presentations</div>

    <div style="font-family: arial; font-size: 13px;"><input type="checkbox" value="documentation"/>Product Documentation</div>

    <div style="font-family: arial; font-size: 13px;"><input type="checkbox" value="pricing"/>Pricing</div>

    <div style="font-family: arial; font-size: 13px;"><input type="checkbox" value="product_guide"/>Product Guide</div>

    <div style="font-family: arial; font-size: 13px;"><input type="checkbox" value="product_sheet"/>Product Sheet</div>

    <div style="font-family: arial; font-size: 13px;"><input type="checkbox" value="promotions"/>Promotions</div>

    <div style="font-family: arial; font-size: 13px;"><input type="checkbox" value="roi_tool"/>ROI Tools</div>

    <div style="font-family: arial; font-size: 13px;"><input type="checkbox" value="training"/>Training</div>

    <div style="font-family: arial; font-size: 13px;"><input type="checkbox" value="webinar"/>Webinars</div>

    <div style="font-family: arial; font-size: 13px;"><input type="checkbox" value="white_paper"/>White Papers</div>

    <div style="font-family: arial; font-weight: bold; font-size: 14px; margin-top: 20px;"><input type="button" value="Click to search" onclick="submitSearch();"/></div>

    <br />

    </form>