Koozali.org: home of the SME Server

web server

Lee Hoay Fern

web server
« on: March 12, 2002, 12:33:39 PM »
hi,

currently we have designed new homepage for our company

but we didnt have the index.htm but we have the main page at :frame/main/main.html

I cant change from  frame/main/main.html to index.htm because if i change, all the links have to change as well.

can anyone help me how should i solve this prob

pls
thanks

hoay fern

Bobby

Re: web server
« Reply #1 on: March 12, 2002, 01:54:58 PM »
In a non-e-Smith this can be set in /etc/httpd/conf/httpd.conf

You should see if this file is effected by the templates BEFORE just making changes to to.

I am pressed for time tonight, otherwise I would look into the template issue regarding this configuration file.

/B

Bruce

Re: web server
« Reply #2 on: March 12, 2002, 07:55:14 PM »
Work Around!

Simply copy the frame/main/main.html to a file named frame/main/index.htm .  Once you've done that, you can have the copied file launch automatically, and when the pages are redirected by links, they'll still go to the original page.  You can also use META code to automatically redirect immediately.

The key here is to remember that you need to do the copy every time you update the main page.

Also, see if the software you're using will allow you to change the name of the file at the entry point. My Ancestry software allows me to change the initial page to anything I want.

Chad Self

Re: web server
« Reply #3 on: March 12, 2002, 08:16:58 PM »
There is an easier way than updating two pages every time you make a change on your main page.

Create a blank index page --or one that has only a single image of your logo etc--and put the following code inside the tags


"5" is the number in seconds before the transfer takes place, so you can lower it to happen much quicker...Leave a space after the semicolon.

cheers
Chad

Bobby

Re: web server
« Reply #4 on: March 12, 2002, 10:53:01 PM »
How about this:

Create an index.html page.  This index.html contains two frames, one of zero size, and the other 100%.  The 0% loads blank, and the 100% loads the page you want.  Not only does this work, but keeps the URL nice and tidy.

I use this method for a site and it works great.  Didn't think of it last night.\

/B

Simeon

Re: web server
« Reply #5 on: March 13, 2002, 12:30:38 AM »
Try this:

mkdir -p /etc/e-smith/templates-custom/etc/httpd/conf/httpd.conf

cp /etc/e-smith/templates/etc/httpd/conf/httpd.conf/50DirectoryIndex00 /etc/e-smith/templates-custom/etc/httpd/conf/httpd.conf/50DirectoryIndex00

pico /etc/e-smith/templates-custom/etc/httpd/conf/httpd.conf/50DirectoryIndex00

you'll see the line:
DirectoryIndex index.htm index.html index.shtml index.cgi
add main.htm to the end of that line
save the file

then type
/sbin/e-smith/expand-template /etc/httpd/conf/httpd.conf

then type
service httpd reload


hope this helps.

Simeon

Re: web server Oops
« Reply #6 on: March 13, 2002, 12:38:59 AM »
Oops.  don't think i read the question properly.
Think that this may solve it though:
 

 
mkdir -p /etc/e-smith/templates-custom/etc/httpd/conf/httpd.conf

pico etc/e-smith/templates-custom/etc/httpd/conf/httpd.conf/81Aliases

put this line in it:

alias   /index.html   /main/main.html
 



save the file
 
 then type
 /sbin/e-smith/expand-template /etc/httpd/conf/httpd.conf
 
 then type
 service httpd reload
 
 
 haven't tried it myself but hope this helps.