Something simple i need to do but cant figure it out...

Discussion in 'HTML & Website Design' started by cscott5288, May 12, 2008.

  1. #1
    Ok lets just say i have about 21 pages on my site.

    On each page i have an area where i put text, but i want for that area of text to be able to be editied from one place only. So i want to apply changes to all the 21 pages by just changing one area like what css does with fonts and styles except for i actualy have to insert content.

    How can i do this wihthout converting all my pages to php or something?
    there must be a simple way!

    thanks ahead
     
    cscott5288, May 12, 2008 IP
  2. web-master

    web-master Peon

    Messages:
    838
    Likes Received:
    15
    Best Answers:
    0
    Trophy Points:
    0
    #2
    I hate to say this but iframes? Nah PHP would be the best I think.
     
    web-master, May 12, 2008 IP
  3. wd_2k6

    wd_2k6 Peon

    Messages:
    1,740
    Likes Received:
    54
    Best Answers:
    0
    Trophy Points:
    0
    #3
    wd_2k6, May 12, 2008 IP
  4. cscott5288

    cscott5288 Active Member

    Messages:
    912
    Likes Received:
    5
    Best Answers:
    0
    Trophy Points:
    60
    #4
    Thanks! i did everything dan mentioned for server-side includes and it worked! i am having one problem though. I creating my new homepage as a .shtml and deleted my old .html homepage. For some reason i can't get my server to recognize the shtml as being my homepage (the page that shows up when going to my domain). i can get it to show up if i type in the full name www. mydomain.com/home.shtml

    how can i set it to my front page?

    thanks!
     
    cscott5288, May 12, 2008 IP
  5. wd_2k6

    wd_2k6 Peon

    Messages:
    1,740
    Likes Received:
    54
    Best Answers:
    0
    Trophy Points:
    0
    #5
    Nice one! I think you have to add it to the accepted list of homepages inside the DirectoryIndex list for your Apache config file if you have access to it ?

    EDIT: I did a bit of futher searching rather than doing the above try the following. Make a new text file, and add this to it:
    DirectoryIndex index.html index.htm index.php index.shtml index.shtm
    Code (markup):
    Then save this file as .htaccess and upload it to the document root. Note: The file is simply to be saved as .htaccess no .txt exstensions or anything like that. Also this file might already exist in your root folder, if so just add the code to the exsisting file.
     
    wd_2k6, May 12, 2008 IP
    cscott5288 likes this.
  6. simplyrahul

    simplyrahul Member

    Messages:
    13
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    36
    #6
    Ok I was kinda looking for the same thing but for different purpose...this helps
     
    simplyrahul, May 12, 2008 IP
  7. cscott5288

    cscott5288 Active Member

    Messages:
    912
    Likes Received:
    5
    Best Answers:
    0
    Trophy Points:
    60
    #7
    I did that and it worked! thanks so much, rep added!!
     
    cscott5288, May 12, 2008 IP
  8. cscott5288

    cscott5288 Active Member

    Messages:
    912
    Likes Received:
    5
    Best Answers:
    0
    Trophy Points:
    60
    #8
    Ok guys, im having trouble again. Ive converted all my pages to shtml (and all the internal links) but for some reason, the include is only working on the home page (or only one page). any other page i try to put it in i get this: [an error occurred while processing this directive] where the include should be. Im guessing i need to make some adjustments, what do i do?
     
    cscott5288, May 12, 2008 IP
  9. cscott5288

    cscott5288 Active Member

    Messages:
    912
    Likes Received:
    5
    Best Answers:
    0
    Trophy Points:
    60
    #9
    Ok nvm it doesnt work for any of my pages!!i guess i thought i had inserted the include on my homepage, but i didnt icorumba!! this is what my .htacess looks like:

    DirectoryIndex index.html index.htm index.php index.shtml index.shtm home.shtml
    AddType text/html .shtml
    AddHandler server-parsed .shtml
    Options +Includes

    was i correct in putting those in?

    what am i doing wrong..
     
    cscott5288, May 12, 2008 IP
  10. cscott5288

    cscott5288 Active Member

    Messages:
    912
    Likes Received:
    5
    Best Answers:
    0
    Trophy Points:
    60
    #10
    HAHA Scratch everything i just said in the last two posts! i had unknlowingly deleted the .html file in my directory that the include was pointing too!

    everything is jolly now :p
     
    cscott5288, May 12, 2008 IP