i think i finally solved this anybody.
last time i was getting the wrong results.
Code: <?php
// price of item.
$price="100.00";
//quenity of items.
$quenity="7";
// tax rate.
$tax="17.50";
//discount rate.
$discount="25%";
// monthly payments.
$payments="12";
//total price x queniety.
$total=$price*$quenity;
// add pretax up, divide tax via 100.
$pretax=$tax/100;
//add a 1 to pretax to get the decimal point.
$total_tax=$pretax+1;
//total with out tax.
$total_with_out_tax=$total;
//total with tax.
$total_with_tax=$total*$total_tax;
//total with discount.
$total_with_discount=$total_with_tax-$discount;
//monthly payments.
$monthly_payments=$total_with_tax/$payments;
echo "£".number_format($total_with_discount,2)."";
?>
yeee haaaa, sorry was solved my fault.
Could Someone Please Debug This?
I was wondering if someone could debug this script for me. I realize it's not the tidest script (and probably not the most efficiant in the world) but it was quite late when I wrote it and I can't be
reating a background image
I am building a site in drupal and have a php form in it, due to certain annoyances with module building I need to generate a background image and margin for my form in PHP and, whilst i imagine this
PHP5/Zend 2.0 - Resources
PHP5 Snapshots
ORA-01017: invalid username/password; logon denied
Dear All,
include function being weird?
I have a very simple system to grab an IP outputted by a PHP file.. (for a project I have) but it outputs a 1 at the end!!<form method="post" action="<?php echo
Whats wrong with my query?
I am trying to get this query to show the appropriate ticked vehicle roof height, unless no boxs are ticked then I want it to display all vehicle roof heights. However it doesn't work correctly, for
Multiple PHP errors when clicking a link..and..removing a ghost..
Hi - I have 2 problems with a new website - homeswapvacations.com, which I need help solving.The first problem - In the left column (on all pages) is "Featured Listing" column (in the admin
send message to the java application
Oracle 10g with Windows platform.
PHP switch function help
Hi, I am trying to create a search function for a directory website. On the search function on html page I have a dropdown menu. From this you can select one OF 3 options - shoes, handbags, shoes and
Help If user voted, block them
On my Prayer request site, i let users Click a button to Pray for somone that has posted a pray, i got that all set up but.Code: // connect to db... if ($_GET['id']) { $id = (int) $_GET['id'];