Forum Moderators: coopster
A)
Data exists only on MySQL
All pages are totally built on the fly
Example:
$num=$db->num_rows($result);
$i=0;
while ($i <$num)
{
$img_caption=mysql_result($result,$i,"img_caption");
$dir_name=mysql_result($result,$i,"dir_name");
$img_filename=mysql_result($result,$i,"img_filename");
$price=mysql_result($result,$i,"price");
echo"<tr><td valign='top'> ";
echo"<h1>";$prod_name=mysql_result($result,$i,"prod_name"); echo"$prod_name";
echo" <a href=' "; $link_to_cart=mysql_result($result,$i,"link_to_cart");
etc......
B) I call it semi-dynamic
Is a tpl system OOP oriented
A tpl is copied and written with some data
The result is a page existing in a directory
Looking like:
require_once('../../../../db_class/details.php');
require_once('../../../db_class/db_class.inc.php');
require_once ("../../../classes/tpl_class.php"); // Include the class
$page = new tpl_class ("../../../templates/main_template_prod.inc.php"); // Create an instance.
$content_dir_name .= '';
include "../../../includes/dir_name.inc.php";
$page->SetParameter("DIR_NAME",$content_dir_name);
$content_prod_name .= '';
include "../../../includes/prod_name.inc.php";
$page->SetParameter("PROD_NAME",$content_prod_name);
and so going on....
And last never used yet!
C) Let’s call it almost-static!
(I won’t use it, due to fopen(), if multiple users (non site owner) may login and edit their section)
A tpl is copied and resides in a directory,
with full blown CSS, HTML.
Not any data are pulled from MySQL
Site manager may edit with fopen()…
A page may look like:
<?php
<html>
CSS formatting…
Header
Left col
Main_content
Footer
Where main content could be
aaa cccc ddd <tag1> sss ddd ee <tag2>
to edit it:
Include”GrabEditableSection.inc.php”;
The included() utilizes strops and strlen to find whatever lies in between pre defined tags
$str=”aaa cccc ddd <tag1> sss ddd ee <tag2>”;
$seek=GrabEditableSection($str, $tag1,$tag2);
Then edit $seek
which one would please a "good" bot?
and appear fully clean (in the browser)
ex: <a href='http://www.site.com/category/packages/membership.php'>
I do not use any ?GET
How does a bot know a page is 'dynamic'? May be by it's file extension (eg. .php) - hardly a fair test? May be by the query string: "?id=123"? May be when it revisits the page it's always different? Hhhhmmm, tricky one!
I am under the impression that BOTs would mostly not be able to follow a link to a dynamic page in a case where a link is dynamically generated...
May be if the link was dymanically generated by client-side JavaScript...?