TAXI FARE CALCULATE
Moderator: General Moderators
TAXI FARE CALCULATE
i have made a mistake...
sorry...
sorry...
Last edited by redskin on Mon Oct 01, 2007 12:57 pm, edited 4 times in total.
- aceconcepts
- DevNet Resident
- Posts: 1424
- Joined: Mon Feb 06, 2006 11:26 am
- Location: London
When you're "echoing" HTML within PHP you need to use backslashes.
i.e.
Also, post you PHP code with the
i.e.
Code: Select all
echo"<select name=\"selectList\">";Code: Select all
tags provided.feyd | Please use
BUT IT STILL SHOWS THE SAME PROBLEM, ANY IDEA?
feyd | Please use
Code: Select all
,Code: Select all
and [syntax="..."] tags where appropriate when posting code. Your post has been edited to reflect how we'd like it posted. Please read: [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url] to learn how to do it too.[/color]
PHP Code;Code: Select all
<?
echo '<form action="'. $_SERVER['PHP_SELF'] .'" method="post">
Select your destiny:<select name=\"city\">'; //I HAVE MODIFIED
foreach($city_array AS $city => $km) {
echo '<option value="'. $city .'">'. $city ."</option>\n";
}
echo '</select><br />
Select total person:<select name="\persons\">'; //I HAVE MODIFIED
for($i=1;$i <= $max_persons; $i++) {
echo'<option value="'. $i .'">'. $i ."</option>\n";
}
echo '</select><br />
Select between stops:<select name="\betweenstop\"><option value="0">No</option>';
for($i=1;$i <= $max_stop; $i++) {
echo'<option value="'. $i .'">'. $i ."</option>\n";
}
echo '</select><br />
<input type="submit" value="Calculate" name="submit" />
</form>';
}
?>feyd | Please use
Code: Select all
,Code: Select all
and [syntax="..."] tags where appropriate when posting code. Your post has been edited to reflect how we'd like it posted. Please read: [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url] to learn how to do it too.[/color]Fare Calculate okay
Thanks for your reply...
Now after calculating the price (one way price)
i would like to have a radio button for return(2 ways)
(de formula is totalprice*2-5% discount)
this is de scription which i have.
How to make it?
Now after calculating the price (one way price)
i would like to have a radio button for return(2 ways)
(de formula is totalprice*2-5% discount)
this is de scription which i have.
How to make it?
Last edited by redskin on Tue Mar 31, 2009 6:04 am, edited 3 times in total.
insert the fare calculated result in an orderform
Dear friends...
i wonder how to add the calculated fare in an bookingform?
i dont get throught with it becouse the script is using echo.
anyone knows? perhaps a little sample...
thanks
i wonder how to add the calculated fare in an bookingform?
i dont get throught with it becouse the script is using echo.
anyone knows? perhaps a little sample...
thanks