PHP stored within mySQL table
am 23.10.2009 13:56:19 von Ron Piggott--=-vKT9x5avTHlC6r+LtbJb
Content-Type: text/plain
Content-Transfer-Encoding: 7bit
I am working on a shopping cart ... specifically writing about the
delivery time lines.
I thought I would include the information pages (like store policies,
contact us, about us) for my shopping cart within a mysql table.
But I ran into a challenge when I got to the "Delivery time line
details". I would like to use PHP to calculate when the expected
arrival date will be. This means storing the information pages in PHP
code and using the "eval" command.
$one_week = strtotime("+7 days");
$one_week = date('Y-m-d', $one_week);
$two_weeks = strtotime("+14 days");
$two_weeks = date('Y-m-d', $two_weeks);
$six_weeks = strtotime("+42 days");
$six_weeks = date('Y-m-d', $six_weeks);
The specific problem I am not sure how to resolve is with the CSS rules.
I haven't figured out how to resolve the parse error the eval command is
giving me for the following line of code:
echo "
- \r\n";
- To Canada: One Week ($one_week) \r\n";
- To United States: Two Weeks ($two_weeks) \r\n";
- To Overseas: Up To Six Weeks ($six_weeks) \r\n";
The rest of what I am write for the delivery looks like this:
===
echo "
Delivery Details
\r\n";echo "
The following are our approximate delivery time
lines:
echo "
- \r\n";
echo "
echo "
echo "
echo "
===
Does anyone have a suggestion for me? Should I be putting the store
policies into their own files instead of using the database and the eval
command? How have you approached similar situations?
Ron
--=-vKT9x5avTHlC6r+LtbJb--