Programming Forums
User Name Password Register
 

RSS Feed
FORUM INDEX | TODAY'S POSTS | UNANSWERED THREADS | ADVANCED SEARCH

Reply
 
Thread Tools Display Modes
Old Nov 17th, 2005, 1:43 PM   #1
nnxion
Programming Guru
 
nnxion's Avatar
 
Join Date: Jun 2005
Location: elemental plane
Posts: 1,429
Rep Power: 5 nnxion is on a distinguished road
Does someone have a site for me?

Uhmm... I am really bad with PHP, so my site sucks. I need a new one, but like I said, I suck in PHP. So I was wondering if someone had a template laying around, where I would just need to enter a new title and change some things, but just the design needs to be good.
Mabe a mysql db for reading from?

My site is currently just using HTML and CSS, design is not is not bad, but when HTML is not easily extendable.
To give you an impression of what my site desing used to look like:
<?php

$news = '
<div class="news">
No news yet.
</div>
';

$links = '
<div class="links">
No links available.
</div>
';

function getContents($page)
{
	global $news, $links;
	switch($page)
	{
		case 'news':
		echo $news;
		break;

		default:
		echo $news;
		break;
	}
}

?>
__________________
"Employ your time in improving yourself by other men's writings, so that you shall gain easily what others have labored hard for."
-- Socrates
nnxion is offline   Reply With Quote
Old Nov 17th, 2005, 1:47 PM   #2
Pizentios
Programming Guru
 
Pizentios's Avatar
 
Join Date: May 2004
Location: Brandon, Manitoba, Canada
Posts: 2,023
Rep Power: 7 Pizentios is on a distinguished road
Send a message via ICQ to Pizentios Send a message via MSN to Pizentios
Php really isn't used for design. It's more for making web apps, or reading from a db for a dynamic website.
__________________
Profanity is the one language that all programmers understand.

Check out my Blog <---updated Nov 30 2007!
Pizentios is offline   Reply With Quote
Old Nov 17th, 2005, 1:54 PM   #3
Ooble
I eat cake for breakfast.
 
Ooble's Avatar
 
Join Date: Jul 2004
Location: In my box.
Posts: 4,434
Rep Power: 9 Ooble is on a distinguished road
Look out for my PHP5/DB-driven site builder! In stores soon!

Seriously, I'm actually building one of these, though progress is slow. My suggestion would be to learn XHTML and CSS properly, and get a copy of PHP and MySQL Web Development, 2nd Edition by Welling and Thomson.
__________________
Me :: You :: Them
Ooble is offline   Reply With Quote
Old Nov 17th, 2005, 2:19 PM   #4
nnxion
Programming Guru
 
nnxion's Avatar
 
Join Date: Jun 2005
Location: elemental plane
Posts: 1,429
Rep Power: 5 nnxion is on a distinguished road
Yeah I already know XHTML and CSS I know the syntax of PHP too, just cannot program it with good style. But I could get that book, but it'll probably take me longer to build a decent site than building my own OS
Why can't their be a 3 layer model for websites in PHP? :p
__________________
"Employ your time in improving yourself by other men's writings, so that you shall gain easily what others have labored hard for."
-- Socrates
nnxion is offline   Reply With Quote
Old Nov 17th, 2005, 5:09 PM   #5
Ooble
I eat cake for breakfast.
 
Ooble's Avatar
 
Join Date: Jul 2004
Location: In my box.
Posts: 4,434
Rep Power: 9 Ooble is on a distinguished road
C'mon... it's like really easy C...
__________________
Me :: You :: Them
Ooble is offline   Reply With Quote
Old Nov 17th, 2005, 8:14 PM   #6
nnxion
Programming Guru
 
nnxion's Avatar
 
Join Date: Jun 2005
Location: elemental plane
Posts: 1,429
Rep Power: 5 nnxion is on a distinguished road
In C it's easy, you have a main with functions or nicely ordered classes (in the case of C++). But here you have HTML where you can throw in some PHP, but then my website's height cannot be set statically so you have to do some tricks to get that right, then when you get that, then if you type too much or set the font too large in your webbrowser then my text leaps off of the background. A lot of such problems, so really my problem is not with PHP but with HTML...Can we not create something else instead of that? :p (I know we can but that cannot be displayed with say Firefox )

Just hurry on your site builder, haha :p and make it open source

(Man I got a lot of smilies in my posts.)
__________________
"Employ your time in improving yourself by other men's writings, so that you shall gain easily what others have labored hard for."
-- Socrates
nnxion is offline   Reply With Quote
Old Nov 17th, 2005, 10:53 PM   #7
Infinite Recursion
Programming Guru
 
Infinite Recursion's Avatar
 
Join Date: Jul 2004
Location: United States
Posts: 3,467
Rep Power: 8 Infinite Recursion is on a distinguished road
Send a message via MSN to Infinite Recursion Send a message via Yahoo to Infinite Recursion
I have the book that Ooble mentions and it is great.
__________________
http://jasonpowers.net

"There are a thousand hacking at the branches of evil to one who is striking at the root."
Infinite Recursion is offline   Reply With Quote
Old Nov 18th, 2005, 6:58 AM   #8
DaWei
Resident Grouch
 
DaWei's Avatar
 
Join Date: Jun 2005
Posts: 6,453
Rep Power: 10 DaWei is on a distinguished road
"PHP and MySQL" by Williams and Lane is also okay. The examples are written around the development of an online wine-store/database. If you decide to get into nested queries, be sure and have a bottle of aspirin on hand.

Its treatment of templates is very restricted, though there are examples.

"Separation of presentation and content" is, of course, not possible. A page would look funny all bold at the top, and pink on the bottom. The thing is to keep it separate until the last possible moment, as much as you can. Let the browser meld it together. PHP only emits the HTML you (or a template, or a friend, or something) tell it to. It won't make you a design nabob. Along with the book or books mentioned, read something by Molly Holschweig and keep the PHP manual handy.
__________________
Abstraction doesn't make it impossible to write bad code; it makes it possible to write superior code.
Contributor's Corner: Grumpy on C++ Exceptions DaWei on Pointers
DaWei is offline   Reply With Quote
Old Nov 18th, 2005, 10:41 AM   #9
Lich
Professional Programmer
 
Lich's Avatar
 
Join Date: May 2005
Location: Detroit
Posts: 254
Rep Power: 4 Lich is on a distinguished road
Send a message via AIM to Lich Send a message via MSN to Lich
Quote:
Originally Posted by Infinite Recursion
I have the book that Ooble mentions and it is great.
me too, although I got the 3rd edition. Still an awsome book, well worth the money.
__________________
--John Cruz
Web Developer
www.cruzweb.net
Lich is offline   Reply With Quote
Old Nov 18th, 2005, 5:56 PM   #10
Ooble
I eat cake for breakfast.
 
Ooble's Avatar
 
Join Date: Jul 2004
Location: In my box.
Posts: 4,434
Rep Power: 9 Ooble is on a distinguished road
There's a third edition? Man, if only these buggers weren't so expensive...

nnxion: I agree, getting browsers to listen is a pain. However, you can set your page height statically - just make sure to set the html element's height too:

http://ooble.no-ip.com/temp.php
__________________
Me :: You :: Them
Ooble is offline   Reply With Quote
Reply

Bookmarks

« Previous Thread in Forum | Next Thread in Forum »

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump




DaniWeb IT Discussion Community
All times are GMT -5. The time now is 4:30 AM.

Powered by vBulletin® Version 3.7.0, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Copyright ©2007 DaniWeb® LLC