Maq
Administrators-
Posts
9,363 -
Joined
-
Last visited
-
Days Won
3
Everything posted by Maq
-
Sorry, my bad, no offense meant. No biggie
-
$query = "SELECT ticket_id FROM tickets WHERE ticket_id='$id'"; $result = mysql_query($query); if (mysql_num_rows($result) == 0) { This evaluates to false. Meaning, it's finding a record with a matching id of $id. Echo the query and see what it's looking for to make sure it's correct. (Please don't post all of the code, only the relevant part.)
-
You don't have to delete it, there is a tab option where you can mark threads as solved.
-
You should really just try it and find out, you can always switch.
-
[SOLVED] Am I violating the laws of encapsulation?
Maq replied to CaptainChainsaw's topic in PHP Coding Help
Care to expand? -
Seems like a problem with Zend. You may have better luck on the Zend forums. Moving to "Application Frameworks".
-
Do you mind sharing the correct code in case someone else runs into a similar issue?
-
I wish there were some examples, easily seen, about what I might be able to do referenced at the beginning. Hehehe kcotter, these examples in the manual should cover all the issues you addressed, let us know if there are any other problems.
-
Are the user's credentials shared between phpBB and your site?
-
Seems like that would be important, they should put something like that in the manual.
-
Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result
Maq replied to Ugat's topic in MySQL Help
Okay, that is a lot of code, especially MySQL code to go through. You have a problem with your query statement which is why you are recieving all of those other errors. Please put this at the end of your query to find a more 'descriptive' error message: $query = mysql_query($qry_stmt) or die(mysql_error()); (moving to the more appropriate "MySQL Help" section) -
I don't think any Moderator would bitch that you wouldn't post it, it's a pretty popular security plug-in anyway
-
Yes, it's called "SQL Inject Me". I use it all the time, even though it catches trivial things that may or may not pose harm, it's a very good tool.
-
I could be wrong, but I think you need to enable this library in your php.ini. Remove the ';' in front of that .dll file. You can also see if this library is enabled with: phpinfo(); ?>
-
Not exactly what you're looking for, but has some neat history and background. http://www.phpfreaks.com/forums/index.php/topic,218939.0.html
-
Please do not make posts requesting code be made for you, especially when you haven't even made any attempt what so ever. More over, this is obviously HW, and doing other's HW on these forums is despised, if you are in need of specific help or have a specific question, we'll be sure to help, other than that, go read some tutorials and try it yourself.
-
[SOLVED] Am I violating the laws of encapsulation?
Maq replied to CaptainChainsaw's topic in PHP Coding Help
You should be requiring all interaction to be performed through an object's methods. They are 'get' and 'set' methods (accessors and mutators) in your class that get and set data. From the information provided it looks like your code obeys the rules of encapsulation. -
It's probably better you mark this as SOLVED and start a new thread there with your updated design and description of your task. (you will get more replies and it will be easier to follow)
-
If you want me to move this to, "Application Design" I will, or, you could create a brand new thread there about your design to get feedback. The hardest part would be the database design, I suggest you sit down, design and normalize your tables to improve performance and scalability. (Database Normalization)
-
There is a good tutorial on phfreaks - Basic Database Handling. In all honesty, you don't need a book for any of this. There won't be a book for your specific needs anyway, reading a tutorial and learning how to work with PHP and MySQL will allow you to apply it to any situation.
-
Yeah I know, I just copied and pasted a portion of the OP's code to run a test, but thanks anyway.