RoR site structure on Apache

This is a simple ‘hello word’ application.

code structure is here

http://www.smtservers.com/demo/

I can access it here

http://www.smtservers.com/demo/public/say/hello

But the url so long and other people can see my source code

I want to access the same code like this

http://www.smtservers.com/say/hello

I also the hosting company,he told me change .htaccess.

Please give me a idea how to change the setting in .htaccess

Thanks

MS

You should change your DocumentRoot. It now points to /…/…/demo you
want it to point to /…/…/demo/public

You should change the Directory directive(s) accordingly.

Colin wrote:

You should change your DocumentRoot. It now points to /…/…/demo you
want it to point to /…/…/demo/public

You should change the Directory directive(s) accordingly.

I can not httpd.conf.The hosting company ask me to change
.htaccess.Please show me how to change .htaccess.Thanks

On Sat, 2006-02-25 at 14:05 +0100, mark sheran wrote:

Colin wrote:

You should change your DocumentRoot. It now points to /…/…/demo you
want it to point to /…/…/demo/public

You should change the Directory directive(s) accordingly.

I can not httpd.conf.The hosting company ask me to change
.htaccess.Please show me how to change .htaccess.Thanks


a virtual host provider is a terrible environment with which to learn
RonR and you are wasting your time.

learn/develop on your own system and use the included webrick server on
your machine as your web server. After you have an application ready to
use, you can then work with your virtual host provider to get it
transferred over and functional…which is still likely to be no easy
task if the virtual host provider is not familiar with providing RonR
services.

To answer your question (not that it is going to help you), an .htaccess
file is created in the public directory automatically when you issue
command…‘rails WHATEVER’ - thus - you should already have this file.

Craig

Craig W. wrote:

a virtual host provider is a terrible environment with which to learn
RonR and you are wasting your time.

learn/develop on your own system and use the included webrick server on
your machine as your web server. After you have an application ready to
use, you can then work with your virtual host provider to get it
transferred over and functional…which is still likely to be no easy
task if the virtual host provider is not familiar with providing RonR
services.

Yes, Mark, please… You keep asking how to fix your “hello world” app
on your server and
several of us, myself included, have told you that this is a bad idea.
Do you have a
computer at home?

Yes I learn that in my windows system

but I have to know how to make RoR work in hosting machine

Thank you for help

Mark

I see the .htaccess.Please let me know how to change it make the link
work
http://www.smtservers.com/say/hello

and like
http://www.smtservers.com/demo/public/say/hello

I do not like people see my site structure.

Thanks

Alright, I can’t vouch for how well this will or won’t work, but you
could
try URL Rewriting:

http://www.yourhtmlsource.com/sitemanagement/urlrewriting.html

Read that tutorial and try it out. However, I can’t tell you how this
will
diner your performance.

Hope that helps,
Ryan