View Full Version : technical help please
thebookiesoffers
1st June 2009, 20:49
My site is in my sig for those that don't know it and you can see I want the site set out over the same main pages, i.e the table running down the left with 'bookies free bets'. What I'd like to know is is there a way of doing one change such as adding a new free bet and that change will happen over all the pages so i don't have to edit all 100 odd pages individually?
hope that makes sense
Kev Jaques
1st June 2009, 21:06
Hmm, please don't tell me you have 100 odd pages which have the table inserted individually?
You should have 1 or 2 templates with various links in and just include the template link within the page, therefore leaving you to just change 1 or 2 files only, so yes it can be done.
thebookiesoffers
1st June 2009, 21:11
Hmm, please don't tell me you have 100 odd pages which have the table inserted individually?
You should have 1 or 2 templates with various links in and just include the template link within the page, therefore leaving you to just change 1 or 2 files only, so yes it can be done.
er, well, but, er :eek:
thats cracking news lol is there a good resource that I can have a read up on how to do it that you know off
david64
1st June 2009, 22:33
Most people use what are called content management system (CMS), which can create dynamic sites, i.e. you can load unlimited data into set templates. So, you would be able to create a template to wrap the default styling of your site and then create templates for certain pages, i.e. one that loads the details of all your betting companies. Then you can create a template for your static content and just include it in every page. My recommendation would be to build it yourself with XSL :cool: However, you would probably need to look at something like Joomla or WordPress my recommendation for a CMS: Symphony. TBH, I don't know if you would be able to do this though as it would take some understanding of a programming language.
Alternativly you can carry on as you are and use:
http://en.wikipedia.org/wiki/Server_Side_Includes
which allow you to include html files in other HTML files. I don't think many hosts have this enabled though and it only works on Apache servers.
er, well, but, er :eek:
thats cracking news lol is there a good resource that I can have a read up on how to do it that you know off
Kev Jaques
1st June 2009, 22:47
you can also insert html files via object, however, that loads them in an iframe which you don't want. As David64 pointed out you will want server includes.
Either way you are looking at a lot of work to consolidate all of the table into the include file, good time to do it really, refactor the list of links into a list rather than table.
david64
1st June 2009, 22:55
@Kev: I like your title tag. I think that is probably one of the most intelligent ones I've seen.
Kev Jaques
1st June 2009, 23:01
Thanks David :)
thebookiesoffers
3rd June 2009, 16:17
Ok, right. The oranage section down the left is created in the css file, is there anyway i can insert the text into that at all to save time?
Kev Jaques
3rd June 2009, 16:25
Nope
The css is only to style the div etc.. not to contain markup
If you have exactly the same code for those things you could do a search and replace, failing that you can easily highlight that whole table, delete it and insert the link to the include file.
Depending on how many different link structures you wanted you create x many includes and put your links into those, then include the appropriate link.
If just keeping it simple same links in all pages then only need to create one include.
It won't take you long as it's basically copy/delete/paste.
Also a good time to put those links in a list rather than table.
thebookiesoffers
3rd June 2009, 16:36
Nope
The css is only to style the div etc.. not to contain markup
If you have exactly the same code for those things you could do a search and replace, failing that you can easily highlight that whole table, delete it and insert the link to the include file.
Depending on how many different link structures you wanted you create x many includes and put your links into those, then include the appropriate link.
If just keeping it simple same links in all pages then only need to create one include.
It won't take you long as it's basically copy/delete/paste.
Also a good time to put those links in a list rather than table.
cheers mate, just trying to get my head round it all. Just wondering how this site gets round this if you can tell? freebets(dot)co(dot)uk
Kev Jaques
3rd June 2009, 16:54
With that many links would make sense to store them in the database and spit them into a simple include file which is linked to either the framework or page. That kind of site will be using a framework so only the content changes (either static or dynamic).
This would be more work for your site if you already have loads of individual pages.
Would do the simple include for the now though, moving things into include files will be the way forward though and you could do those in chunks.
david64
3rd June 2009, 17:05
You can add content to a page via CSS:
http://www.w3schools.com/Css/pr_gen_content.asp
However. I am afraid that it would be a bit of a botch and it only works in some browsers.
If you want the kind of work doing that you are suggesting, I think you would have to pay someone to do it as its not the kind of thing you can just advise someone on with a few lines on a forum.
If you want to get it real cheaply done, youcan use a site like GetAFreelancer or RentACoder, but I would say that as you don't know about programming, that it would be difficult to make that work as it is largely used as an outsource for develpoment companies.
Otherwise, you could try and get someone here to do it.
UKSBD
3rd June 2009, 18:12
I use a bit of software called Universal Explorer which has a great search
and replace feature.
you can do something like
Find:
<tr>
<td>Existing line</td>
<td>Existing line</td>
</tr>
Replace with:
<tr>
<td>Existing line</td>
<td>Existing line</td>
</tr>
<tr>
<td>New line</td>
<td>New line</td>
</tr>
and it will change all pages for you.
Kev Jaques
3rd June 2009, 18:21
David is right you can add some content via CSS but for your issue it's totally not advisable hence I said no ;)
matt.chatterley
3rd June 2009, 18:24
David is right you can add some content via CSS but for your issue it's totally not advisable hence I said no ;)
I think the various comments are about right - would be happy to have a look at quoting against this, but looking through the code, etc is going to take a while, I suspect (as ever, hard to say without digging in the first place)!