0
votes

I am trying to make a very simple Rails program and have a problem. I try to make a home.html.erb file, and here is my code

Rails syntax error, unexpected end-of-input, expecting keyword_end

I am very sorry I can not upload the code because it was too long.

My problem is, when I tried to open the page

http://localhost:3000/

it said that I had the problem

app/views/pages/home.html.erb:24: syntax error, unexpected end-of-input, expecting end

But I think that I have enough </div>, so I still do not know why I have that problem?

Could you please help me solve this problem?

2
You forgot % - it should be <% end %> instead of <%end>. - Marek Lipka
BTW this is Ruby syntax error, so it comes from erb parser, which, frankly, doesn't care about your code's HTML compatibility at all, so it won't complain for things like missing </div> etc. - Marek Lipka
There is a syntax typo <% end %> instead of <% end > - Ranzit
paste your home.html.erb, you will get the help. - Bachan Smruty

2 Answers

0
votes

You have a typo in closing <% end %> tag in you erb file.

0
votes

There is a syntax typo <% end %> instead of <% end >