Jump to content

Zup

Members
  • Posts

    9
  • Joined

  • Last visited

    Never

About Zup

  • Birthday 03/03/1988

Contact Methods

  • Website URL
    http://

Profile Information

  • Gender
    Not Telling
  • Location
    Winnipeg, MB

Zup's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. Are you sure this is normal behavior? It's pretty stupid of MS to do this, and I'm all for promoting the use of other browsers but the fact of the matter is over half the population on the internet uses IE and I'd like it to work for them too.
  2. I have a simple form, just one password box and one submit button that posts to itself. I have a PHP script validate the password and create a session if it's correct. Everything works fine, except in IE7 if I press Enter to send the password it looks like the page just refreshes, but if I click Submit, it works fine. Firefox does not have this problem, it works both ways. Any ideas? Please help.
  3. Yea that does make sense. Now I have to learn how to make a cron job, but it can't be too hard. Thanks for your help. BTW, would this help he out? [a href=\"http://www.phpfreaks.com/tutorials/28/0.php\" target=\"_blank\"]http://www.phpfreaks.com/tutorials/28/0.php[/a]
  4. I am interested in creating a text-based game on the internet like Midnite Challenge, NY Mafia, Realthugz etc. However, I don't know how to keep the server updating itself. Games like this require constant updating, for example, a shop restocks, prices on commodities change, businesses open and close, etc. Say for example I want a particular store to be open from 9AM to 6PM. How would I make it so the server opens the store and closes the store at it's respective times? Sorry if this is unclear. If anyone needs any clarification, please ask. EDIT: Holy crap! Sorry for triple post. Someone please delete the other two.
  5. If you really need to physically change the orders, you'll have to create a temporary table that has the same properties as the first table. Then you can insert data from the first table into the temporary table, select a row to be moved in the first table, and update the other row (the row that you put into the temporary table) with the information from the selected row. Now select your row from the temporary table, and update the row in the first table that you "moved". If that's too complicated to read, this may help: Let FTable be first table and TTable be temp. table We will switch rows 2 and 6. Row 2 from FTable gets copied into TTable. Row 6 in FTable overwrites Row2 in FTable (select then update) Row 2 from TTable overwrites Row 6 in FTable (select then update) TTable is deleted. End result: row 2 and row 6 are switched.
  6. Be careful when you post scripts on here because often they will contain your password, like yours did. Now the line: $query = "INSERT INTO $table ($column) VALUES ( 1,$CMS)"; will produce an error. You have to get rid of ($column). Next, you're inputting values (1, $CMS). I don't see anywhere in your code where $CMS is given a value. You're going to have to add this line before your query line somewhere in your code: $CMS = $_POST['CMS']; Now your 1 in there seems weird. I'm guessing that's a mistake too but since I can't see what your table structure is I can't be sure. Usually the first column in a table like this is your auto-increment variable, so replace 1 with '' (two single-quotes). You also have a ton of unneccessary variables in there but that won't stop the script from working. Post here when you have tried this.
  7. Paste your cms.php file here, I'll edit this and help you when you do.
  8. Zup

    Members Db

    Have them log in with their username and password. Then present them with a form that they can use to edit their info with. Have the form action link to the same page and use the method "post". At the top of your PHP script, do this: $var = $_POST['var']; Replace var with your variable names, (ie. $FirstName = $_POST['FirstName'] Then connect to your DB and use MySQL to update your members table, like so: $query = "UPDATE users SET FirstName='$FirstName', LastName='$LastName', Address='$Address', Phone='$PhoneNumber' WHERE userID='$ID'"; @MySQL_Query($query) or die ("Error executing query"); Now $ID is going to have to be found when the user logs in since every user should have a unique ID. This can be found with the query: @MySQL_Query("SELECT userID FROM users WHERE username='$user' AND password='$pass'") or die ("Error executing query"); I hope this helps, if you need extra help just ask, but you may have to provide a little more information about your tables and their field names.
×
×
  • 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.