Welcome to Welcome to DNF.com™ - Domain Sales, Domain Forum, Domain Appraisals, Domain Registrars

If you are new to domains and looking to buy, sell and learn about domains then you have come to the right place. DNForum is the largest domain name community on the internet and continues to grow every day. There are over 105,000 domainers on DNForum doing everything from buying domains, selling domains, learning about domains and discussing domains. Take a minute and Register.

Register Today on DNForum IT'S FREE!

Results 1 to 20 of 20
  1. #1
    DNF Member

    Join Date
    Mar 2004
    Posts
    318
    DNF$
    3,442
    Bank
    0
    Total DNF$
    3,442
    Donate  

    HTML - is there a way to ...

    I know basic HTML... just getting to CSS.

    I want to place a number of text links on several pages of a website. I would like to have these text links in one place where I can update them and have it updated on all pages. So I don't have to manually make the changes on all pages. I don't know if I explained myself very well but is this possible?

    Thank you.

  2. #2
    Exclusive Lifetime Member
    prodigyair's Avatar
    Join Date
    Mar 2005
    Location
    usa
    Posts
    123
    DNF$
    333
    Bank
    0
    Total DNF$
    333
    Donate  

    Re: HTML - is there a way to ...

    Quote Originally Posted by 768768
    I know basic HTML... just getting to CSS.

    I want to place a number of text links on several pages of a website. I would like to have these text links in one place where I can update them and have it updated on all pages. So I don't have to manually make the changes on all pages. I don't know if I explained myself very well but is this possible?

    Thank you.
    I think you have to use PHP for that

    <? include../(file)?> or something like that I'm not to sure.

  3. #3
    DNF Member

    Join Date
    Mar 2004
    Posts
    318
    DNF$
    3,442
    Bank
    0
    Total DNF$
    3,442
    Donate  

    Re: HTML - is there a way to ...

    Not what I wanted to hear but thanks for the response.

  4. #4
    Country hopper
    katherine's Avatar
    Join Date
    Jul 2005
    Location
    Free World
    Posts
    7,499
    Country

    Iceland
    DNF$
    30,536
    Bank
    0
    Total DNF$
    30,536
    Donate  

    Re: HTML - is there a way to ...

    So what did you expect ?
    Using include files is the way to go
    NameNewsletter.com - free lists of available domain names
    ZoneFiles.net (beta) - ccTLD and gTLD droplists

  5. #5
    DNF Member

    Join Date
    Apr 2005
    Posts
    198
    DNF$
    26,303
    Bank
    0
    Total DNF$
    26,303
    Donate  

    Re: HTML - is there a way to ...

    Create a file that has all your links in it and name it something like links.html. Then on your pages, use <!--#include file="links.txt" --> where you want the links to go.

    You can set up the links.html file any way you want, so you could use an unordered list, table, ect. Where ever <!--#include file="links.txt" --> appears, the contents of links.html will be printed. The files have to end in .shtml, though, instead of .html.
    http://imgshark.com Free image hosting, No account needed, 5mb upload

  6. #6
    The Bishop
    namestrands's Avatar
    Join Date
    Jan 2005
    Location
    Langley, VA
    Posts
    4,053
    DNF$
    3,312
    Bank
    0
    Total DNF$
    3,312
    Donate  

    Re: HTML - is there a way to ...

    If you use the software Dreamweaver you can select the code you want to update on all pages and add it to the library. This way when you update one you update them all without the need of includes and it works with static HTML pages.
    Enterprise Communications and Social Media in Uist

  7. #7
    MomsDigest.com For Sale!
    cursal's Avatar
    Join Date
    Aug 2003
    Location
    Oregon
    Posts
    1,843
    DNF$
    16,854
    Bank
    0
    Total DNF$
    16,854
    Donate  

    Re: HTML - is there a way to ...

    Read up on SSI here: http://www.bignosebird.com/ssi.shtml
    SSI=server Side Includes. Will work for your purpose very well.
    PHP includes are very similar

    Good Luck!

  8. #8
    DNF Member

    Join Date
    Mar 2004
    Posts
    318
    DNF$
    3,442
    Bank
    0
    Total DNF$
    3,442
    Donate  

    Re: HTML - is there a way to ...

    Don't have Dreamweaver but #include file is what I was looking for. And the link cursal posted was helpful.

    Thanks guys. I appreciate it!

  9. #9
    Exclusive Lifetime Member
    dcristo's Avatar
    Join Date
    Feb 2005
    Location
    Australia
    Posts
    3,500
    DNF$
    3,798
    Bank
    0
    Total DNF$
    3,798
    Donate  

    Re: HTML - is there a way to ...

    Quote Originally Posted by 768768
    I know basic HTML... just getting to CSS.

    I want to place a number of text links on several pages of a website. I would like to have these text links in one place where I can update them and have it updated on all pages. So I don't have to manually make the changes on all pages. I don't know if I explained myself very well but is this possible?

    Thank you.
    One method would be to convert your .html pages to .shtml and use server Side Includes (SSI).

  10. #10
    DNF Regular
    DNGeeks's Avatar
    Join Date
    Jan 2005
    Location
    Winnipeg Canada
    Posts
    625
    Country

    Canada
    DNF$
    10,316
    Bank
    0
    Total DNF$
    10,316
    Donate  

    Re: HTML - is there a way to ...

    You could use php, ssi or javascript to include a file.

    If you want to use ssi, you do not need to change your pages to .shtml if you are able to use .htaccess.

  11. #11
    DNF Addict
    Mr.Domains's Avatar
    Join Date
    Sep 2004
    Location
    Geneva, Switz.
    Posts
    1,868
    Country

    Great Britain
    DNF$
    3,233
    Bank
    6,090
    Total DNF$
    9,323
    Donate  

    Re: HTML - is there a way to ...

    Yes, javascript would do it too.
    Create a file called "links.js" and enter your links in document.write(); statements like so:

    <!--
    document.write('<a href="http://www.link1.com">link 1</a>');
    document.write('<a href="http://www.link2.com">link 2</a>');
    //-->
    Then call it from a SCRIPT tage like so:

    <SCRIPT SRC="links.js"></SCRIPT>
    Neil Hillman - Web Developer, Pixel Pusher...

  12. #12
    DNF Member

    Join Date
    Mar 2004
    Posts
    318
    DNF$
    3,442
    Bank
    0
    Total DNF$
    3,442
    Donate  

    Re: HTML - is there a way to ...

    Thanks, guys. Everything works like I think it should but...

    When my files were .html files I could click on them and view them via IE locally - on my computer. I could view it before uploading to make sure everything is ok.

    Now that they're .shtml files I can no longer view them. I have right clicked on them and chose "use IE to open" but nothing. Of course I need to view the pages before I upload them so what do I do? I'm using WIN XP home edition with the latest v of IE.

    Is there some way I'm suppose to convert .html to .shtml? All I did was rename them. It seems to have worked except for the above problem.

    Help!

  13. #13
    a.k.a. Nameslave
    Anthony Ng's Avatar
    Join Date
    May 2002
    Location
    Toronto, ON
    Posts
    4,985
    Country

    Canada Follow Anthony Ng On Twitter Add Anthony Ng on Facebook
    DNF$
    4,533
    Bank
    0
    Total DNF$
    4,533
    Donate  

    Re: HTML - is there a way to ...

    I would prefer using PHP includes to SSI.
    Profoundly influenced by #Bauhaus, @Nameslave unrepentantly embraces #Minimalism in his #multimedia portfolio. His early works include an experimental adaptation of Chekhov’s Cherry Orchard inspired at least partly by Robert Fripp. His totally irrelevant M.Ed. dissertation examines Organizational Culture and Change Management.

  14. #14
    Exclusive Lifetime Member
    dcristo's Avatar
    Join Date
    Feb 2005
    Location
    Australia
    Posts
    3,500
    DNF$
    3,798
    Bank
    0
    Total DNF$
    3,798
    Donate  

    Re: HTML - is there a way to ...

    Quote Originally Posted by 768768
    Thanks, guys. Everything works like I think it should but...

    When my files were .html files I could click on them and view them via IE locally - on my computer. I could view it before uploading to make sure everything is ok.

    Now that they're .shtml files I can no longer view them. I have right clicked on them and chose "use IE to open" but nothing. Of course I need to view the pages before I upload them so what do I do? I'm using WIN XP home edition with the latest v of IE.

    Is there some way I'm suppose to convert .html to .shtml? All I did was rename them. It seems to have worked except for the above problem.

    Help!
    You did the right thing, you just have to rename the files.

    To edit the .shtml files, open them up in a html editor such as dreamweaver.

  15. #15
    DNF Member

    Join Date
    Mar 2004
    Posts
    318
    DNF$
    3,442
    Bank
    0
    Total DNF$
    3,442
    Donate  

    Re: HTML - is there a way to ...

    nameslave: Thanks but I don't know PHP. It's next but I have to get thru html first.


    dcristo: Thank you. I can edit the files (I usually just use notepad) but after editing, I want to be able to see the actual page b4 uploading them. I can no longer do that after I renamed them to .shtml.

  16. #16
    DNF Member

    Join Date
    Apr 2005
    Posts
    198
    DNF$
    26,303
    Bank
    0
    Total DNF$
    26,303
    Donate  

    Re: HTML - is there a way to ...

    The pages worked after you uploaded? They should still be viewable in IE even with the .shtml extension. The included part will not be visible, but everything else on that page should be.
    http://imgshark.com Free image hosting, No account needed, 5mb upload

  17. #17
    DNF Member

    Join Date
    Mar 2004
    Posts
    318
    DNF$
    3,442
    Bank
    0
    Total DNF$
    3,442
    Donate  

    Re: HTML - is there a way to ...

    Pages worked fine after uploading. But the pages are not viewable in IE. I even renamed them back to .html and then I was able to view them again. Renamed them back to .shtml and nope.

    Since you say they should still be visible it must be something with my system. But I'm at a lost as to what to do now. I right click on the file... click on "open with IE"... it doesn't do anything.

  18. #18
    Bloody Hell
    Acro's Avatar
    Join Date
    Feb 2004
    Location
    USA
    Posts
    28,666
    Country

    Holy See
    DNF$
    15,567
    Bank
    0
    Total DNF$
    15,567
    Donate  

    Re: HTML - is there a way to ...

    If the dynamic portion of the included file contains broken table structures, the files won't display correctly locally. Try uploading them to a test portion of your web site in order to preview.

    DomainGang.com - Digital Entertainment for Domainers
    Acroplex - Web & Graphics
    Acro.net - My Blog

  19. #19
    a.k.a. Nameslave
    Anthony Ng's Avatar
    Join Date
    May 2002
    Location
    Toronto, ON
    Posts
    4,985
    Country

    Canada Follow Anthony Ng On Twitter Add Anthony Ng on Facebook
    DNF$
    4,533
    Bank
    0
    Total DNF$
    4,533
    Donate  

    Re: HTML - is there a way to ...

    Quote Originally Posted by 768768
    nameslave: Thanks but I don't know PHP. It's next but I have to get thru html first.
    I'm not a PHP expert either. But to use PHP includes, you only need to:

    a) rename your .htm(l) files to .php
    b) add an include tag (very much like any other HTML tag)
    c) create a separate .inc file (rename from a plain text file) which holds the data you want to change more often

    The best thing is: it is fast and powerful. I use PHP includes to write most of my web pages now (in "building blocks") so I can change site-wide changes by modifying just 1 single file (the .inc one).

    Search over at Google for e.g. "php incudes" or go straight to php.net for some entry-level tutorials, and you'll find they are not much different than HTML. Hope this helps.
    Profoundly influenced by #Bauhaus, @Nameslave unrepentantly embraces #Minimalism in his #multimedia portfolio. His early works include an experimental adaptation of Chekhov’s Cherry Orchard inspired at least partly by Robert Fripp. His totally irrelevant M.Ed. dissertation examines Organizational Culture and Change Management.

  20. #20
    DNF Member

    Join Date
    Mar 2004
    Posts
    318
    DNF$
    3,442
    Bank
    0
    Total DNF$
    3,442
    Donate  

    Re: HTML - is there a way to ...

    Quote Originally Posted by Acroplex
    If the dynamic portion of the included file contains broken table structures, the files won't display correctly locally. Try uploading them to a test portion of your web site in order to preview.
    No, no tables. My original intent was for text links which I would be able to easily change when I wanted to. I didn't like the way they looked so I have one which is just AdSense and another which is just a copyright footer.

    I have noticed when the files are .html that locally they have the IE logo. When they're .shtml they just show the .txt logo. For some reason my system is not associating IE with them... even when I tell it to open the files with IE. Something I would like to figure out but I think I'm going to try the php or java script suggested by nameslave and Mr.Domains.

    Quote Originally Posted by nameslave
    Search over at Google for e.g. "php incudes" or go straight to php.net for some entry-level tutorials, and you'll find they are not much different than HTML. Hope this helps.
    Thanks, nameslave. I did find this http://www.ibdhost.com/help/templates/ which I found very helpful. I've included the link as other newbies may find it useful.

    A question that comes to mind with php though... If you're "calling" all your pages, none of the content is actually there for the search engines, is it? You know, content is king. I must not be thinking about this right or it wouldn't be so popular. But how are the SE reading your pages if most of the content is in other files?

    Thanks!
    Last edited by 768768; 11-06-2005 at 11:09 AM. Reason: Automerged Doublepost

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

Domain name forum recommended by Domaining.com