Velocity Reviews

Velocity Reviews (http://www.velocityreviews.com/forums/index.php)
-   HTML (http://www.velocityreviews.com/forums/f31-html.html)
-   -   how to make website wide changes, later (http://www.velocityreviews.com/forums/t642178-how-to-make-website-wide-changes-later.html)

someone_else 11-01-2008 05:27 PM

how to make website wide changes, later
 
hi all,
I want to build a website where each page contains a common set of links to
other pages in the site. However, when I add a link, at a later date, I
don't want to have to add it manually to each page.

I have a rudimentary understanding of CSS, but I can't figure out how to use
it to create my basic page template, which contains the common links.

I'm sure I must be missing something very obvious.
Any simple examples out there?
cheers



Adrienne Boswell 11-01-2008 05:36 PM

Re: how to make website wide changes, later
 
Gazing into my crystal ball I observed "someone_else"
<qcnjnfwefwefmj@adsahnshcndncdrbtysdf.invalid> writing in
news:490c9189$1_1@mk-nntp-2.news.uk.tiscali.com:

> hi all,
> I want to build a website where each page contains a common set of
> links to other pages in the site. However, when I add a link, at a
> later date, I don't want to have to add it manually to each page.
>
> I have a rudimentary understanding of CSS, but I can't figure out how
> to use it to create my basic page template, which contains the common
> links.
>
> I'm sure I must be missing something very obvious.
> Any simple examples out there?
> cheers
>
>
>


You want to look into some sort of server side include, depending on
what language your hosting provider has available. For example

<?php include = "nav_inc.php"; ?>
or
<!--#include file = "nav_inc.asp"-->

--
Adrienne Boswell at Home
Arbpen Web Site Design Services
http://www.cavalcade-of-coding.info
Please respond to the group so others can share


Chris F.A. Johnson 11-01-2008 05:37 PM

Re: how to make website wide changes, later
 
On 2008-11-01, someone_else wrote:
> hi all,
> I want to build a website where each page contains a common set of links to
> other pages in the site. However, when I add a link, at a later date, I
> don't want to have to add it manually to each page.
>
> I have a rudimentary understanding of CSS, but I can't figure out how to use
> it to create my basic page template, which contains the common links.


You don't use CSS; that is for presentation, not content.

> I'm sure I must be missing something very obvious.
> Any simple examples out there?


Use server-side includes (SSI):

<!--#include file="links.html" -->

You may have to name the enclosing file with a .shtml suffix or set
the execute bit on it, depending on how your web server is set up.

--
Chris F.A. Johnson, webmaster <http://Woodbine-Gerrard.com>
================================================== =================
Author:
Shell Scripting Recipes: A Problem-Solution Approach (2005, Apress)

someone_else 11-01-2008 06:31 PM

Re: how to make website wide changes, later
 

"Chris F.A. Johnson" <cfajohnson@gmail.com> wrote in message
news:9e509$490c93c9$cef88ba3$10176@TEKSAVVY.COM...
> On 2008-11-01, someone_else wrote:
>> hi all,
>> I want to build a website where each page contains a common set of links
>> to
>> other pages in the site. However, when I add a link, at a later date, I
>> don't want to have to add it manually to each page.
>>
>> I have a rudimentary understanding of CSS, but I can't figure out how to
>> use
>> it to create my basic page template, which contains the common links.

>
> You don't use CSS; that is for presentation, not content.
>
>> I'm sure I must be missing something very obvious.
>> Any simple examples out there?

>
> Use server-side includes (SSI):
>
> <!--#include file="links.html" -->
>
> You may have to name the enclosing file with a .shtml suffix or set
> the execute bit on it, depending on how your web server is set up.
>
> --
> Chris F.A. Johnson, webmaster <http://Woodbine-Gerrard.com>
> ================================================== =================
> Author:
> Shell Scripting Recipes: A Problem-Solution Approach (2005, Apress)



Thanks for the quick replies guys.
Since my host does not provide SSI it looks like I will just have to
manually change each page. I can probably create a script in C or perl to
edit the files, but that'll take me longer than manually changing the pages!
Might be a fun project though.



Jonathan N. Little 11-01-2008 07:50 PM

Re: how to make website wide changes, later
 
Adrienne Boswell wrote:

> You want to look into some sort of server side include, depending on
> what language your hosting provider has available. For example
>
> <?php include = "nav_inc.php"; ?>


In PHP that's

<?php include("nav_inc.php"; ?>

> or
> <!--#include file = "nav_inc.asp"-->
>



--
Take care,

Jonathan
-------------------
LITTLE WORKS STUDIO
http://www.LittleWorksStudio.com

Jonathan N. Little 11-01-2008 07:54 PM

Re: how to make website wide changes, later
 
someone_else wrote:

> Since my host does not provide SSI it looks like I will just have to
> manually change each page.


Does host support PHP?

> I can probably create a script in C or perl to
> edit the files, but that'll take me longer than manually changing the pages!
> Might be a fun project though.



Google "html preprocessor"

--
Take care,

Jonathan
-------------------
LITTLE WORKS STUDIO
http://www.LittleWorksStudio.com

Adrienne Boswell 11-01-2008 08:00 PM

Re: how to make website wide changes, later
 
Gazing into my crystal ball I observed "Jonathan N. Little"
<lws4art@central.net> writing in news:2f94c$490cb316$40cba7aa$27166
@NAXS.COM:

>> <?php include = "nav_inc.php"; ?>

>
> In PHP that's
>
>


I _knew_ that. I just should refrain from posting in the morning before I
have coffee.

--
Adrienne Boswell at Home
Arbpen Web Site Design Services
http://www.cavalcade-of-coding.info
Please respond to the group so others can share


C A Upsdell 11-01-2008 08:02 PM

Re: how to make website wide changes, later
 
someone_else wrote:
>>> I want to build a website where each page contains a common set of links
>>> to
>>> other pages in the site. However, when I add a link, at a later date, I
>>> don't want to have to add it manually to each page.

> Since my host does not provide SSI it looks like I will just have to
> manually change each page. I can probably create a script in C or perl to
> edit the files, but that'll take me longer than manually changing the pages!
> Might be a fun project though.


Or use a text editor that can do a global search and replace.


someone_else 11-01-2008 08:13 PM

Re: how to make website wide changes, later
 

"C A Upsdell" <cupsdell@upsdell.invalid> wrote in message
news:geicjg$g47$1@registered.motzarella.org...
> someone_else wrote:
>>>> I want to build a website where each page contains a common set of
>>>> links to
>>>> other pages in the site. However, when I add a link, at a later date, I
>>>> don't want to have to add it manually to each page.

>> Since my host does not provide SSI it looks like I will just have to
>> manually change each page. I can probably create a script in C or perl to
>> edit the files, but that'll take me longer than manually changing the
>> pages! Might be a fun project though.

>
> Or use a text editor that can do a global search and replace.
>


I have and old version of Dreamweaver here, and it looks like it does 'block
find and replace' on multiple files .. great! .. I'll give it a try.



dorayme 11-01-2008 08:35 PM

Re: how to make website wide changes, later
 
In article <490ca087$1_3@mk-nntp-2.news.uk.tiscali.com>,
"someone_else" <qcnjnfwefwefmj@adsahnshcndncdrbtysdf.invalid> wrote:

> Since my host does not provide SSI it looks like I will just have to
> manually change each page.


In the past when people say this, others here say, get another host.
Because some sort of include is about the only really efficient way to
do this.

Even for me to get the energy to say this I had to have enough cups of
coffee to make a slope prance around like a boistrous monkey.

--
dorayme


All times are GMT. The time now is 08:45 AM.

Powered by vBulletin®. Copyright ©2000 - 2014, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.