<?php
$database ='database';
$data ='data';
if (!is_numeric($_REQUEST['capital']) || $_REQUEST['capital'] < 75000)
{
echo "Please enter at least $75,000 for the Capital.";
echo "<br><br>";
}
$sql = "SELECT * FROM fusion_users WHERE user_id = '".$userdata['user_id']."'";
If ($data['strength'] <40 || $data['money'] <75000 ){
echo "You don't qualify to establish a business! you need at least 40 strength and $75,000.";
echo "<br><br>";
}else{
$sql="INSERT INTO companies (founder_username, company_name, capital)
VALUES
('".$userdata['user_name']."', '$_POST[companyname]','$_POST[capital]')";
if (!mysql_query($sql,$con))
{
die('Error: ' . mysql_error());
}
$up="Update fusion_users set money=money-$_POST[capital] where user_id = '".$userdata['user_id']."'";
mysql_query($up) or die("error");
$up="Update fusion_users set strength=strength-40 where user_id = '".$userdata['user_id']."'";
mysql_query($up) or die("error");
}
echo "Congrats! You've just made a new business! You can manage this business through the company control panel";
?>
<?php
echo "Welcome, ".$userdata['user_name']."!";
?>
<BR><BR>
Here you can see all of your accounts, and their details. <Br><br>
<?php
$result = mysql_query("SELECT * FROM bank WHERE founder_username = ".$userdata['user_name']."");
echo "<table border='1'>
<tr>
<th>Account Name</th>
<th>Account Money</th>
<th>Daily Interest</th>
<th>Account loan Amount</th>
<th>Accumlated Iterst. on Crnt. loan</th>
</tr>";while($row = mysql_fetch_array($result))
{
echo "<tr>";
echo "<td>" . $row['account_name'] . "</td>";
echo "<td>" . $row['account_money'] . "</td>";
echo "<td>" . $row['account_daily_interest'] . "</td>";
echo "<td>" . $row['account_loan'] . "</td>";
echo "<td>" . $row['account_loan_interest'] . "</td>";
echo "</tr>";
}
echo "</table>";
?>
<?php
If ($userdata['strength'] <2 || $userdata['money'] <250 ){
echo "You don't qualify to create a bank account! You need at least 2 strength and $250.";
}else{
$sql="INSERT INTO bank (founder_username, account_name) VALUES ('".$userdata['user_name']."', '".$_POST['accountname']."')";
if (!mysql_query($sql))
{
die('Error: ' . mysql_error());
}
}
$up="UPDATE fusion_users set money=money-250 where user_id = '".$userdata['user_id']."'";
mysql_query($up) or die("error");
$up="UPDATE fusion_users set strength=strength-2 where user_id = '".$userdata['user_id']."'";
mysql_query($up) or die("error");
?>
<?php
If ($userdata['strength'] <2 || $userdata['money'] <250 ){
echo "You don't qualify to create a bank account! You need at least 2 strength and $250.";
}else{
$sql="INSERT INTO bank (founder_username, account_name) VALUES ('".$userdata['user_name']."', '".$_POST['accountname']."')";
if (!mysql_query($sql))
{
die('Error: ' . mysql_error());
}
$up="UPDATE fusion_users set money=money-250 where user_id = '".$userdata['user_id']."'";
mysql_query($up) or die("error");
$up="UPDATE fusion_users set strength=strength-2 where user_id = '".$userdata['user_id']."'";
mysql_query($up) or die("error");
}
?>
<?php
If ($userdata['strength'] <2 || $userdata['money'] <250 ){
echo "You don't qualify to create a bank account! You need at least 2 strength and $250.";
}else{
$sql="INSERT INTO bank (founder_username, account_name)
VALUES
('".$userdata['user_name']."', '".$_POST['accountname']."')";
if (!mysql_query($sql))
{
die('Error: ' . mysql_error());
}
$up="UPDATE fusion_users set money=money-250 where user_id = '".$userdata['user_id']."'";
mysql_query($up) or die("error");
$up="UPDATE fusion_users set strength=strength-2 where user_id = '".$userdata['user_id']."'";
mysql_query($up) or die("error");
?>
<?php
$database ='database';
if (!is_numeric($_REQUEST['capital']) || $_REQUEST['capital'] < 75000)
{
echo "Please enter at least $75,000 for the Capital.";
echo "<br><br>";
}
If ($userdata['strength'] <40 || $userdata['money'] <75000 ){
echo "You don't qualify to establish a business! you need at least 40 strength and $75,000.";
}else{
$sql="INSERT INTO companies (founder_username, company_name, capital)
VALUES
('".$userdata['user_name']."', '".$_REQUEST['companyname']."','".$_REQUEST['capital']."')";
if (!mysql_query($sql))
{
die('Error: ' . mysql_error());
}
$up="Update fusion_users set money=money-$_REQUEST[capital] where user_id = '".$userdata['user_id']."'";
mysql_query($up) or die("error");
$up="Update fusion_users set strength=strength-40 where user_id = '".$userdata['user_id']."'";
mysql_query($up) or die("error");
}
echo "Congrats! You've just made a new business! You can manage this business through the company control panel";
?>
Cool! You're now going to Establish a Business.<br><br>
You need atleast $75,000 to establish a company.
<form action="viewpage.php?page_id=26" method="post" name="createenterprise">
Business Name:<br>
<input type="text" name="companyname" maxlength="32" /><br>
Capital (At least $75,000):<br>
<input type="text" name="capital" /><br><br>
<input type="submit" name="makeenterprise" value="Make Business" />
<?php
$database ='database';
if (!is_numeric($_REQUEST['capital']) || $_REQUEST['capital'] < 75000)
{
echo "Please enter at least $75,000 for the Capital.";
echo "<br><br>";
}
If ($userdata['strength'] <40 || $userdata['money'] <75000 ){
echo "You don't qualify to establish a business! you need at least 40 strength and $75,000.";
}else{
$sql="INSERT INTO companies (founder_username, company_name, capital)
VALUES
('".$userdata['user_name']."', '".$_REQUEST['companyname']."','".$_REQUEST['capital']."')";
if (!mysql_query($sql,$con))
{
die('Error: ' . mysql_error());
}
$up="Update fusion_users set money=money-$_POST[capital] where user_id = '".$userdata['user_id']."'";
mysql_query($up) or die("error");
$up="Update fusion_users set strength=strength-40 where user_id = '".$userdata['user_id']."'";
mysql_query($up) or die("error");
}
echo "Congrats! You've just made a new business! You can manage this business through the company control panel";
?>
Notice: Undefined index: capital in /www/oxyhost.com/s/a/l/salesmangame/htdocs/administration/custom_pages.php(72) : eval()'d code on line 6
Please enter at least $75,000 for the Capital.
Notice: Undefined index: companyname in /www/oxyhost.com/s/a/l/salesmangame/htdocs/administration/custom_pages.php(72) : eval()'d code on line 19
Notice: Undefined index: capital in /www/oxyhost.com/s/a/l/salesmangame/htdocs/administration/custom_pages.php(72) : eval()'d code on line 19
Notice: Undefined variable: con in /www/oxyhost.com/s/a/l/salesmangame/htdocs/administration/custom_pages.php(72) : eval()'d code on line 21
Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in /www/oxyhost.com/s/a/l/salesmangame/htdocs/administration/custom_pages.php(72) : eval()'d code on line 21
Error:
<?php
$database ='database';
if (!is_numeric($_REQUEST['capital']) || $_REQUEST['capital'] < 75000)
{
echo "Please enter at least $75,000 for the Capital.";
echo "<br><br>";
}
If ($userdata['strength'] <40 || $userdata['money'] <75000 ){
echo "You don't qualify to establish a business! you need at least 40 strength and $75,000.";
}else{
$sql="INSERT INTO companies (founder_username, company_name, capital)
VALUES
('".$userdata['user_name']."', '".$_REQUEST['companyname']."','".$_REQUEST['capital']."')";
if (!mysql_query($sql,$con))
{
die('Error: ' . mysql_error());
}
$up="Update fusion_users set money=money-$_POST[capital] where user_id = '".$userdata['user_id']."'";
mysql_query($up) or die("error");
$up="Update fusion_users set strength=strength-40 where user_id = '".$userdata['user_id']."'";
mysql_query($up) or die("error");
}
echo "Congrats! You've just made a new business! You can manage this business through the company control panel";
?>
('".$userdata['user_name']."', '$_POST[companyname]','$_POST[capital]')";
('".$userdata['user_name']."', '".$_POST[companyname]."','".$_POST[capital]."')";
Category Forum
Official Core Support - 6Labels
None yet
Statistics
0 participants
Notifications
You are not receiving notifications from this thread.
Related Questions