? about adding pages
The only way I know to design my website is by creating a new html page for each page and then linking them together to make up a multi-page site.
I'm sure there is probably a better way, isn't there? How do you do it?
Is there anything wrong with the way I have done it?
My site: http://www.glammergal.com
Thank you for your help.
Renegade posted this at 23:37 — 14th February 2005.
He has: 3,022 posts
Joined: Oct 2002
Well, if you are new to this, then there is nothing wrong with the way you have done things.
You might want to look into PHP or ASP to dynamically generate website content.
CptAwesome posted this at 23:56 — 14th February 2005.
He has: 370 posts
Joined: Dec 2004
There is really no easy way to explain all the steps you can go through to automate the process but, 3 things you want to do are:
1. Seperate all the code, design, and content.
2. Have a common naming scheme, or logical database structure, because if you don't have that to begin with, it's a lot more work later.
3. Learn code tweaks, things like htaccess, and php's ability to read URIs, then http://www.website.com/users/name
can be the same thing as
http://www.website.com/users.php?name=name
But the biggest key is seperating the content, design and code. When you have those 3 things in their own spaces, you have a much more flexible, and dynamic page.
iselljewelry posted this at 11:53 — 15th February 2005.
They have: 3 posts
Joined: Feb 2005
Sorry to be dumb, what do you mean by separating the code, design, and content?
The common naming scheme ( as in jewelry1, jewelry2, etc....? )
I am not familiar with PHP, Htaccess, URI's, ASP....I will try to look to find out about them through the link you both have provided me though and hopefully will be able to
decipher what it is all about.
I basically know html and how to grab java scripts and add them. As far as anything else it's pretty much greek to me.
I want to have a really nice site, one that the seach engines won't cough at because in my type of business there are thousands (millions?) of listings.
I need to figure out how to getting seen.
iselljewelry posted this at 11:58 — 15th February 2005.
They have: 3 posts
Joined: Feb 2005
Okay, checked out the links you both gave me. The PHP link is very helpful ( thanks ).
The other two links are for website hosting? ( I don't understand what you want me to glean from this site )
CptAwesome posted this at 17:39 — 15th February 2005.
He has: 370 posts
Joined: Dec 2004
Ok, "website.com" is an EXAMPLE I was using an example of a naming scheme, not actual webpages, sorry for the confusion.
When I say seperating code, content and design,
Content: A database (or text files) with plain text in it, with some side information like catergorization, date etc. When using PHP most people use MySQL, but there are lots of databases out there. for info on mysql: http://dev.mysql.com/
Design: Your basic HTML, or XSS, or some other templating/style formating system.
Code: PHP, ASP, JSP, or (if I am not mistaken) ColdFusion. What this does is "pull" data from the "content" and delivers it via the "design"
If you're still unclear, I'll give one more "example"
Lets say I want 7 pages, about random stuff, and I want them to all look the same. Ok, so I have my 7 pages in txt files named 1-7.
Well, I have my design set up as template.html
So, someone comes to my site, they go to index.php
and what I want to see is a "?page=" after index.php, if I don't have one, or it's higher than 7, then I use the php to force a choice of a variable $page. Then I have the php call up the template, lets say into another variable using file_get_contents() and then the same thing with the $page.txt. So, once you have 2 variables $template and $page (or data, or whatever) then use something like ereg_replace(), preg_replace() or str_replace() to find a placeholder in the template file like "" and once it's replaced, you end up with 7 fully formatted html pages, you can automate it to automatically check when there are new ones, it doesn't have to be numbers, and this is just a basic run through of the concept.
You might want to look into Smarty I haven't tried it personally, but I have heard it's good, it's a php created, and driven templating engine.
Want to join the discussion? Create an account or log in if you already have one. Joining is fast, free and painless! We’ll even whisk you back here when you’ve finished.