2.135 views
Ik heb een php bestand, nu wil ik deze echter koppelen aan een css bestand, hoe doe ik dit? Waar moet ik bv de divs neer zetten?
<?php
en onderaan de php pagina staat dit:
echo '<div>'
echo '<div class="Achtergrond">';
echo 'De Totaalprijs excl. btw bedraagt: '. $totaalprijsexcl .' euro.';
echo 'De Totaalprijs incl. btw bedraagt: ' . $totaalprijsincl .' euro.';
echo '</div>';
echo '</div>';
//dit is beetje omslachtig dat wel.. maar laat even zien hoe je moet kijken
?>
<?php
// Stijl pagina invoegen.
echo '<link href="index.css" rel="stylesheet" type="text/css" />';
$ex_btw = (50 + 70 + 80) * 1.19;
$in_btw = (50 + 70 + 80);
// Div met inhoud
echo '<div class="Achtergrond">';
// Prijs ex btw.
echo 'De Totaalprijs excl. btw bedraagt: '.$ex_btw.' euro.';
// Prijs incl. btw.
echo 'De Totaalprijs incl. btw bedraagt: '.$in_btw.' euro.';
echo '</div>';
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<!-- Content type -->
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<!-- Pagina titel -->
<title>Pagina titel</title>
<!-- Style pagina -->
<link href="Stijl.css" rel="stylesheet" type="text/css" />
</head>
<body>
<?php
$ex_btw = (50 + 70 + 80);
$in_btw = (50 + 70 + 80) * 1.19;
// Div met inhoud
echo '<div class="Achtergrond">';
// Prijs ex btw.
echo 'De Totaalprijs excl. btw bedraagt: '.$ex_btw.' euro.';
// Prijs incl. btw.
echo 'De Totaalprijs incl. btw bedraagt: '.$in_btw.' euro.';
echo '</div>';
?>
</body>
</html>
koen schreef op 18.01.2010 15:55milo, dat is inderdaad netter.
maar niet wat hij vroeg,
hij vroeg puur hoe hij het kon koppellen.
Jij bent zeker ook zo'n eikel die als je wordt gevraagt 'weet je de hoe ik bij de dorpsstraat moet komen' alleen antwoord met 'ja' en doorloopt :)
(ps. je in en ex btw staan verkeerd om :P)