You are here

public static function RocketChat::renderHelpPage in Rocket.Chat 7.2

Same name and namespace in other branches
  1. 7 RocketChat.class.inc \RocketChat\RocketChat::renderHelpPage()

Implements hook_help().

Parameters

$path: Path to render on.

$arg: Arguments in this path

Return value

string

See also

\hook_help()

1 call to RocketChat::renderHelpPage()
rocket_chat_help in ./rocket_chat.module
Implements hook_help().

File

src/RocketChat.class.inc, line 122

Class

RocketChat
Class RocketChat.

Namespace

RocketChat

Code

public static function renderHelpPage(&$path, &$arg) {
  $arguments = $arg;
  $output = array();
  $extensions = array();
  switch ($path) {
    case 'admin/config/services/rocket_chat':

      //        $output[] = <<<settingsPageHelp

      //Here you set the Settings for the Rocket.Chat module.<br>

      //<ul>

      //  <li>In the <mark>Rocket.Chat Server</mark> setting you put the base Rocket.Chat url you use to contact the Rocket,chat server.</li>
      //  <li>In the <mark>Paths to show the chat widget on</mark>. you put the drupal url's to show the widget on. With the following Special cases:
      //    <ul>
      //      <li>Leave the Textfield empty, this will make the widget show on all pages.</li>
      //      <li>use the special '<front>' to specify the front page, so the widget is shown on the front page.</li>
      //      <li>use a '*' at the end of an URL to signify all Url's below a certain path. like 'node/*' to make the widget shown on all nodes.</li>
      //    </ul>
      //  </li>

      //</ul>

      //settingsPageHelp;
      break;
    case 'admin/help#rocket_chat':
      $output[] = <<<helpPage
<h1 id="_rocket-chat_-module-for-drupal-7-"><em>Rocket.Chat</em> Module for Drupal 7.</h1>
<h2 id="introduction">INTRODUCTION</h2>
<p>The Rocket.Chat Module enables a drupal site to integrate Rocket.Chat.<br>it is currently in its <strong><em>7.x-1.0</em></strong> release.
The following Features of rocket chat are imiplemented. </p>
<ul>
<li>A page with the <a href="@rocketchat-livechat">Livechat</a> widget.
This widget offer you the ability to communicate with
your website &#39;guests&#39;.</li>
</ul>
<h2 id="requirements">Requirements</h2>
<p>This module is designed for:</p>
<ul>
<li><a href="@drupal">Drupal 7</a></li>
<li><a href="@rocketchat">Rocket.Chat</a></li>
</ul>
<p>It needs the following Rocket.Chat modules enabled and configured.</p>
<ul>
<li>Livechat</li>
</ul>
<h2 id="recommendations">Recommendations</h2>
<p>To use Rocket.Chat on the internet use a TLS (HTTPS) connection. See
<a href="@drupalHttps">Drupal Documentation HTTPS</a> and <a
href="rockechatHttps">Rocket.Chat Documentation HTTPS</a>
Respectively for instructions on the how.<br>
HTTP setups are not recommended and not supported by the maintainers.
For how to use Livechat see the <a href="@rocketchatLivechatDocs">Rocket.Chat Livechat Documentations</a>
<h2 id="installation">Installation</h2>
<ul>
<li>Go to
<a href="@rocketchatConfig">[web-site-url]/admin/config/services/rocket_chat</a>
 and fill the config form,</li>
<li>Visit [web-site-url]/[path-chosen] then the widget will appear </li>
<li>If its not there Clear the caches and reload the page, the widget should now
 appear.</li>
</ul>
<h2 id="configuration">Configuration</h2>
<p>in the Configuration of the module (located under the &#39;Web services&#39; in the
configuration tab.)<br>
  you set the address of the Rocket.Chat server and the Patch on the drupal where
  the widget is enabled.</p>
<h2 id="troubleshooting">Troubleshooting</h2>
<p>Leave a detailed report of your issue in the
<a href="@drupal-issue">issue queue</a> and one of the maintainers will add it
to the task list.</p>
<h2 id="maintainers">Maintainers</h2>
<ul>
<li><a href="@sysosmaster">Sysosmaster</a> (Original Module creator)</li>
<li><a href="@idevit">idevit</a> (Community Plumbing)</li>
<li><a href="@gabriel">Gabriel Engel</a> (Creator Rocket.Chat)</li>
</ul>
helpPage;
      $extensions['@drupal'] = 'https://www.drupal.org/project/drupal';
      $extensions['@drupal-issue'] = 'https://www.drupal.org/project/issues/' . 'search/2649818';
      $extensions['@drupalHttps'] = 'https://www.drupal.org/https-information';
      $extensions['@rocketHttps'] = 'https://rocket.chat/docs/installation/' . 'manual-installation/configuring-ssl-reverse-proxy';
      $extensions['@rocketchat'] = 'https://rocket.chat';
      $extensions['@rocketchat-livechat'] = 'https://rocket.chat/docs/' . 'administrator-guides/livechat';
      $extensions['@rocketchatLivechatDocs'] = 'https://rocket.chat/docs/' . 'administrator-guides/livechat';
      $extensions['@rocketchatConfig'] = '/admin/config/services/rocket_chat';
      $extensions['@gabriel'] = 'https://www.drupal.org/u/gabriel-engel';
      $extensions['@idevit'] = 'https://www.drupal.org/u/idevit';
      $extensions['@sysosmaster'] = 'https://www.drupal.org/u/sysosmaster';
      break;
  }
  $ret = "";
  foreach ($output as $line) {
    $ret .= '<p>' . t($line, $extensions) . '</p>';
  }
  return $ret;
}