Jump to content

mikosiko

Members
  • Posts

    1,327
  • Joined

  • Last visited

  • Days Won

    1

Everything posted by mikosiko

  1. Define what "Still does not work" exactly means... what are you getting (or not)?... messages on the screen?.. nothing?...zero?.. niech?.... help the people to help you!! Some observation: - Why are you setting $md5_password if in your query you are using the plain $password ... and in addition... you should be using password_hash() instead of that md5 for hashing the password. - What is the result of this line in your code // output contents of $row printf('<pre>%s</pre>', print_r($row, 1)); - Here... Do you know the diference between = and == ? } if($_SESSION['loggedIn'] = true) { header("index.php"); } - Here ... you already sanitized the $_POST['username'] right?... why you still using the un-sanitized value again? ... $_SESSION['username'] = $_POST['username']; header("Location: banned.php"); - Last but not least... the order of all your if's after the closing } of your first one make no sense at all... you need to re-think your logic starting from here: if($row['user_level'] == 1) { you understand that if your query doesn't produce a resultset $row['user_level'] will no be valid?
  2. Do you have a field named 'no Data'? That is what $row['no Data'] means... Maybe you want just echo the literal'no Data'?
  3. What exactly is "bname"... A field in your table or a variable coming from another place?
  4. Yes... Be sure to use real prepared sentences instead of emulated ones (normally the default). You must setup PDO::ATTR_EMULATE_PREPARES to FALSE Read carefully about prepared sentences Y the reasons behind this setup here http://php.net/manual/en/pdo.prepare.php In the users contributed note #7 is a good explanation of why
  5. means that your query is incorrect and hence failing. Add this lines after your <?php opening tag or better yet setup how to manage and display errors in your php.ini. It should give your indication of what is going on. // Define how to display/report errors ini_set("display_errors", "1"); error_reporting(-1); In additional note: - You should not be using mysql_ API it has been already deprecated; you should be using mysqli_ or PDO
  6. In addition to what Barand said.. You don't see anything wrong with this line in your code? if (isset($_POST['inp_submit']) AND $check_inventar_num = 0) HINT: Assignment Operator is not the same as the Comparison Operator
  7. I will assume that you don't have experience with composer neither with Laravel, hence your lack of understanding, and don't making sense of my answer... let me clarify a little bit... starting for show you your own sentences in the OP OK.. so you have Laravel running in your PC after install it using composer... and I'm assuming that will be the pc that you will use for developing correct? .... (I hope that you are not thinking in developing on your Production Server)... Have you looked what Composer did with the Laravel dependencies? (hint: check the "vendor" folder/sub-folders under Laravel)... short answer...Laravel is Installed and ready to run so you can start developing/testing.... (as you said...a framework with a bunch of "files")....... when your application is completed/tested and ready for deployment just COPY the Laravel Folder to your server (no Composer involved not apt-get, nothing fancy at all) plus your application files... and there you go, just adjust the database credentials (if you are using ones) and that is. Later, if you need to update/upgrade Laravel... just do it in your DEVELOPMENT enviroment, test everything again and RE-DEPLOY to your Server.... Intranet/Internet doesn't matter at all because as you said is your Production Server at work... so you can upload the files yourself (if you have the permissions) or hand it to your SysAdmins for installation. There are other options to deploy your app's but it will be the simplest if you don't have the rights on your server. So, what part of my original answer didn't make sense to you, and in which part I contradict myself? Good Luck
  8. as far as I know you don't need to install Composer in your server, if you already installed laravel in your PC using composer all the dependencies are in place, then you only need to copy your whole Laravel application folder to your server
  9. tested your code myself ... unable to reproduce what you are telling us... as a result of var_dump($mysqli->commit()) I'm getting the expected "bool(true)" ... If you include this lines before your var_dump() what do you get? (expected result is 0) if ($result = $mysqli->query("SELECT @@autocommit")) { $row = $result->fetch_row(); printf("BEFORE THE COMMIT Autocommit is %s<br />", $row[0]); $result->free(); } var_dump($mysqli->commit()); if you get the expected result (meaning that before the commit the autocommit is indeed FALSE) then what left is that maybe you didn't provide us the same code that you are testing and that is making the difference in our testings, or that you found a weird bug that no one else here is able to replicate with the posted code
  10. look for and enable the php_pdo_odbc extension on php.ini restart your webserver an try again
  11. Jazz man is asking if you are using Myisam or Innodb or other storage engine for your table... The behavior that are you having is indicating that you are using most likely Myisam which is non-transactional, therefore autocommit, commit nor rollback have any effect
  12. something for you to look at if you have PHP version 5.5 or later... read the examples/usage http://php.net/manual/en/function.password-hash.php for PHP 5.3.7 and later there is a compatibility pack available here: https://github.com/ircmaxell/password_compat you should be using it for hashing
  13. [EDIT] Zane beats me seems that you are missing a closing braket for the try... just before the catch ..... .... } catch..... ... ...
  14. If the suhosin.ini was parsed then phpinfo() should show some of the setup variables for it (or look directly in the ini file)... Even when the default value for all of them is 1000 worth to check them: Suhosin.post.max_vars Suhosin.get.max_vars and Suhosin.request.max_vars Here is the link to the configuration options http://www.suhosin.org/stories/configuration.html
  15. there is any reason why your video table need to use the Innodb storage engine?.... are you implementing referential integrity or transactions on it?
  16. Did you check in the output of phpinfo() if the suhosin extension is installed/enabled in your server?
  17. you tried what?... where is the code?
  18. have you even tried the suggestions that were gave to you on post # 3 http://forums.phpfreaks.com/topic/292188-pdf-output-problem/?do=findComment&comment=1495360 and/or post #8 http://forums.phpfreaks.com/topic/292188-pdf-output-problem/?do=findComment&comment=1495430 that suggestions could or couldn't work, but is up to you to try it in this part of your code:
  19. Rob, if you have access to your php.ini check how the variable max_input_vars is defined... maybe it has a wrong limit... I was able to replicate the behavior that you are seeing setting that variable to 1 (the default is 1000).... maybe is not your case, but should be investigated. According to some others posts in the net, it could be also an issue of the suhosin extension (if it is installed), basically also due to wrong configuration of some variables on it. hope this help
  20. Is not just a matter of enclose those in some html element (like span p.e) and apply whichever CSS style you want?... Same way that you are doing in other parts of you code
  21. Thanks Jacques I'm already testing that one... precisely because the local storage... so far so good
  22. looking for suggestions and experiences from those of you that use a Password Manager
  23. The D2 came from this part ρ (D2,Driver), here you are using the RENAMING (or RENAME) operator, which is equivalent to the ALIAS(ing) in SQL.. maybe it will help a little more: http://www.databasteknik.se/webbkursen/relalg-lecture/index.html
  24. Assuming that the OP is really talking about Relational Algebra, then this worth to be read completely https://en.m.wikipedia.org/wiki/Relational_algebra There are some implementations examples that could help.
  25. So given the example data that you posted, which are the expected results (in detail using the posted data)? I will suggest you to test your query eliminating first the GROUP BY and the "AND `t5`.`userid` = '599zxj'" filter temporarily that will allow you to analyze which are the results of your basic JOINS and proceed from there applying the filters that you consider necessary.
×
×
  • 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.