Well in the database you would store the page name/page ID as well as the actual page in a largetext or memo field. When the page is requested by name/ID you would simply pull it from the database and display it, ie., <a href="page?id=25018">Read more...</a>
ShawnCplus
Code Monkey
1,583 posts since Apr 2005
Reputation Points: 526
Solved Threads: 268
This is a very simple example, but you can build on it:
I am sure you know how get works, but ill put it here anyway, this link sets $_GET['article'] to 1001 on my localhost: http://localhost/testing/test07.php?article=1001
mysql_select_db("testbase") or die(mysql_error());
$query=mysql_query("
SELECT info
FROM articles
WHERE article_id='" . $_GET['article'] . "'");
while($entry=mysql_fetch_array($query))
{
echo $entry['info'];
}
echo "</select>";
?>
If you need further explanation just ask
hooray
Junior Poster in Training
62 posts since Jan 2008
Reputation Points: 11
Solved Threads: 6
yes, but you would have to do that in php as $aid is a php variable, so it would be:
<?php
echo "<a href='template.php?aid=" . $aid . "'>Read more...</a>";
?>
OR
<a href="template.php?aid=<?php echo $aid; ?>">Read more...</a>
This would mean $_GET['aid'] would be equal to $aid
hooray
Junior Poster in Training
62 posts since Jan 2008
Reputation Points: 11
Solved Threads: 6
hooray
Junior Poster in Training
62 posts since Jan 2008
Reputation Points: 11
Solved Threads: 6