2,113 Posted Topics
Re: Hi, as the error states the format of the invoice is not recognized by their system, you are showing only the namespaces in the header of the XML document. The document must conform to these namespaces. So if the namespace `xlmns:p` defines nodes like `<p:FatturaElettronica>` the following: <FatturaElettronicaHeader> <DatiTrasmissione> Will … | |
Re: Hi, the composer command `development-enable` is part of the `zf-development-mode` tools which ships in version 3.0 and requires PHP 5.6 or PHP 7.0, you're using 5.4, so it won't be installed. See if you can install version 2.* of these tools, as it should support your PHP version. For more … | |
Re: The current latest stable PHP version is 7.* from which `ext/mysql`was removed. If you are using PHP 5.6 then the query should still work, as `ext/mysql` is only deprecated. Can you share the error code you got from the above? ![]() | |
Re: Hi Jailani, in your code you are using: $value = $_GET['change']; which will not work if the form set the method to POST: <form method="post"> if you perform a POST request then you have to use $_POST in the PHP side to access the values of the input fields. You … | |
Re: Check `arp-scan -ln` it outputs something like this: > arp-scan -ln Interface: wls1, datalink type: EN10MB (Ethernet) Starting arp-scan 1.8.1 with 256 hosts (http://www.nta-monitor.com/tools/arp-scan/) 192.168.0.1 00:c0:9f:09:b8:db QUANTA COMPUTER, INC. 192.168.0.5 00:02:a5:90:c3:e6 Compaq Computer Corporation 192.168.0.87 00:0b:db:b2:fa:60 Dell ESG PCBA Test 192.168.0.90 00:02:b3:06:d7:9b Intel Corporation 192.168.0.153 00:10:db:26:4d:52 Juniper Networks, Inc. 192.168.0.191 … | |
Re: Hi, the first link redirects with 302 to the home page, when instead should show a 404 error page. Look here: * http://www.gsa-constructionspecialist.com/assets/upload/artikel/2007TugasLPJKke5.pdf And go to the first folder: * http://www.gsa-constructionspecialist.com/assets/ You server is listing the index, from there you can see that the `upload` directory does not exists. It … | |
Re: Can you show the method controller? | |
Re: > i am just curious how to access social media accounts like facebook, watspp etc. with the users' permission in order to help them prevent unethical hackers from breaking into their accounts. Even if ethical, that would probably be a misuse of FaceBook terms of services. There are projects, like … | |
Re: Hi, if this is for WordPress then follow these directives: * https://codex.wordpress.org/Using_Permalinks otherwise search for *apache and url rewriting.* | |
Re: Ok, it does not work because you are not accessing to the returned row when you call `$stmt->otdq_ordernum`. Use: $row = $stmt->fetch(); And then: $row->otdq_ordernum; Or use a MySQL variable. Also `rowCount()` in PDO, assuming you are using it, does not return the rows found in a SELECT statement, but … | |
Re: Hi, it happens because getDB() is using PDO and in the script you are using MySQLi. Fix it and it should work. | |
Re: Hi, you could use [`array_diff_assoc()`:](http://php.net/array-diff-assoc) <?php $sql = [25.00, 25.00, 50.00, 82.00, 120.00, 205.00]; $post = [25.00, 50.00, 50.00, 80.00, 120.00, 205.00]; print_r(array_diff_assoc($post, $sql)); Returns: Array ( [1] => 50 [3] => 80 ) So you can manage the array through the index key of the array. But what is … | |
Re: Hi, the PHPMailer hack would probably fail if submitting filtered data to the library, i.e.: * sanitizing through `filter_input()` * and by using SMTP, because it will not use sendmail, nor mail() Note, a `filter_*` function is also used in the PHPMailer library, but as default option of [their `validateAddress()` … | |
Re: > how does this page look to you? https://www.dazah.com/audiences Looks fine here with Chromium 55.* and no login issues. Besides... Happy New Year! | |
Re: Hi, it happens because their server detects you are using a bot, by setting a User-Agent their server replies with a Location header that suggests where to redirect the request, this is a time-limited login link that redirects back to the requested page. Example with [HTTPie:](https://httpie.org/) http -vv GET http://www.aaii.com/sentimentsurvey/sent_results … | |
Re: FIND_IN_SET() does not use indexes, so it can become slow. You can try with a regular expression and LIKE: SELECT `column` FROM `table` WHERE `column` LIKE '123%' AND `column` RLIKE '123[0-9]{0,3}'; See this post for more information: * https://www.psce.com/blog/2012/03/31/mysql-queries-with-regexp/ | |
Re: **@HG** Hi, I think it's related to this thread: * https://www.daniweb.com/community-center/daniweb-community-feedback/threads/470580/link-underline | |
Re: In addition: if the hash is generated by a salted md5 or sha1, the attacker can generate a string that outputs the same hash, it does not need to find the exact password, it just need to find a collision. See: * https://en.wikipedia.org/wiki/Collision_attack That would not work on Google, but … | |
Re: You could use the `RecursiveDirectoryIterator()` something like in this comment: * http://php.net/manual/en/function.glob.php#92710 More precisely like this: <?php $path = dirname(__DIR__); $dir_iterator = new RecursiveDirectoryIterator($path , FilesystemIterator::SKIP_DOTS); $iterator = new RecursiveIteratorIterator($dir_iterator , RecursiveIteratorIterator::LEAVES_ONLY , RecursiveIteratorIterator::CATCH_GET_CHILD); foreach($iterator as $file) if(TRUE === $file->isReadable()) echo $file . PHP_EOL; | |
Re: I'm following the Redis, PHPRedis documentation and the CI driver to see if there is any discrepancy that could lead those results. But as far as I'm seeing it seems all fine in your code. Only few notes on PHPRedis, I don't know if it helps you: **A)** `set()` used … | |
Re: Hi, look, this hex dump suggests it could be C++: 0007e0a0 72 20 61 72 67 75 6d 65 6e 74 73 0d 0a 00 00 00 |r arguments.....| 0007e0b0 52 36 30 30 32 0d 0a 2d 20 66 6c 6f 61 74 69 6e |R6002..- floatin| 0007e0c0 67 … | |
Re: **@Dani** I think it's related more to prepared statements in `ext/mysqli`: * http://php.net/manual/en/mysqli-stmt.bind-param.php **@Sunny** See if this comment helps: * http://php.net/manual/en/mysqli-stmt.bind-param.php#92283 Note: when uploading a blob consider to convert it into a string, otherwise look at: * http://php.net/manual/en/mysqli-stmt.send-long-data.php | |
Re: It is not automatic. When you call `/main/` you point to a directory (aka folder) in the document root of the web server, to display by default a file you need to configure the server. This depends on the `DirectoryIndex` directive, if you are using Apache. The documentation says: > … | |
Re: Hi, you have two choices: 1. parse the CSV strings into an array and then insert 2. use the `LOAD DATA INFILE` statement to feed the file to the database, but it requires to have access to a folder that is readable by the MySQL server For an example of … | |
Re: Hi, set the the rewrite base to your subfolder `RewriteBase "/myapp/"`, then it should work. For more information read this: * http://httpd.apache.org/docs/current/mod/mod_rewrite.html#rewritebase | |
Re: Hi, from the [documentation the `strtotime()` function](http://php.net/strtotime) you can read: > Parse about any English textual datetime description into a Unix timestamp And it expects: int strtotime ( string $time [, int $now = time() ] ) The `$stockdate` is a DateTime object, not a string. So try by submitting … | |
Re: **@athanas_1** Hi, this error happens when you declare a function two or more times. For example: <?php function a() { return ; } function a() { return ; } You can fix it by removing the second declaration. | |
Re: Hi, check the source of the **custom data** example in the autocomplete JQueryUI documentation: * http://jqueryui.com/autocomplete/#custom-data The `select` property should fit your requirements: select: function( event, ui ) { $( "#project" ).val( ui.item.label ); $( "#project-id" ).val( ui.item.value ); $( "#project-description" ).html( ui.item.desc ); $( "#project-icon" ).attr( "src", "images/" + … | |
Re: Hi, right before this code, set a check: /* check connection */ if(mysqli_connect_errno()) { printf("Connect failed: %s\n", mysqli_connect_error()); exit(); } Too see why the connection returns null. ![]() | |
Re: Hi, with browsers requests, the server can only accept the upload and check the sizes when it finishes. So, if you want to manage the error through PHP, raise the size and set a lower limit in the script. If the limit in the php.ini file is 25MB and the … | |
Re: Hi, if you want to download the project to a new box then you clone it, so you do: git clone url_of_the_repository If the code is already there, but not updated to the latest version, then you just pull: git pull and then you can push the changes. See: * … | |
Re: Hi Dani! :D I have few points: ###A I still not receive emails (newsletter, notifications) with my registration email address (the *Receive Community-related Email?* issue). I only receive the monthly newsletter with the email address of the [*other* account.](https://www.daniweb.com/members/1132988/1) To watch an article I have to use that account from … | |
Re: Hi, you have to share more information about the issue, the form and the controller code could also help. | |
Re: Hi, are you following the documentation? * http://book.cakephp.org/3.0/en/controllers.html#redirecting-to-other-pages If affirmative, can you share your code and more information about what is not working? | |
Re: At line 36 add: or die(mysql_error()); and see if it returns some information about the query syntax. By the way, you should switch to MySQLi or PDO. The mysql_* functions have been removed from PHP 7.0, so you will have hard time when upgrading. See: * http://php.net/manual/en/mysqlinfo.api.choosing.php | |
Re: ###Side Note You can use **Apache Bench** to test loads: * http://httpd.apache.org/docs/current/programs/ab.html It allows you to build GET & POST requests, file uploads and see how the server performs under the defined conditions. | |
Re: Hi, add error checking to the database connection and query execution, if it does not solve, test your query on a MySQL client. | |
Re: Hi, I don't understand your request: `defined()` is used only with constants not with statements, are you defining a constant or just trying to `include 'somefile.php';` and be sure it's loaded? | |
Re: Hi, in addition to **Ddanbe's** suggestion: with Google Chrome, right click a word in this post, choose **Inspect**, it will open the *Web Developer Console,* click on **Computed:** from there you get all the style information about the inspected element. | |
Re: Hi, It happens because of rounding errors, for more information see: * http://floating-point-gui.de/ * http://docs.oracle.com/cd/E19957-01/806-3568/ncg_goldberg.html You could try with `Decimal()`: from decimal import Decimal # with binary floating points print(divmod(356, 3.56)) (99.0, 3.5599999999999947) # with arbitrary roundings print(Decimal('356') % Decimal('3.56')) 0.0 Example: http://ideone.com/a6UDRi | |
| |
Re: Hi, if using MySQL you can do a second query: $num = $this->conn->query("SELECT FOUND_ROWS()")->fetchColumn(); About rowCount(): > PDOStatement::rowCount() returns the number of rows affected by the last DELETE, INSERT, or UPDATE statement executed by the corresponding PDOStatement object. > If the last SQL statement executed by the associated PDOStatement was … | |
Re: Hi, start from the ground: * install a local development environment to test your scripts, so search tutorials about installing PHP and MySQL, or if you want something more easy to manage, search for XAMMP, LAMP & co. * then search tutorials about PHP and MySQL, for example "how to … | |
Re: Hi, have you tried the **web developer console** integrated in your browser (Mozilla Firefox, Chrome, Chromium) to see if the javascript code is raising some errors? Can you provide a live example? Besides, test your script with a simple HTML form, you will see there are at least few issues: … | |
Re: Hello, you can use a stored procedure, for example: DROP PROCEDURE IF EXISTS `calcTotals`; DELIMITER // CREATE PROCEDURE `calcTotals`(IN `loanStatus` VARCHAR(100), IN `settlementStatus` VARCHAR(100)) BEGIN DECLARE `total_loan` DECIMAL(10,2); DECLARE `total_settlement` DECIMAL(10,2); SELECT SUM(`total_amount`) INTO `total_loan` FROM `loan` WHERE `loan_status` = `loanStatus`; SELECT SUM(`amount`) INTO `total_settlement` FROM `settlement` WHERE `sett_status` = … | |
Re: Hi, we need more information about your issue: the code, what is expected to and what you get. If you can, add a JS fiddle, it would help. | |
Re: **@zebnoon1** Hi, you were asked multiple times, to reply to some questions with useful information. Calmly read again Pritaeas posts and reply to his requests. For example, he asked: > What size is the downloaded file? So the downloaded .pdf file is 0 bytes, few bytes and when opens is … | |
Re: Hi, see the lines `254` and `263` of the PHP page, the first checks if the token is set by the request (i.e. through javascript), the second is a conditional IF statement that verifies the value of the set token with the hardcoded. Change the value in the javascript and, … | |
Re: Hi, change the **DB_IStatement_1** signature for the `execute()` and `fetch()` methods and it should work fine. In practice you are implementing the PDOStatement interface into your class, so you must declare the same arguments: public function execute($params = []); public function fetch($how = NULL, $orientation = NULL, $offset = NULL); … | |
Re: Hi! The method/function `fetchAll()` of the PDO library returns an array, which is an empty array if no rows are matched, what you want here is probably `fetchColumn()`: $type = $stmt->fetchColumn(); And you also want to use prepared statements: I know I repeat myself a lot on this subject, but … |
The End.