返回顶部

收藏

use puts to display text in a web page (It was printed out in the console.)

更多
<html>
  <head>
    <title>Using Views</title>
  </head>
  <body>
    <h1>Working With Views</h1>
    This is an active view in a Ruby on Rails application.
    <br>
    <br>
    2 + 3 = <%= 2 + 3 %>
    <br>
    <% puts 'Hi' %>
    <br>
    This page executes Ruby code on the fly.
  </body>
</html>

标签:Ruby,Rails

收藏

0人收藏

支持

0

反对

0

»更多 您可能感兴趣的代码
  1. 2016-04-23 18:50:43Link to an Action by 杨洋
  2. 2016-08-20 16:27:54Mix Ruby Code and HTML by digua
  3. 2016-10-13 09:29:34Read Data from a Checkbox by digua
  4. 2016-01-10 21:40:25Passing Data from an Action to a View by 胡晋
  5. 2016-08-20 16:38:38A loop executes the body of the loop by zetaliang
  6. 2016-08-20 16:54:59Escaping Sensitive Text by zetaliang
  7. 2016-10-10 09:35:27Initialize Data in an HTML Control by 永明
  8. 2016-08-20 17:12:28Tie a Text Field to a Model by JustForFly
  9. 2016-03-06 20:22:08Use cookie by digua
  10. 2016-03-21 10:38:51Call a Template File Directly by JustForFly
  11. 2016-08-20 17:33:13Creating a View by zetaliang

发表评论