IndexController.php 675 B

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. <?php
  2. namespace app\controller;
  3. use support\Request;
  4. class IndexController
  5. {
  6. public function index(Request $request)
  7. {
  8. return <<<EOF
  9. <style>
  10. * {
  11. padding: 0;
  12. margin: 0;
  13. }
  14. iframe {
  15. border: none;
  16. overflow: scroll;
  17. }
  18. </style>
  19. <iframe
  20. src="https://www.workerman.net/wellcome"
  21. width="100%"
  22. height="100%"
  23. allow="clipboard-write"
  24. sandbox="allow-scripts allow-same-origin allow-popups"
  25. ></iframe>
  26. EOF;
  27. }
  28. public function view(Request $request)
  29. {
  30. return view('index/view', ['name' => 'webman']);
  31. }
  32. public function json(Request $request)
  33. {
  34. return json(['code' => 0, 'msg' => 'ok']);
  35. }
  36. }