# TRANSLATORS: Translate the values in quotes volatile.q_label = "Q"; # appears before questions as Q: volatile.a_label = "A"; # appears before answers as A: # NO TRANSLATION NEEDED BEYOND THIS POINT # KHP 18/Aug/2010 - added base_util, required by get_current_language() include "templates.util.base_util"; # docs_user_chapter_link() returns a link to an option documentation page in the user guide, given the shortcut or option name subroutine(docs_user_chapter_link(string chapter), ( expand(""); $("docs.user_guide.page_titles." . chapter); ""; )); # docs_user_chapter_link # start_docs_page() starts a documentation page with the specified title subroutine(start_docs_page(string title), ( # KHP 06/Sep/2010 - Set output language string user_node_name = node_name(volatile.authenticated_user_node_path); string current_language = get_current_language(user_node_name); set_language(current_language); # debug_message("#### start_docs_page() - user_node_name: " . user_node_name . "\n"); # debug_message("#### start_docs_page() - current_language: " . current_language . "\n"); volatile.docs_page_title = title; #debug_message("volatile.docs_page_title: " . volatile.docs_page_title . "\n"); docs.header; # '\n'; # " \n"; # expand(' \n'); # " \n"; # "
' . title . '
\n"; '

' . expand(title) . '

'; # '\n'; # " \n"; # " \n"; # " \n"; # "
\n"; # if (internal.docs.tab eq 'USER') and (internal.docs.index eq 'FALSE') then ( '
'; ''; '

'; ''; docs_user_chapter_link('index') . ''; docs_user_chapter_link('user_overview') . ''; docs_user_chapter_link('user_reports') . ''; docs_user_chapter_link('user_filters') . ''; docs_user_chapter_link('user_interpreting_reports') . ''; '

'; ) else ( '
'; ); )); subroutine(end_docs_page, ( # "
\n"; docs.footer; )); # docs_option_link() returns a link to an option documentation page, given the shortcut or option name subroutine(docs_option_link(string option), ( # Get the full node name for this option # echo("option: " . option); string fullOptionName; if (node_exists("default_profile." . option)) then fullOptionName = "default_profile." . option; # 2013-03-25 - GMF - Removed this, because if a node 'a' exists, it will break the docs search for 'a' as a shortcut link to command_line.action # else if (node_exists(option)) then ( # echo("FULL EXISTS"); # fullOptionName = option; # ); # 2011-09-26: If it's a subnode of log source, use the option path as the full option name (it's in "default" in default_profile, but not in lang_options). else if (matches_regular_expression(option, "^default_profile[.]log[.]source[.](.*)$")) then fullOptionName = option; else fullOptionName = get_node_name_from_shortcut(option); # echo("fullOptionName: " . fullOptionName); # Get the option name within the profile string optionNameForURL = fullOptionName; if (starts_with(fullOptionName, "default_profile.")) then optionNameForURL = "profile." . substr(optionNameForURL, length("default_profile.")); # Get the option label string label; if (optionNameForURL ne "") then label = $("lang_options." . optionNameForURL . ".label"); else label = "[unknown]"; string result = expand("$label"); result; )); # docs_option_link # remove_prefix() -- this removes a prefix p from string s subroutine(remove_prefix(string s, string p), ( if (starts_with(s, p)) then s = substr(s, length(p)); s; )); # docs_chapter_link() returns a link to an option documentation page, given the shortcut or option name subroutine(docs_chapter_link(string chapter), ( expand(""); $("docs.technical_manual.page_titles." . chapter); ""; )); # docs_chapter_link # docs_chapter_link_with_anchor() returns a link to an option documentation page, given the shortcut or option name subroutine(docs_chapter_link_with_anchor(string chapter, string anchor, string label), ( expand(""); label; ""; )); # docs_chapter_link_with_anchor # docs_function_link() returns a link to a Salang function subroutine(docs_function_link(string function), ( ""; "" . function . "()"; ""; )); # docs_function # docs_faq_link() returns a link to an FAQ entry, given the name subroutine(docs_faq_link(string name), ( expand(""); $("docs.faq.db." . name . ".label"); ""; )); # docs_faq_link # docs_user_faq_link() returns a link to an FAQ entry in the User FAQ, given the name subroutine(docs_user_faq_link(string name), ( expand(""); $("docs.user_faq.db." . name . ".label"); ""; )); # docs_user_faq_link # docs_faq_short_description() returns a short description of a FAQ entry subroutine(docs_faq_short_description(string name), ( # expand("$volatile.q_label: ") . $("docs.faq.db." . name . ".question") . "
\n"; string anchor_id = 'faq:' . name; string section_id = 'faq:' . name . ':div'; '
'; '' . $("docs.faq.db." . name . ".question") . '\n'; # expand("$volatile.a_label: ") . $("docs.faq.db." . name . ".short_answer") . "\n"; '
'; expand($("docs.faq.db." . name . ".short_answer")); '
'; "For full details, see " . docs_faq_link(name) . "
\n"; '
'; '
'; )); # docs_faq_short_description # docs_user_faq_short_description() returns a short description of a FAQ entry from the User FAQ subroutine(docs_user_faq_short_description(string name), ( expand("$volatile.q_label: ") . $("docs.user_faq.db." . name . ".question") . "
\n"; expand("$volatile.a_label: ") . $("docs.user_faq.db." . name . ".short_answer") . "\n"; "For full details, see " . docs_user_faq_link(name) . ".
\n"; "
\n"; )); # docs_user_faq_short_description # # KHP 28/02/2014 - Added subroutines to create menu and pre-sales info # subroutine(create_technical_manual_menu, ( node group; node groups = "docs.technical_manual.technical_manual_toc"; string group_name; string group_link_id; string group_list_id; node chapter; node chapters; string name; string label; string href; string link_id; ''; )); subroutine(create_faq_menu, ( node group; node groups = "docs.faq.faq_toc"; string name; string label; ''; )); subroutine(pre_sales_recommended_text, ( '

' . lang_admin.general.pre_sales_support_info . '

'; '

If you are considering $PRODUCT_NAME for a very large dataset (more than 200 million lines of data), it is recommended that you contact $PRODUCT_NAME technical support in advance, to get expert guidance with your profile configuration. There is no charge for pre-sales technical consultations, and it is very likely to improve your initial experience of $PRODUCT_NAME.

Contact support@sawmill.net for pre-sales support.

'; ));