<p>Hello, I know little about web design so I hope this makes sense.
I am trying to integrate a very basic php site into an existing html website to create a blog. I have one page where I can enter info which is then published onto a page called blogentries.php which works fine on it's own. I want the info to be published into the blogentries div on my website that says "I WANT BLOG ENTRIES HERE" close to the bottom.
I thought it would be a simple case of making the connection to the database in the header and put the rest of the php into the div, but obviously there is more to it than that.
I was wondering if someone could look at the code for the two pages and explain how it should be done?
Wow, imagine you dump hundreds of hours into completing things and unlocking stuff and you lose it all.
Back in the day when cheats were built into games, you could at least unlock things again that way without spending hundreds of hours again. But those days are long gone for some reason as no one builds cheats into games anymore.
So it's even more painful that studio that's on its 6th installment **** it up so badly.
Question
Brodel
<p>Hello, I know little about web design so I hope this makes sense.
I am trying to integrate a very basic php site into an existing html website to create a blog. I have one page where I can enter info which is then published onto a page called blogentries.php which works fine on it's own. I want the info to be published into the blogentries div on my website that says "I WANT BLOG ENTRIES HERE" close to the bottom.
I thought it would be a simple case of making the connection to the database in the header and put the rest of the php into the div, but obviously there is more to it than that.
I was wondering if someone could look at the code for the two pages and explain how it should be done?
Thank you
blogentries.php
[b]blogpage in html[/b]
<!doctype html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>AJWatson - Blog</title>
<meta name="keywords" content=" art design, digital media design, graphic design, logo design, ">
<link rel="shortcut icon" href="favicon.ico" />
<!-- Load CSS -->
<link href="css/style.css" rel="stylesheet" type="text/css" />
<!-- Load Fonts -->
<link rel="stylesheet" href="http://fonts.googleapis.com/css?family=Droid+Serif:regular,italic,bold,bolditalic" type="text/css" />
<link rel="stylesheet" href="http://fonts.googleapis.com/css?family=Droid+Sans:regular,bold" type="text/css" />
</head>
<body>
<!--This is the START of the header-->
<div id="topcontrol" style="position: fixed; bottom: 5px; left: 960px; opacity: 1; cursor: pointer;" title="Go to Top"></div>
<div id="header-wrapper">
<div id="header">
<div id="logo"><a href="index.html"><img src="images/logo.png" width="100" height="80" alt="logo" /></a></div>
<div id="header-text">
<h4>Blog</h4>
<h6><a href="index.html">Home</a> ? Blog</h6>
</div>
</div>
</div>
<!--END of header-->
<!--This is the START of the menu-->
<div id="menu-wrapper">
<div id="main-menu">
<ul>
<li><a href="index.html">Home</a></li>
<li><a href="about.html">About</a></li>
<li><a href="portfolio.html">Portfolio</a></li>
<li><a class="selected" href="blog.html">Blog</a></li>
<li><a href="contact.html">Contact</a></li>
</ul>
</div>
<!--This is the START of the footer-->
<div id="footer">
<div id="social-box">
<ul>
<li>
<div class="facebook"><a href=""></a></div>
</li>
<li>
<div class="twitter"><a href=""></a></div>
</li>
<li>
<div class="linkedin"><a href=""></a></div>
</li>
</ul>
</div>
<h6></h6>
</div>
<!--END of footer-->
</div>
<!--END of menu-->
<!--This is the START of the content-->
<div id="content">
<!--This is the START of the blog-->
<div id="blogentries">
I WANT BLOG ENTRIES HERE
</div>
<!--END of blog-->
</div>
<!--END of content-->
</div>
</body>
</html>
[/CODE]
Link to comment
https://www.neowin.net/forum/topic/1069116-help-integrating-phpmysql-with-existing-html-page/Share on other sites
37 answers to this question
Recommended Posts