GingerRobot
-
Posts
4,082 -
Joined
-
Last visited
Posts posted by GingerRobot
-
-
You will need to use javascript for this, not php.
-
You could also use empty:
[code]
if(!empty($_POST['package'])){
switch($_POST['package']){
case '1month':
$month = mktime(0, 0, 0, date("m")+1 , date("d"), date("Y"));
break;
case '2month':
$month = mktime(0, 0, 0, date("m")+2 , date("d"), date("Y"));
break;
case '3month':
$month = mktime(0, 0, 0, date("m")+3 , date("d"), date("Y"));
break;
}
}
[/code] -
There wont be a definitave solution using http referrer - some firewalls do not allow the referrer to be sent and some browers can be configured not to send them.
-
So you want to log someone out if they log in on a differant machine?
I would guess the only way of doing this would be to record the IP used to log in, and on each refresh of the frame check if the current IP being used is the same as the last logged in IP. If its not, log them out. -
Unless you have any php knowledge this is going to be difficult. It will involve the use of a database.
I would suggest looking at this tutorial :
[a href=\"http://www.phpfreaks.com/tutorials/40/0.php\" target=\"_blank\"]http://www.phpfreaks.com/tutorials/40/0.php[/a]
As a basic introduction to php, you will also need the emailing feature used in that.
Copy a field value
in PHP Coding Help
Posted
<script type="text/javascript" language="JavaScript"><!--
function change()
{
document.form.textfield.value = document.form.select.value
}
// --></script>
<FORM ACTION="actionofyourfrom" METHOD="POST" NAME="form">
<SELECT NAME="select" ONCHANGE="change()">
//All your values in your drop down box
</SELECT>
<INPUT TYPE="TEXT" NAME="textfield">
Edit: please note, im no javascript expert. Its largely a mystery to me