The ADC processor pipeline writes a JavaScript function to the body of each product detail page. When the page loads, this function invokes a Oracle RightNow client JavaScript function to create the knowledge base widget and place it in the page. The client function makes a call to the Oracle RightNow servers to search the knowledge base and return content for populating the widget.

The JavaScript function on the product detail page sets the widget parameters to the values specified in the /atg/adc/KnowledgeBaseProcessor component. For example:

<!--
dojo.ready(function(){
if (window.RightNow !== undefined){
 RightNow.Client.Controller.addComponent( {
div_id: "knowledgebase",
instance_id: "skw_0",
module: "KnowledgeSyndication",
type: 3,
number_answers: 5,
correction: true,
description: true,
ext_docs: false,
label_correction: "Did You Mean:",
label_documents: "Recommended Documents",
label_more_results: "More Results",
label_no_results: "No Results Found",
label_related_searches: "Other Suggested Searches:",
label_search_button: "Find",
q:"Find in KnowledgeBase?",
navigation: true,
payload_size: 150,
persist_prodcat:false,
preprocess: "pagescraper",
recommended: true,
related: false,
search_box: true,
target: "",
truncate_size: 100,
c: "",
context: ["title"],
p: ""
}, "http://oracleatg.rightnowdemo.com/ci/ws/get"
);
RightNow.Client.Controller.startFetching();
if(dojo.byId("showKnowledgebaseLink")){
dojo.removeClass("showKnowledgebaseLink", "hideKnowledgebase");
}
  if (RightNow && RightNow.Client && RightNow.Client.Event &&
  RightNow.Client.Event.evt_searchResponse){
 RightNow.Client.Event.evt_searchResponse.subscribe(atg.store.rightNow.decorateLinksWhenReady, this);
}
}
});
if (window.addEventListener){
addEventListener('message', atg.store.rightNow.postMessageListener, false)
}
else {
attachEvent('onmessage', atg.store.rightNow.postMessageListener)
}//-->

Copyright © 1997, 2013 Oracle and/or its affiliates. All rights reserved. Legal Notices