Jump to content

mofm

Members
  • Posts

    41
  • Joined

  • Last visited

    Never

Everything posted by mofm

  1. Great thanks that worked
  2. make sure ur password coloum in ur table will allow enough charters to enter it.
  3. does anyone have any ideas on whats wrong ... i don't get any errors the page returns blank and $album_id is empty <?php require '../includes/functions.php'; require '../includes/connect.php'; require '../includes/settings.php'; session_start(); /************************************************************ Adjust the headers... ************************************************************/ header("Expires: Thu, 17 May 2001 10:17:17 GMT"); // Date in the past header ("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT"); // always modified header ("Cache-Control: no-cache, must-revalidate"); // HTTP/1.1 header ("Pragma: no-cache"); // HTTP/1.0 if(empty($album_id)) { $albums_query = "SELECT * FROM albums"; if($albums_result=mysql_query($albums_query)) { $counter=0; $albums=array(); while($albums_array=mysql_fetch_array($albums_result)) { $albums[$counter]['title']=$albums_array['name']; $albums[$counter]['description']=$albums_array['description']; $albums[$counter]['user']=$albums_array['userid']; $albums[$counter]['image']=$albums_array['image']; $albums[$counter]['user']=$albums_array['user']; $albums[$counter]['date']=$albums_array['date']; $albums[$counter]['id']=$albums_array['id']; $counter+1; } $counter2=0; echo"<TR>"; while ($counter2<$counter) { if ($counter2%4==0) { echo"</TR><TR>"; } echo "<td colspan=\"3\">".$albums[$counter2]['title']."</td>"; echo "<td colspan=\"3\">".$albums[$counter2]['title']."</td>"; $counter2+1; } echo "</TR>"; }else{ echo "gggg"; } } thanks mofm
  4. ok if your trying to get the email address and subject of an email in someones email inbox when they view the email, this cannot be done unless you have access to the server. if you want to make like a confirmation link similar to what is used on forums thne this can be done easly .... mofm
  5. Try this .it should work <?php $passwordText = "samplepassword"; $encryptedPass = md5($passwordText); $passwordFromLogin = $_POST['passwrd']; $passwordEncrypted = md5($passwordFromLogin); echo "Your pass :$encryptedPass<BR>Entered pass:$passwordEncrypted"; //Remove this line when ur done testing if ($passwordEncrypted == $encryptedPass) { header("Location: http://" . $_SERVER['HTTP_HOST'] .dirname($_SERVER['PHP_SELF'])."/correctLogin.php"); } else { header("Location: http://" . $_SERVER['HTTP_HOST'] .dirname($_SERVER['PHP_SELF'])."/error.html"); } ?>
  6. ur asking us to help you on somthing that we havnt sen i.e help me my code dont work the page comes up black whats wrong ..... show us swher ur code is going worng and you may get a fix thanks mofm
  7. i dont think ther is anything wrong wioth the code but if u post it i can tell you ... maybe its somethinging to do with the server ?
  8. Try somthing like this hope it works but im not sure it sill Select * From products Where Collection LIKE '$collection' AND construction Like '$construction' AND color_e like '$red' OR '$green' OR '$blue'
  9. Try somthing like this <a href="delete.php?ID=3" >DELETE CONTACT</a> delete.php?ID=3 delete.php is the file your funtion is stored on ?ID=3 is the id of teh row you are deleting doing it this way you will need to remove funtion funtionname { } uif you need to keep it in a function for what ever reason make a new page and do somthing like this include 'functions.php'; $id=$_GET['ID'] //ofcourse sqlinjection etc needs adding if(delete_order($id)==1) {echo "rowdeleted"}else{echo "error occured or invalid id";} the function would look somthing like function delete_order($ID) { $query = "DELETE FROM order_enquiries WHERE id =$ID"; if($return = mysql_query($query)) { return 1; }else{ return 0; } }
  10. im guessing that $username is empty ? or it doenst exist maybe a typo or somthing ? Try echo $_post['user']; and see if the variable is comething onto the page this may help you out
  11. Ginger robot !!! i want to marry you byut seriously thanks ...its always the most simplist things that get me stumped it was stuck on thsi for nearly a hour !! i feel so stupid but thanks alot for your help its working as intended now lots of love MofM
  12. $searchterm = $$HTTP_POST_VARS['searchterm']; needs to be $searchterm = $HTTP_POST_VARS['searchterm']; And $query = "select * from grades where like '%".$searchterm."%'"; $result = $db->query($query); needs to be somthing like $query = "select * from grades where coloumnamehere like '%".$searchterm."%'"; $result = $db->query($query);
  13. yes ofcourse this is posible but you want how right well you could do it using PHP SESSIONS and little toturial i made is loacted here http://www.rohitab.com/discuss/index.php?showtopic=19510&st=0&p=165699&#entry165699 its small and bearly a tut but its a start for you thers are other ways to do this but im guessing this qwill be the easyist for you i havnt seen ur code so i dunno how its set up but somthing like this may work $_SESSION['keptdir']="/upload.php?file=4"; and you can call this to ur redirection script. hope this helps MofM
  14. im making a website and i want the websit to track its users ie what page they are on how many are online etc etc and iv done most of this code it just that a qurey is being a pain in my arse can i get some help please ? this is my mysql query: UPADTE usersonline SET member='y' refurl='http://localhost/25%20march%2008/' userid='1' currentpage='/25 march 08/test.php' activity = now() WHERE ipaddress ='127.0.0.1' this is the error that i recive from PHP myadmin Error SQL query: UPADTE usersonline SET member = 'y'refurl = 'http://localhost/25%20march%2008/'userid = '1'currentpage = '/25 march 08/test.php'activity = now( ) WHERE ipaddress = '127.0.0.1' MySQL said: Documentation #1064 - 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 'UPADTE usersonline SET member='y' refurl='http://localhost/25%20march%2008/' use' at line 1 I thank you for reading and i hope you can come up with a soloution to this tahnks MOFM
  15. Union the statments together so your sql will look something like this SELECT Name From Users UNION SELECT Name FROM Groups emm u probly wont understand that so go here and it will explain [a href=\"http://www.mysqlfreaks.com/statements/13.php\" target=\"_blank\"]http://www.mysqlfreaks.com/statements/13.php[/a]
×
×
  • 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.