+ Reply to Thread
Results 1 to 5 of 5

Thread: Basic Ruby Question

  1. #1
    jasgor9's Avatar
    jasgor9 is offline x10Hosting Member jasgor9 is an unknown quantity at this point
    Join Date
    Nov 2007
    Posts
    40

    Question Basic Ruby Question

    I am learning Ruby and can't figure out this: does ruby have opening/closing tags like PHP (<?php ?>) and ASP (<% %>) ? I tried making a Ruby page with this code:

    HTML Code:
    puts "Hello, World"
    ...but when i viewed the page it just said 'puts "Hello World"' If there aren't tags, then how can i fix this?

  2. #2
    konekt's Avatar
    konekt is offline x10 Sophmore konekt is an unknown quantity at this point
    Join Date
    Mar 2008
    Posts
    100

    Re: Basic Ruby Question

    You should not need anything supplemental to code Ruby. I would make sure it is properly installed on the server.

  3. #3
    cybergig is offline x10Hosting Member cybergig is an unknown quantity at this point
    Join Date
    Mar 2008
    Posts
    28

    Re: Basic Ruby Question

    From what I am told you need absolute server, which is an adfree server.

  4. #4
    phazzedout's Avatar
    phazzedout is offline x10 Sophmore phazzedout is an unknown quantity at this point
    Join Date
    Dec 2009
    Location
    CA, United States
    Posts
    230

    Re: Basic Ruby Question

    Code:
    puts "Hello World!"
    You do not need any code to close it. Also in order to view it on a web browser you need to configure Ruby on Rails & Ruby Gems not just regular Ruby. I do not think x10hosting has Ruby on Rails or Ruby Gems. I know a couple of hosts, that are not as good as this one but do have Ruby on Rails.
    "Words convey the mental treasures of one period to the generations that follow; and laden with this, their precious freight, they sail safely across gulfs of time in which empires have suffered shipwreck and the languages of common life have sunk into oblivion." - Anonymous

  5. #5
    misson is offline x10 Spammer misson is a jewel in the rough
    Join Date
    Mar 2008
    Location
    Libertatia
    Posts
    2,506

    Re: Basic Ruby Question

    Though Ruby on Rails isn't available, you should be able to run ruby scripts as CGI scripts on X10. Put them in ~/public_html/cgi-bin and set execute permissions via your FTP client or cPanel. Make sure to include a shebang line with the path to the ruby interpreter. Search the web or these forums for more info.

    However, if you want to learn Ruby, you should install an interpreter on your own computer to play with. You don't want to learn Ruby and CGI scripting simultaneously.
    Last edited by misson; 03-12-2010 at 01:51 AM.
    Be sure to read all pages linked in this post; they have further information that should prove useful. When asking for help, make sure you follow Eric Raymond's and Jon Skeet's guidelines for prompt, accurate responses. Please answer any questions I ask; they're not rhetorical (probably). Any posted code is intended as illustrative example, rather than a solution to your problem to be copied without alteration. Study it to learn how to write your own solution.
    Misson, not Mission.

+ Reply to Thread

Similar Threads

  1. My 2cents on Ruby vs PHP.
    By jwillia in forum Programming Help
    Replies: 0
    Last Post: 03-15-2008, 11:18 PM
  2. Ruby on Rails Support
    By jline in forum Free Hosting
    Replies: 2
    Last Post: 01-19-2008, 07:11 AM
  3. newbie with a really basic question
    By clouding in forum Scripts & 3rd Party Apps
    Replies: 1
    Last Post: 11-28-2007, 01:30 PM
  4. Odd question but will I be banned for this?
    By sielk in forum Free Hosting
    Replies: 3
    Last Post: 09-28-2007, 11:29 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
x10hosting free hosting for the masses
dedicated servers