SproutCMS

This is the code documentation for the SproutCMS project

source of /modules/Welcome/views/super_op_result.php

  1. <?php
  2. /*
  3.  * kate: tab-width 4; indent-width 4; space-indent on; word-wrap off; word-wrap-column 120;
  4.  * :tabSize=4:indentSize=4:noTabs=true:wrap=false:maxLineLen=120:mode=php:
  5.  *
  6.  * Copyright (C) 2016 Karmabunny Pty Ltd.
  7.  *
  8.  * This file is a part of SproutCMS.
  9.  *
  10.  * SproutCMS is free software: you can redistribute it and/or modify it under the terms
  11.  * of the GNU General Public License as published by the Free Software Foundation, either
  12.  * version 2 of the License, or (at your option) any later version.
  13.  *
  14.  * For more information, visit <http://getsproutcms.com>.
  15.  */
  16. use Sprout\Helpers\Enc;
  17.  
  18.  
  19. ?>
  20.  
  21.  
  22. <style>
  23. .login-box {
  24. max-width: 1200px;
  25. margin: 2em auto;
  26. padding-top: 0;
  27. }
  28. code {
  29. border: none;
  30. padding: 2px;
  31. background: #eee;
  32. }
  33. </style>
  34.  
  35.  
  36. <p>The authentication details for your super-operator account have been generated.</p>
  37.  
  38. <h3>A: First super-operator</h3>
  39. <ol>
  40. <li>Download the <a href="<?php echo Enc::html($superop_config_url); ?>">generated config file</a></li>
  41. <li>Save the file as <code><?php echo Enc::html(DOCROOT . 'config/super_ops.php'); ?></code></li>
  42. </ol>
  43.  
  44. <h3>B: Or if adding an extra super-operator</h3>
  45. <ol>
  46. <li>Update the file <code><?php echo Enc::html(DOCROOT . 'config/super_ops.php'); ?></code> adding the following:</li>
  47. </ol>
  48.  
  49. <?php
  50. echo "<pre>";
  51. foreach ($users as $username => $user) {
  52. echo " '", Enc::html(Enc::js($username));
  53. echo "' =&gt; ['uid' => {$user['uid']}, 'hash' =&gt; '", Enc::html(Enc::js($user['hash']));
  54. echo "', 'salt' =&gt; '", Enc::html(Enc::js($user['salt'])), "'],\n";
  55. }
  56. echo "</pre>";
  57. ?>
  58.  
  59. <p><a href="welcome/checklist" class="button">Back to checklist</a></p>
  60.