Jump to content

markbett

Members
  • Posts

    133
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

markbett's Achievements

Member

Member (2/5)

0

Reputation

  1. ok lets try this approach,,, what are you expecting to have happen and what is actually happening??
  2. I am looking to impliment a digital maping system similar to google maps where I can take floorplans of my company and map assets to certain locations and search for them after. like google-maps meets an office people-finder so that when you are looking for printer 23-541-a you can just put it in the interface and it will bring up the map of where the asset is in the company.... I ahve been looking for a tutorial on creating something like this or an existing product but have had no luck... can someone point me in the right direction
  3. where (((scf_mem_id={$R}) and (scf_frnd_id={$social_mem_id}) OR ((scf_mem_id={$R}) and (scf_frnd_id={$social_mem_id} )) The section before and after teh OR are the same cause i dont understand what you are doing but that will work when you get the right stuff after the or
  4. it in the LIMIT command and when you choose which record to start with... Definition: Limit is used to limit your MySQL query results to those that fall within a specified range. You can use it to show the first X number of results, or to show a range from X - Y results. It is phrased as Limit X, Y and included at the end of your query. X is the starting point (remember the first record is 0) and Y is the duration (how many records to display). Also Known As: Range Results Examples: SELECT * FROM `your_table` LIMIT 0, 10 This will display the first 10 results from the database. SELECT * FROM `your_table` LIMIT 5, 5 This will show records 6, 7, 8, 9, and 10
  5. i looked through the php manual and i dont see anything indicating that register globals results in session variables overwriting non session... anyone
  6. ok the code on that page now looks somethign like this: [code]<? var_dump($_SESSION); echo "<hr>"; //determien the event hosts name $sql = mysql_query("SELECT first_name, last_name, email_address AS host_email FROM users WHERE id ='$event_host'") //id ='15'")// or die (mysql_error()); if(!$sql){         echo 'Error getting determining event host: '.               mysql_error();       } else { while($row = mysql_fetch_array($sql)){ stripslashes(extract($row)); $event_host = $first_name.' '.$last_name; } } var_dump($_SESSION); ?>[/code] you can see THAT is the section of code that is causeing the session variable  to be RESET WHY??? my login script ONLY should set those if the login isnt set to being true [code] if($_SESSION['login'] != TRUE){ echo "i ran again cause i suck"; $username = mysql_real_escape_string($_POST['username']); $password = mysql_real_escape_string($_POST['password']);     $validate = mysql_query("SELECT * FROM users                           WHERE username='$username'                           AND password = md5('$password')                           AND verified='1'  AND disabled='0'                           ") or die (mysql_error());                             if(mysql_num_rows($validate) == 1){       while($row = mysql_fetch_assoc($validate)){         $_SESSION['login'] = true;         $_SESSION['userid'] = $row['id'];         $_SESSION['first_name'] = $row['first_name'];         $_SESSION['last_name']  = $row['last_name']; [/code] wtf is going on.....
  7. ok i dump varibles on the page throughout it and it changes them from after teh session stuff is done to when the data is being put in that page... now WHY WHY WHY
  8. you name the form elements  whatever you like (term1 term2) then when you process the form you get your $_POST['term1'] clean it for sql injections then set it to a variable $_post['term1']=$term1 etc etc then you can use them in your query sql=("SELECT * FROM blue WHERE something=".$term1." OR ".#term2") blah blah
  9. what is in the variable morerow?  is it a number...  where is it being set?
  10. thats what i did **see reply 17**
  11. you need to clarify your question... forms work in php th same way they work in other languages... your form action calls teh script that process teh form form elements are variables etc...
  12. whats also puzzling is that it changes those variable but it doesnt change like teh email address...
×
×
  • 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.