Jump to content

dhrups

New Members
  • Posts

    6
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

dhrups's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. hi. thanks for ur help. i made the change to my sql statement, and now i am getting the following error: Query error: SELECT category, model_number, quantity FROM models WHERE model_number=\'. $row[\'model_number\']. \' You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near '\'. $row[\'model_number\']. \'' at line 1 is there anything else wrong with my code? like i sed i am using the primary key to be model_number which has a type varchar, as it contains both numbers and letters in it. could that be the problem.
  2. I am updating my table in the database, I have written the code, and keep getting the following error: Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in C:\Apache2\Apache2\htdocs\SCS\edit_customers.php on line 166 i have commented the line number 166 in bold. can some one pls let me know if i am doing something wrong? (the primary key is model_number and the type is varchar) but i dont think this shud matter?? Script edit_model.php <? php require_once("config.php); ?> <? function escape_data($data){ if(ini_get('magic_quotes_gpc')){ $data = stripslashes($data); } if (function_exists('mysql_real_escape_string')){ global $connection; $data = mysql_real_escape_string(trim($data), $connection); } else { $data = mysql_escape_string(trim($data)); } return $data; } if ((isset($_GET['model_number']))){ ($id = $_GET['model_number']); } elseif ((isset($_POST['model_number']))){ ($id = $_POST['model_number']); } else { echo '<h1 model_number="mainhead">PAGE ERROR</h1> <p class="error">This page has been accessed in errorpuj.</p><p><br/><br/></p>'; exit(); } if (isset($_POST['submitted'])){ $errors = array(); //check for first name if(empty($_POST['category'])){ $error[] = 'You forgot to enter the category.'; } else { $fn = escape_data($_POST['category']); } if(empty($_POST['quantity'])){ $error[] = 'You forgot to enter the quantity.'; } else { $e = escape_data($_POST['quantity']); } if(empty($errors)) { $query = "SELECT model_number FROM models WHERE quantity= '$e' AND model_number != $id"; $result = mysql_query($query); if(mysql_num_rows($result)==0){ $query = "UPDATE models SET model_number='$id', category='$fn', quantity='$e' WHERE model_number=$id"; $result = @mysql_query ($query); if (mysql_affected_rows() == 1) { echo '<p> The machine detail has been edited.<p>'; } else { echo '<h1 model_number="mainhead"> System Error</h1> <p class = "error" > The machine detail could not be edited due to a system error.</p>'; echo '<p>' . mysql_error() . '<br/><br/> Query: ' . $query . '<p>'; exit(); } } else { echo '<h1 model_number="mainhead">Error!</h1> <p class="error"> The quantity had already been registered.</p>'; } } else { echo '<h1 model_number="mainhead">Error!</h1> <p class="error"> The following error(s) occured:<br/>'; foreach ($errors as $msg){ echo " - $msg<br/>\n"; } echo '</p><p>Please Try Again. </p><p><br/></p>'; } } $query = "SELECT category, model_number, quantity FROM models WHERE model_number=$id"; $result = @mysql_query ($query); if (mysql_num_rows($result) ==1){ [/u] [b] //this is line no 166[/b] $row = mysql_fetch_array ($result, MYSQL_NUM); echo '<h2> Edit Customer </h2> <form name="edit_cust_details.php" action = "edit_model.php" method = "post"> <p>Category: <input type="text" name ="category" size="15" maxlength="15" value="' .$row[0] . '"/></p> <p>Model_number: <input type="text" name ="model_number" size="15" maxlength="15" value="' .$row[1] . '"/></p> <p>Quantity: <input type="text" name ="quantity" size="15" maxlength="15" value="' .$row[2] . '"/></p> <p><input type="submit" name="submit" value="Submit" /></p> <input type="hidden" name="submitted" value="TRUE" /> <input type="hidden" name="model_number" value="' . $id . '" /> </form>'; } else { echo '<h1 model_number="mainhead">Page Error</h1> <p class="error">This page has been accessed in error.</p><p><br/><br/></p>'; } mysql_close(); ?>
  3. can anyone help me out? I am trying to output a text or pop up box or something of the sort, to notify a user of the system, when the stock level reaches a minimum level. currently i am doing this manually, but i would like to generate this message automatically. the code used for the manual notification is: [b] machine_stock_level.php[/b] <?php $result = mysql_query("SELECT category, model_number, quantity FROM main_stock WHERE quantity <= 10 ORDER BY category"); $row = mysql_numrows($result); $i=0; while ($i < $row) { $Category = mysql_result($result,$i,"category"); $Model_number = mysql_result($result,$i,"model_number"); $Quantity = mysql_result($result,$i,"quantity"); ?> <tr> <td width="276" align="center" style="border-left-style: solid; border-left-width: 1; border-bottom-style: solid; border-bottom-width: 1" height="19"><b><font face="Arial, Helvetica, sans-serif"><? echo $Category; ?></font></b>&nbsp;</td> <td width="200" align="center" style="border-left-style: solid; border-left-width: 1; border-bottom-style: solid; border-bottom-width: 1" height="19"><b><font face="Arial, Helvetica, sans-serif"><? echo $Model_number; ?></font></b>&nbsp;</td> <td width="201" align="center" style="border-right-style: solid; border-right-width: 1; border-bottom-style: solid; border-bottom-width: 1" height="19"><b><font face="Arial, Helvetica, sans-serif"><? echo $Quantity; ?></font></b>&nbsp;</td> </tr> <? $i++; } ?> </tr> </table>
  4. Hi, first of all thanks to Ray and Ken for helping me with my previous problem. This problem is abit different. I am trying to update a table in the database. My table consists of the following feilds: category, model_number, description, price and quantity. Now i am trying to update the quantity for each row in the table. The model number is a primary key and it is varchar as i have to use numbers and letters as e.g 9047 NB etc, and some of the model numbers are just plain numbers e.g 9554. I have done the following scripts but its not working. i have one file called view_all_models.php where i am viewing whats on the database and i have a hyperlink called Edit next to it which takes me to the edit_model.php page and lets me input the new details. Could someone please check it and let me know whats wrong? any better solutions? [b]file1: view_all_models.php[/b] ------------------------------- <?php require_once("config.php"); ?> <html> <head> <title><?php echo "Machine Details" ?></title> <head> <body> <table border="1" width="100%" height="226"> <tr> <td width="22%" height="91" bgcolor="#0099FF">&nbsp; </td> <td width="78%" height="91" bgcolor="#66CCFF" ALIGN=CENTER>&nbsp; <H1> View MAchine Details </H1> <? $query = "SELECT category, model_number, price, quantity FROM models"; $result = mysql_query ($query); $num = mysql_num_rows($result); if ($num > 0){ echo "<p>There are currently $num stored machine details. </p>\n"; echo '<table align = "center" border = "1" cellspacing = "0" cellpadding = "5"> <tr> <td align="left"><b>Edit</b></td> <td align="left"><b>Category</b></td> <td align="left"><b>Model Number</b></td> <td align="left"><b>Price</b></td> <td align="left"><b>Quantity</b></td> </tr> '; while ($row = mysql_fetch_array($result, MYSQL_ASSOC)){ echo ' <tr> <td align="left"><a href="edit_model.php?model_number='. $row['model_number']. '">Edit</a></td> <td align="left">'. $row['category']. '</td> <td align="left">'. $row['model_number']. '</td> <td align="left">'. $row['price']. '</td> <td align="left">'. $row['quantity']. '</td> </tr> '; } echo '</table>'; mysql_free_result($result); } else { echo '<p class = "error">There are no stored machines.</p>'; } mysql_close(); ?> <p>&nbsp;</p> <p>&nbsp;</p> <p>&nbsp;</p> <p>&nbsp;</p> <p>&nbsp;</p> <p>&nbsp;</p> <p>&nbsp;</p> </TABLE> <p>&nbsp;</p> <p>&nbsp;</p> <p>&nbsp;</p> <p>&nbsp;</p> <p>&nbsp;</p> <p>&nbsp;</p> <p>&nbsp;</p> </form> </td> </table> </body> </html> --------------------------------------------------------------------------------------------------------------------- [b]file2: edit_model.php[/b] -------------------------------- <?php require_once("config.php"); $connection = @mysql_connect($db_host, $db_user, $db_password) or die("oops! error connecting"); mysql_select_db($db, $connection); ?> <html> <head> <title><?php echo "Edit Machine Details" ?></title> <head> <body> <table border="1" width="100%" height="226"> <tr> <td width="22%" height="91" bgcolor="#0099FF">&nbsp; <td width="78%" height="91" bgcolor="#66CCFF" ALIGN=CENTER>&nbsp; <H1> Edit Machine Details </H1> </td> </tr> <? function escape_data($data){ if(ini_get('magic_quotes_gpc')){ $data = stripslashes($data); } if (function_exists('mysql_real_escape_string')){ global $connection; $data = mysql_real_escape_string(trim($data), $connection); } else { $data = mysql_escape_string(trim($data)); } return $data; } if ((isset($_GET['model_number']))){ ($id = $_GET['model_number']); } elseif ((isset($_POST['model_number']))){ ($id = $_POST['model_number']); } else { echo '<h1 model_number="mainhead">PAGE ERROR</h1> <p class="error">This page has been accessed in errorpuj.</p><p><br/><br/></p>'; exit(); } if (isset($_POST['submitted'])){ $errors = array(); //check for first name if(empty($_POST['category'])){ $error[] = 'You forgot to enter the category.'; } else { $fn = escape_data($_POST['category']); } if(empty($_POST['quantity'])){ $error[] = 'You forgot to enter the quantity.'; } else { $e = escape_data($_POST['quantity']); } if(empty($errors)) { $query = "SELECT model_number FROM models WHERE quantity= '$e' AND model_number != $id"; $result = mysql_query($query); if(mysql_num_rows($result)==0){ $query = "UPDATE models SET model_number='$id', category='$fn', quantity='$e' WHERE model_number=$id"; $result = @mysql_query ($query); if (mysql_affected_rows() == 1) { echo '<p> The machine detail has been edited.<p>'; } else { echo '<h1 model_number="mainhead"> System Error</h1> <p class = "error" > The machine detail could not be edited due to a system error.</p>'; echo '<p>' . mysql_error() . '<br/><br/> Query: ' . $query . '<p>'; exit(); } } else { echo '<h1 model_number="mainhead">Error!</h1> <p class="error"> The quantity had already been registered.</p>'; } } else { echo '<h1 model_number="mainhead">Error!</h1> <p class="error"> The following error(s) occured:<br/>'; foreach ($errors as $msg){ echo " - $msg<br/>\n"; } echo '</p><p>Please Try Again. </p><p><br/></p>'; } } $query = "SELECT category, model_number, quantity FROM models WHERE model_number=$id"; $result = @mysql_query ($query); if (mysql_num_rows($result) ==1){ $row = mysql_fetch_array ($result, MYSQL_NUM); echo '<h2> Edit Customer </h2> <form name="edit_cust_details.php" action = "edit_model.php" method = "post"> <p>Category: <input type="text" name ="category" size="15" maxlength="15" value="' .$row[0] . '"/></p> <p>Model_number: <input type="text" name ="model_number" size="15" maxlength="15" value="' .$row[1] . '"/></p> <p>Quantity: <input type="text" name ="quantity" size="15" maxlength="15" value="' .$row[2] . '"/></p> <p><input type="submit" name="submit" value="Submit" /></p> <input type="hidden" name="submitted" value="TRUE" /> <input type="hidden" name="model_number" value="' . $id . '" /> </form>'; } else { echo '<h1 model_number="mainhead">Page Error</h1> <p class="error">This page has been accessed in error.</p><p><br/><br/></p>'; } mysql_close(); ?> <p>&nbsp;</p> <p>&nbsp;</p> <p>&nbsp;</p> <p>&nbsp;</p> <p>&nbsp;</p> <p>&nbsp;</p> <p>&nbsp;</p> <p>&nbsp;</p> <p>&nbsp;</p> <p>&nbsp;</p> <p>&nbsp;</p> </form> </td> </table> </body> </html>
  5. Hi, i am trying to add up the total for my code. i have used the following code to multiply price with quantity and display it as total. I am not storing the values in total on the database. I need to add the total up. ie. i have 2 rows with to different totals, for e.g total 200 200 final Total: i want ti fill in that final total. <?php //start of php coding and running mySQL queries. $result = mysql_query("SELECT * FROM accessories ORDER BY category"); $row = mysql_numrows($result); $i=0; while ($i < $row) { $Category = mysql_result($result,$i,"category"); $Description = mysql_result($result,$i,"description"); $Price = mysql_result($result,$i,"price"); $Quantity = mysql_result($result,$i,"quantity"); $Total = ($Price * $Quantity); ?> <tr> <td width="154" align="center" style="border-style: solid; border-width: 1"><b><font face="Arial, Helvetica, sans-serif"><? echo $Category; ?></font>&nbsp;</td> <td width="321" align="left" style="border-style: solid; border-width: 1"><b><font face="Arial, Helvetica, sans-serif"><? echo $Description; ?></font></b>&nbsp;</td> <td width="157" align="center" style="border-style: solid; border-width: 1"><font face="Arial, Helvetica, sans-serif"><? echo number_format($Price, 2); ?></font>&nbsp;</td> <td width="104" align="center" style="border-style: solid; border-width: 1"><font face="Arial, Helvetica, sans-serif"><? echo $Quantity; ?></font>&nbsp;</td> <td width="159" align="center" style="border-style: solid; border-width: 1"><b><font face="Arial, Helvetica, sans-serif"><? echo number_format($Total, 2); ?></font></b>&nbsp;</td> </tr> <? $i++; } ?> </tr>
  6. I am trying to use sessions but it doesnt seem to work. Can someone please help me. [b]file1: scs_admin.php[/b] <html> <head> <title>Administrator Page</title> </head> <body> <?php require_once("config.php"); ?> <? session_start(); $u_user_id = $_POST["user_id"]; $u_password = $_POST["password"]; $query = "SELECT * FROM users WHERE user_id='$u_user_id' AND password='$u_password'"; $result = mysql_query($query, $connection) or die(mysql_error()); if(mysql_num_rows($result)=="1") { $_SESSION[user_id]=$_POST[user_id] && $_SESSION[password]=$_POST[password]; ?> <table border="0" width="100%" height="1"> <tr> <td width="15%" rowspan="3" height="1" bgcolor="#3399FF" valign="top"> <table border="1" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#FFFFFF" width="100%" id="AutoNumber2"> <tr> <td width="100%"> <p align="center"><font color="#FFFFFF"><b><a href="home.php"> <font color="#FFFFFF">HOME</font></a></b></font></td> </tr> </table> <p align="center"> <p align="center"> <p align="center"> <p align="center"> <p align="center"> <p align="center"> <p align="center"> <p align="center"> <p align="center"> <p align="center"> <p align="center"> <table border="1" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#FFFFFF" width="100%" id="AutoNumber3"> <tr> <td width="100%"> <p align="center"><font color="#FFFFFF"><b><a href="logout.php"> <font color="#FFFFFF">LOG OUT</font></a></b></font></td> </tr> </table> </td> </tr> <tr> <td width="85%" height="1" bgcolor="#66CCFF"> <h3 align="center"><font size="6" color="#FFFFFF"> <span style="background-color: #0000FF">INTERCROSS AGENCIES LTD</span></font></h3> <h3 align="center"><span style="background-color: #00FF00">STOCK CONTROL SYSTEM</span></h3> <hr size="1" color="#000000" noshade> </td> </tr> <tr> <td width="85%" height="10" bgcolor="#C0C0C0"><b> </b><p align="center"> <font color="#FF0000"><b><u><font size="4">ADMINISTRATOR PAGE</font></u></b></font><font size="4"> </font></p> <p> </p> <p><b>PLEASE SELECT THE APPROPRIATE OPTIONS:</b></p> <form method="POST" action="scs_admin.php"> <table border="3" cellpadding="0" cellspacing="0" style="border-style:double; border-width:3; border-collapse: collapse; " bordercolor="#111111" width="100%" id="AutoNumber1" height="157"> <tr> <td width="21%" style="border-style: double; border-width: 3; ; padding-left:4; padding-right:4; padding-top:1; padding-bottom:1" height="43" align="center"> <p align="center"> <a href="create_user.php"> <input type="button" value="CREATE USER" name="B3" style="font-weight: bold"></a></td> <td width="20%" style="border-style: double; border-width: 3; ; padding-left:4; padding-right:4; padding-top:1; padding-bottom:1" height="43" align="center"> <p align="center"><a href="scs_delete_user.php"> <input type="button" value="DELETE USER" name="B7" style="color: #FF0000; font-weight: bold"></a></td> <td width="34%" style="border-style: double; border-width: 3; ; padding-left:4; padding-right:4; padding-top:1; padding-bottom:1" height="43" colspan="2" align="center"> <p align="center"><a href="search_models.php"> <input type="button" value="SEARCH MACHINES" name="B9" style="font-weight: bold"></a></td> <td width="25%" style="border-style: double; border-width: 3; ; padding-left:4; padding-right:4; padding-top:1; padding-bottom:1" height="43" colspan="2" align="center"> <p align="center"><a href="scs_views.php"> <input type="button" value="SEARCH SPARES" name="B10" style="font-weight: bold"></a></td> </tr> <tr> <td width="41%" style="border-style: double; border-width: 3; ; padding-left:4; padding-right:4; padding-top:1; padding-bottom:1" height="35" colspan="2" align="center"> <p align="center"> </td> <td width="59%" style="border-style: double; border-width: 3; ; padding-left:4; padding-right:4; padding-top:1; padding-bottom:1" height="35" colspan="4" align="center"> </td> </tr> <tr> <td width="21%" style="border-style: double; border-width: 3; ; padding-left:4; padding-right:4; padding-top:1; padding-bottom:1" height="39" align="center"> <p align="center"> <a href="stock_page.php"> <input type="button" value="STOCK LEVELS" name="B4" style="color: #0000FF; font-weight: bold"></a></td> <td width="20%" style="border-style: double; border-width: 3; ; padding-left:4; padding-right:4; padding-top:1; padding-bottom:1" height="39" align="center"> <p align="center"> <a href="create_report.php"> <input type="button" value="REPORTS" name="B8" style="color: #0000FF; font-weight: bold"></a></td> <td width="20%" style="border-style: double; border-width: 3; ; padding-left:4; padding-right:4; padding-top:1; padding-bottom:1" height="39" align="center"> <a href="add_machines.php"> <input type="button" value="ADD MACHINES" name="B11" style="font-weight: bold"></a></td> <td width="20%" style="border-style: double; border-width: 3; ; padding-left:4; padding-right:4; padding-top:1; padding-bottom:1" height="39" align="center" colspan="2"> <a href="add_spares.php"> <input type="button" value="ADD SPARES" name="B12" style="font-weight: bold"></a></td> <td width="19%" style="border-style: double; border-width: 3; ; padding-left:4; padding-right:4; padding-top:1; padding-bottom:1" height="39" align="center"> <a href="add_accessories.php"> <input type="button" value="ADD ACCESSORIES" name="B13" style="font-weight: bold"></a></td> </tr> <tr> <td width="41%" style="border-style: double; border-width: 3; ; padding-left:4; padding-right:4; padding-top:1; padding-bottom:1" height="32" colspan="2" align="center"> </td> <td width="59%" style="border-style: double; border-width: 3; ; padding-left:4; padding-right:4; padding-top:1; padding-bottom:1" height="32" align="center" colspan="4"> </td> </tr> <tr> <td width="41%" style="border-style: double; border-width: 3; ; padding-left:4; padding-right:4; padding-top:1; padding-bottom:1" height="32" colspan="2" align="center"> <p align="center"> </td> <td width="59%" style="border-style: double; border-width: 3; ; padding-left:4; padding-right:4; padding-top:1; padding-bottom:1" height="32" align="center" colspan="4"> <p><a href="delete_stock.php"> <input type="button" value="DELETE STOCK" name="B14" style="font-weight: bold"></a></td> </tr> </table> <p> </p> </form> <p> </p> <p> </p> <p></p> <hr size="1" color="#000000" noshade> </td> </tr> </table> <? } else{ ?> <table border="0" width="100%" height="1"> <tr> <td width="13%" rowspan="2" height="1" bgcolor="#3399FF" valign="top"> <table border="1" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#FFFFFF" width="100%" id="AutoNumber4"> <tr> <td width="100%"> <p align="center"><font color="#FFFFFF"><b><a href="home.php"> <font color="#FFFFFF">HOME</font></a></b></font></td> </tr> </table> <p align="center"> <p align="center"> <p align="center"> <p align="center"> <p align="center"> <p align="center"> <p align="center"> <table border="1" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#FFFFFF" width="100%" id="AutoNumber5"> <tr> <td width="100%"> <p align="center"><font color="#FFFFFF"><b><a href="logout.php"> <font color="#FFFFFF">LOG OUT</font></a></b></font></td> </tr> </table> </td> </tr> <tr> <td width="87%" height="1" bgcolor="#C0C0C0"> <h3 align="center"><span style="background-color: #00FF00">LOG IN FAILED!!!!!!</span></h3> <p align="center">Wrong User Id or Password supplied.</p> <p align="center">Please Try Again!<p align="center"> <a href="admin_login.php"><span style="background-color: #FFFF00"> <font color="#000000">Administrator Log In</font></span></a></tr> </table> <? } ?> </body> </html> --------------------------------------- [u][b]File 2 : add_page.php[/b] [/u] <?php require_once("config.php"); session_start(); if(!isset($_SESSION[user_id])) { echo "<p><center>Please login to view this page.</p><p> </p> Please wait... You will automatically be redirected back to the login page"; echo "<META HTTP-EQUIV=Refresh CONTENT='3; URL=home.php'>"; } else { } ?> <html> <head> <title>Staff Page</title> </head> <body> <table border="0" width="100%" height="1"> <tr> <td width="15%" rowspan="3" height="1" bgcolor="#3399FF" valign="top"> <table border="1" cellspacing="1" width="100%" id="AutoNumber3"> <tr> <td width="100%" align="center"> <b><font color="#FFFFFF"><a href="home.php"> <font color="#FFFFFF">HOME</font></a></font></b></td> </tr> <tr> <td width="100%" align="center"> <font color="#FFFFFF"><b><a href="scs_staff.php"> <font color="#FFFFFF">BACK</font></a></b></font></td> </tr> <tr> <td width="100%"> <p align="center"> </td> </tr> </table> <p align="center"> <p align="center"> <p align="center"> <p align="center"> <p align="center"> <p align="center"> <p align="center"> <p align="center"> <p align="center"> <table border="1" cellspacing="1" width="100%" id="AutoNumber2"> <tr> <td width="100%"> <p align="center"><b><font color="#FFFFFF"><a href="logout.php"> <font color="#FFFFFF">LOG OUT</font></a></font></b></td> </tr> </table> </td> </tr> <tr> <td width="85%" height="1" bgcolor="#66CCFF"> <h3 align="center"><font size="6" color="#FFFFFF"> <span style="background-color: #0000FF">INTERCROSS AGENCIES LTD</span></font></h3> <h3 align="center"><span style="background-color: #00FF00">STOCK CONTROL SYSTEM</span></h3> <hr size="1" color="#000000" noshade> </td> </tr> <tr> <td width="85%" height="10" bgcolor="#C0C0C0"><b> </b><p align="center"> <u><font size="4" color="#FF0000"><b>ADD PAGE</b></font></u></p> <p><b>SELECT OPTIONS:</b></p> <form method="POST" action="scs_staff.php"> <table border="1" cellspacing="1" width="100%" id="AutoNumber1" height="53"> <tr> <td width="25%" height="48" align="center"> <a href="add_machines.php"> <input type="button" value="ADD MACHINES" name="B1" style="font-weight: bold"></a></td> <td width="25%" height="48" align="center"> <a href="add_spares.php"> <input type="button" value="ADD SPARES" name="B2" style="font-weight: bold"></a></td> <td width="25%" height="48" align="center"> <a href="add_accessories.php"> <input type="button" value="ADD ACCESSORIES" name="B3" style="font-weight: bold"></a></td> </tr> </table> <p> </p> <p> </p> </form> <p> </p> <p></p> <hr size="1" color="#000000" noshade> </td> </tr> </table> </body> </html>
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.