SproutCMS

This is the code documentation for the SproutCMS project

source of /sprout/views/admin/main_seo.php

  1. <?php
  2. use Sprout\Helpers\Enc;
  3. ?>
  4.  
  5. <div id="seo-wrapper" class="page-edit-tab">
  6. <div class="heading-with-buttons">
  7. <button class="button button-small button-grey icon-close icon-after page-edit-tab-close" type="button" data-target="seo-wrapper">Close</button>
  8. <h3 class="h2 icon-before icon-search">SEO</h3>
  9. </div>
  10.  
  11. <div class="white-box">
  12.  
  13. <?php if (!empty($disabled)): ?>
  14. <ul class="messages"><li class="neutral">SEO analysis can't be determined from content.</li></ul>
  15. </div></div>
  16. <?php return; ?>
  17. <?php endif; ?>
  18.  
  19. <?php if (!empty($keywords) and count($keywords) > 0): ?>
  20. <h2 class="icon icon-before icon-equalizer">Keyword density</h2>
  21.  
  22. <div class="seo-keywords">
  23. <p>
  24. <?php foreach ($keywords as $word => $count): ?>
  25. <button class="button button-small button-grey" type="button"><?php echo Enc::html($word); ?> <sup><?php echo Enc::html($count); ?></sup></button>
  26. <?php endforeach; ?>
  27. </p>
  28. </div>
  29. <?php endif; ?>
  30.  
  31. <h2 class="icon icon-before icon-view_list">Analysis</h2>
  32.  
  33. <div class="seo-analysis">
  34. <?php if (!empty($seo_problems) and count($seo_problems) > 0): ?>
  35. <h4>Problems (<?php echo Enc::html(count($seo_problems)) ?>)</h4>
  36. <ul class="messages">
  37. <?php foreach ($seo_problems as $item): ?>
  38. <li class="error"><?php echo $item; ?></li>
  39. <?php endforeach; ?>
  40. </ul>
  41. <?php endif; ?>
  42.  
  43. <?php if (!empty($seo_improvements) and count($seo_improvements) > 0): ?>
  44. <h4>Improvements (<?php echo Enc::html(count($seo_improvements)) ?>)</h4>
  45. <ul class="messages">
  46. <?php foreach ($seo_improvements as $item): ?>
  47. <li class="neutral"><?php echo $item; ?></li>
  48. <?php endforeach; ?>
  49. </ul>
  50. <?php endif; ?>
  51.  
  52. <?php if (!empty($seo_considerations) and count($seo_considerations) > 0): ?>
  53. <h4>Considerations (<?php echo Enc::html(count($seo_considerations)) ?>)</h4>
  54. <ul class="messages">
  55. <?php foreach ($seo_considerations as $item): ?>
  56. <li class="neutral neutral-grey"><?php echo $item; ?></li>
  57. <?php endforeach; ?>
  58. </ul>
  59. <?php endif; ?>
  60.  
  61. <?php if (!empty($seo_goodresults) and count($seo_goodresults) > 0): ?>
  62. <h4>Good results (<?php echo Enc::html(count($seo_goodresults)) ?>)</h4>
  63. <ul class="messages">
  64. <?php foreach ($seo_goodresults as $item): ?>
  65. <li class="confirm"><?php echo $item; ?></li>
  66. <?php endforeach; ?>
  67. </ul>
  68. <?php endif; ?>
  69. </div>
  70.  
  71. </div>
  72. </div>
  73.