Jump to content

Edmhar

Members
  • Posts

    31
  • Joined

  • Last visited

Edmhar's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. Thank you i passed this problem hahaha kindly check my new post simple add and subtract mysql and php
  2. Hello. im gonna ask how i will make this happen. i have a mysql database ( StockItem, in, out, availableitem) add and subraction only assuming that I have value n my StockItem = 50 , in = 0 , out = 0 , availableitem = ( have a computation of stockitem - in & availableitem + out ) so i will have form for ( in ) The IN AND OUT are USERINPUT it will have textbox that will input the value by admin. for example i input in FOR (in) textbox = 10 then click the button process it will update the whole table affecting all the field in that row
  3. how about if i put this in html?
  4. how about if will put this in html?
  5. thanks man your great hahaha I love you No homo! you helping me to finish my Thesis
  6. i want to post if logged in i want to have echo logout link if not logged in want to echo login
  7. the order must not have set value it must be inputed by the admin who in charge in sales. <?php include 'connect.php'; //this item order must be input by officer in charge am i correct? $itemorder = ""; $query ="SELECT * FROM tbl_equipment WHERE Equip_ID ='".$itemid."' AND Equip_name ='".$itemname."' AND EquipVolume = '".$itemstock."' "; query echo $itemname; echo $itemid; echo $itemstock - $itemorder; //for example stock of camera is 15 and a customer rent 5 pcs so in my admin page i will input input the number of order and so the other customer will see after they refresh is 10 pcs ony // It must have effect in my database so im thinking i will use UPDATE but i dont know how to input it in // then if item went down to 0 it will show The item is 0 with UNAVAILBLE ?> <?php $conn_err ='Cant Connect'; $mysql_host = 'localhost'; $mysql_itemid = 'root'; $mysql_db = 'mis'; if (!@mysql_connect($mysql_host, $mysql_itemid)||!@mysql_select_db($mysql_db)) { die($conn_err); } ?> this is my connect.php
  8. you are so good in programming i hope youre like my professor hahaha BTW check this link im doing in my inventory system http://forums.phpfreaks.com/topic/283378-logical-operation-for-php-with-mysql-inventory-system/
  9. Hi guys i want to ask how to get the value of the in the mysql for example i have a equipments like camera so i have tbl_equipments with field of EquipmentID, EquipmentName, NoOfEquip, for example values EquiptmentID : 1001 EquiptmentName: Camera NoOfEquip: 15 So my customer can see if how many available camera from our website EXAMPLE A customer rent a camera for 5 pcs if i refresh the page the remaining camera items is 10 and i that customer back that item item What maybe the code? I have no idea to make this.
  10. nope i using even that cause me loop I use this <?php include '../../core.php'; if($_SESSION['login'] && $_SESSION['type'] === 'ADMINISTRATION'){ ?> <!DOCTYPE html> <html lang="en"> <head> <meta charset="utf-8"> <link rel="stylesheet" type="text/css" href="../css/main.css"/> </head> <body> This is Admin. <a href="../../logout.php">Log Out!</a> </body> </html> <?php }else{ header('Location:Webpage/index.php'); } ?>
  11. Thank you i got this there is some error but so basic so my problem is now is loop when i logged in it go loop
×
×
  • 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.