I have some ph I have posted below and would like to add the stripslash function to it but dont know where to start
function writer($value)
{
$fp = fopen ($this->filename,"w");
fwrite($fp,$value);
fclose($fp);
}
As ususal all help much appreciated
Rob
Works like dream.. thanks one last questio I have tried adding it into this and it just disables it..
<script>document.write( (($data[15]*100) / (2.54)) / 100 );</script> Again would like no more than 2 decimal places
$data[15] is a cariable replaced by the database
Cheers
Rob
Hi Anyone (Dave)
have one last question, the script above works like a dream however some numbers have 6 decimal places after them, how would I limit this to 2 decimal places?
I have tried with some spipets I have seen to do this but it disables the funcyions so I am sure they are not going in...
Hi Dave
Works superb, when I see a script like this I can see how it works, I am just not advanced enough yet to actually write one on my own.
every time I post in this forum I get great help.
Cheers
Rob
Dave
You got it I never thought to put the form tags around it :)
How would I use this to have 5 radio buttons that are increased by 17% 34% 51% 68% 85% can I load more than one form IE
document.forms[0].
document.forms[1].
document.forms[2]. etc?
cLFlaVA
Can I just change the...
Hi Dan
Thanks, I used the value 500 as an example to show a figure sorry.
I should have said this will be a dynamic page and 500 will be replaced by a value from a database.
Hnce the need for some javascript to give some alternative price options.
Cheers
Rob
I need to do some calculations in a form when a form loads so I would think onload is the best way to make this happen?
I have tried the following.
<BODY onLoad="document.forms[0].Price.value=( ((500) / (100)) * 17 + 500 );">
<input type="radio" value="" checked name="Price">
But it gives an...
Hi
Thanks for the replies to my last post, I have another small script problem. I am using the script below to add 2 numbers
<script>document.write(24.99+2.99);</script>
when I add some numbers such as the ones in the example I get about 12 numbers after the decimal point, how can I force...
Hi
I have a small javascript that adds 2 form fields, however when I add decimal numbers it only adds the integers rather than the whole decimal number. Any suggestions greatly welcomed.
Script is below.
Cheers
Rob
<script language="JAVASCRIPT">
<!--
function addTWD() {...
Hi,
Im pretty new to PHP, however I have a form that submits data to a mysql database, I would like to specify the minimum amount of characters that have entered into one field before the form can be submited, If any one can show me in simple terms I would be very grateful.
Cheers
Rob
Hi I am using a small cgi program to open a flat data file then go through the results and display only results that are between two values in a field.
I have pasted the part of the script that I am using to do this below:
The field I am trying to use tha value of is $price, my problem is that...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.