HTML help
 

MegaSack DRAW - This year's winner is user - rgwb
We will be in touch

[Closed] HTML help

14 Posts
6 Users
0 Reactions
61 Views
Posts: 16363
Free Member
Topic starter
 

I am trying to create a website that has text and image content read from a file. Not really sure where to start or what to google so any pointers would help. Ideally I want a file full of all the content that is then loaded to the website. Is this possible/easy?

So the file would look something like:
PageTitle1 = "This is page 1"
Content1 = "Lots of text about something"
Image1 = "/images/pitureofahorsey.jpg"

and the index.html would very very roughly be
< h1 > PageTitle1 < /h1 >
< p > Content1 < /p >
< img > Image1 < /img >

to look like this on the website
[b]This is page 1[/b]
Lots of text about something
[img] [/img]


 
Posted : 14/04/2011 4:59 pm
Posts: 0
Free Member
 

Is this just a one-off or is it that you're almost trying to create your own content management system, to separate the content and the layout??

Rachel


 
Posted : 14/04/2011 5:01 pm
Posts: 16363
Free Member
Topic starter
 

trying .. to separate the content and the layout

I suppose I am trying to do that. The idea is that you just edit the content file and everything else stays the same


 
Posted : 14/04/2011 5:08 pm
Posts: 0
Free Member
 

IN that case, it's all possible but so is re-inventing pencil sharpeners - why do it when someone has already spent a lot of time on it and done a really good job?

Seriously, you will benefit from having a look at a Content Management System, let's say WordPress. Learn how that works and it will pay back a thousand times.

www.wordpress.org

(I actually use a different CMS, www.drupal.org, but I'm told WordPress has a quicker learning curve)

Rachel


 
Posted : 14/04/2011 5:12 pm
Posts: 0
Free Member
 

I want to know why that horse has its head stuck in a tree!

is it dead ?


 
Posted : 14/04/2011 5:42 pm
Posts: 5938
Free Member
 

wordpress
joomla
drupal

all do this much better than you will ever be able to.


 
Posted : 14/04/2011 5:48 pm
Posts: 16363
Free Member
Topic starter
 

So is it hard? Using something as complex as wordpress seems like overkill. I only really want a file with the layout in html and a file with the content, txt or xml or something. A bit more googling seems to imply it is tricky and need PHP and mySql. I'd have though it would be simpler as is it is with programming in C and just using 'include'

Not sure about the horse. Probably hungry or stupid or both.


 
Posted : 14/04/2011 5:50 pm
Posts: 5938
Free Member
 

yeah, you would need PHP as a minimum. doubt you'd need mysql, maybe to store the tags?


 
Posted : 14/04/2011 5:52 pm
Posts: 0
Free Member
 

Yes, you would need both php and mysql. It I'd worth it though and virtually every hosting company out there will supply those anyway.

You're right; you could it it much more basically but these tools exist for a reason - flexibility. Youre bound to want to do that one little extra thing one day that a custom coded solution just won't let you do without a lot of work.

Rachel


 
Posted : 14/04/2011 6:19 pm
Posts: 16363
Free Member
Topic starter
 

wordpress
joomla
drupal

Will these work locally served without an internet connection?


 
Posted : 15/04/2011 9:14 am
Posts: 91097
Free Member
 

PHP would be easy enough.

But yes, don't re-invent the wheel, it'll be rubbish.


 
Posted : 15/04/2011 9:16 am
Posts: 0
Free Member
 

HTML + XML

http://www.w3schools.com/XML/tryit.asp?filename=tryxml_display_table


 
Posted : 15/04/2011 9:30 am
Posts: 0
Free Member
 

Yes, you can certainly use Drupal without an internet connection - that's how I work on the train if I'm building something. I have a version of Drupal (I use the Acquia all-in-one package at http://network.acquia.com/downloads) and it allows me to work on my Macbook just as though I was at work.

We also have some Drupal websites on our private network at work.

Rachel


 
Posted : 15/04/2011 9:33 am
Posts: 0
Free Member
 

If your on a Windows platform, you can use XAMPP to run stuff locally.


 
Posted : 15/04/2011 9:43 am
Posts: 16363
Free Member
Topic starter
 

HTML + XML

http://www.w3schools.com/XML/tryit.asp?filename=tryxml_display_table

Thanks. This looks promising. Just written a very basic version of what I want so I'll have a bit more of a play. Shall look at the existing options, too


 
Posted : 15/04/2011 11:20 am