Extent default Wikipedia-widget styles to apply to the mkws-wikipedia
[mkws-moved-to-github.git] / examples / htdocs / mkws-widget-ru.readme
index c55272e..4dc8c4b 100644 (file)
@@ -4,26 +4,29 @@
 Simply paste this inline with the markup on any page: 
 
     <script src="//mkws.indexdata.com/mkws-complete.js"></script>
-    <script src="//mkws.indexdata.com/mkws-widget-ru.js"></script>
+    <script>var mkws_config = { sp_auth_credentials: "paratext/paratext_mkc" }</script>
     <link rel="stylesheet" type="text/css" href="//mkws.indexdata.com/mkws-widget-ru.css" />
-    <div class="mkwsReferenceUniverse" autosearch="!param!q"></div>
+    <div class="mkws-reference-universe" autosearch="!param!q"></div>
     
 ## A bit more detail 
 
 The MasterKey Widget Set ([MKWS](http://mkws.indexdata.com/)) lets you easily embed search-enabled widgets which run in the client browser and display results from a web service. In this case, it searches Reference Universe.
 
-You need to include two scripts: one for MKWS and one for the Reference Universe widget. This can be inline as above or you can include them in the header or aggregate them with your application's scripts.
+You need to include the main MKWS scripts. This can be inline as above or you can include it in the header or aggregate it with your application's scripts.
 
     <script src="//mkws.indexdata.com/mkws-complete.js"></script>
-    <script src="//mkws.indexdata.com/mkws-widget-ru.js"></script>
     
+You also need to tell the widget how to authenticate onto the searching service:
+
+    <script>var mkws_config = { sp_auth_credentials: "paratext/paratext_mkc" }</script>
+
 The provided stylesheet is generic and you're encouraged to replace it entirely by styling the new elements to fit seamlessly with your content. 
 
     <link rel="stylesheet" type="text/css" href="//mkws.indexdata.com/mkws-widget-ru.css" />
     
-Any element you give the class `mkwsReferenceUniverse` will have is contents replaced by the top results from a search against the Reference Universe service for the current query.
+Any element you give the class `mkws-reference-universe` will have is contents replaced by the top results from a search against the Reference Universe service for the current query.
     
-    <div class="mkwsReferenceUniverse" autosearch="!param!q"></div>
+    <div class="mkws-reference-universe" autosearch="!param!q"></div>
 
 ### Finding the query