2,113 Posted Topics
Hello, while browsing my posts I saw that sometimes quoted text is not displayed, yet there is an empty space in the corresponding area, I think the quote block is floating somewhere, if I inspect the document I can see the quoted text, here are few screenshots:  ` method of the [image library](https://codeigniter.com/user_guide/libraries/image_lib.html), it happens because of: Image_lib class already loaded. Second attempt ignored. You can see that from the log of CodeIgniter. I don't know if they added something to avoid this problem, I just use this solution: * http://forum.codeigniter.com/archive/index.php?thread-4297-2.html see the … | |
Re: Hi, enter in Community Center, the parent of this forum, and click on Live Chat: * https://www.daniweb.com/community-center/3 | |
Re: Hi, you can do that with git-rm but if you want to remove it from repository's history, then you can follow these instructions: * https://git-scm.com/book/en/v2/Git-Tools-Rewriting-History#_removing_file_every_commit * https://help.github.com/articles/remove-sensitive-data/ Or you can use BFG Repo Cleaner as suggested in the last link: * https://rtyley.github.io/bfg-repo-cleaner/ | |
Re: Hi, check the documentation: > the latest release of MySQLdb (1.2.5) doesn’t support Python 3. In order to use MySQLdb under Python 3, you’ll have to install mysqlclient instead. * https://docs.djangoproject.com/en/1.9/ref/databases/ * https://pypi.python.org/pypi/MySQL-python/1.2.5 But **mysqlclient** does not support Python 3.5: > MySQL-3.23 through 5.5 and Python-2.7, 3.3-3.4 are currently supported. … | |
Re: If binlog is enabled maybe you can access the previous queries and reload the old/new database: * https://dev.mysql.com/doc/refman/5.6/en/mysqlbinlog.html But if everything was replaced, due for example to a Windows restore point, then it will not work, you have to try to recover the replaced files, check: * http://superuser.com/questions/909006/recover-broken-mysql-database-after-setting-windows-back-to-an-earlier-date | |
Re: Hi, Sorry but on update and add functions you're setting `$_SESSION['msg']`, on `message()` instead you're dealing with `$_SESSION['message']`, is that a mistype? I built a simple test and works fine: <?php session_start(); function message() { if(isset($_SESSION['msg'])) { $output = "<div class=\"msg\">{$_SESSION['msg']}</div>"; unset($_SESSION['msg']); return $output; } } function insert() { $r … | |
Re: Hi James, if you want help you **must** set a proper title, explain us what you want to do and show where you are stuck, this implies that you share the code that gives you the issue. ![]() | |
![]() | Re: Hi, with **pure PHP** you can change the path in which session files are stored, see `save_path`: http://php.net/manual/en/session.configuration.php#ini.session.save-path Create a directory in a parent of public_html, so that is not reachable by a browser and other users in the server. In alternative you can store sessions in database, doing this … |
Re: Hi, an easy solution is a mysqldump: mysqldump --no-data --opt db_name | mysql --host=remote_host -C db_name This command will dump from local to remote database (remote would be the laptops), the `--no-data` option dumps only the `CREATE TABLE` statements, without the insert statements. For each command you have to define … | |
Re: So you want to change the **DocumentRoot**? In that case it can be done only in these contexts: * server config * virtual host It cannot be done at .htaccess level. More information here: * http://httpd.apache.org/docs/current/mod/core.html#documentroot | |
Re: Hi, I'm not confident with c# but check if this helps: * https://github.com/bashwork/common/blob/master/csharp/validation/Source/Validation/Internal/FormValidationTester.cs#L90 Found via https://searchcode.com/?q=regex+ipv6&loc=0&loc2=10000&lan=6 | |
Re: Hi, you have to fetch the results, `fetch_all()` will return the entire result set: $result = $name->fetch_all(MYSQLI_ASSOC); print_r($result); While `fetch_array()` will return one row, and in order to get the orders you have to loop: while($row = $name->fetch_assoc()) { echo $row['full_name']; } Or move the internal pointer through `field_seek()` . … | |
Re: Hi! I'm experiencing something similar to ddanbe, I only see endorsements on UI/UX Design (12) and Linux and Unix (10) categories, everything else disappeared. | |
Re: Hi, you should move on `public_html` only the files that are in the `public` folder of your laravel application, all the other files should be placed in the parent directory, so that are not accessible by a browser. ![]() | |
Re: It's fine for me, I like it. The only thing that still drives my attention (not disturbing) is the Discussion Starter tag, too purple, if that was gray or outlined like the Featured or the Sponsor tags, I think it would be better. | |
Re: Same here on Google Chrome: Mozilla/5.0 (X11; Linux i686) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/45.0.2454.93 Safari/537.36 | |
Re: Check also this thread: * https://www.daniweb.com/programming/web-development/threads/497916/diference-between-two-dates#post2178414 bye! | |
Re: Hi, try to round the result of `$wd` because if for example this is a `4:3` it would return `666,67` i.e. a float, where instead `imagecreatetruecolor()`expects an integer. | |
Re: Hi! According to the RFC 2109 this seems to be the expected behavior, section 4.2.1: > An origin server may include multiple Set-Cookie headers in a > response. Note that an intervening gateway could fold multiple such > headers into a single header. And section 4.2.2: > Informally, the Set-Cookie … | |
![]() | Re: Hi, run: SELECT `User`, `Password`, length(`Password`) FROM mysql.user; The length should be 41, if you get 16 it means that the user is still using the old password system and it needs to be updated. And you have to make sure the system variable `old_password` is set to `0`, otherwise … |
Re: Hi, I don't understand, could you explain it better and show full code? | |
Re: Hi, the ID must be unique, if you have two or more `id="anchor-name"` then it would not work. If this still does not help then share the code. | |
Re: Hi, check this link: http://php.net/migration55 P.S. You should read also migrations notes for 5.3 and 5.4, to see what else has changed. ![]() | |
Re: Hi, if that is a unix timestamp then do: -- updating date format UPDATE `table_name` SET `col_name` = FROM_UNIXTIME(`col_name`); -- changing colum type to datetime ALTER TABLE `table_name` MODIFY `col_name` datetime null; If you want to preserve the old value, then add a new column and update against it: ALTER … | |
Re: Hi, change: $target = "upload/"; To: $target = $_SERVER['DOCUMENT_ROOT'] . "/upload/"; Otherwise `move_uploaded_file()` will try to write the destination relatively to the script path. Then it should work. A note: the conditional statements that you're using to detect Javascript, CSS and PHP will mostly fail, as the browser will probably … | |
Re: Hi, it does not work it means one of these statements does not run? Which specifically? And by the way: `$cat` should be `$_GET["catid"]`? if(isset($_GET["catid"])) { $statement = "posts WHERE cat_name='$cat' ORDER BY pid ASC"; If yes, then simply assign the value to the `$cat` variable and it should work. | |
Re: Hi, I suggest you to print the contents of the POST request to see what is actually sent to the script, so on top of the progress.php file simply put: <?php if($_POST) die("<pre>". print_r($_POST, true) ."</pre>"); At the moment I see you have duplicated input fields like **Progressid**, by doing … | |
Re: Hi, have you checked the encoding returned by the server? You should be able to see it in the `Content-Type` header response, by using the developer tools in Google Chrome, as explained here: * https://developer.chrome.com/devtools/docs/network#http-headers Or by running curl: curl -I http://app.tld/page | |
Re: > do i need another text editor for the php file? Hi, it's not required, but using an editor that highlights the code will help a lot. You can try SublimeText with SublimeLinter for syntax checking: * http://www.sublimetext.com/ * http://www.sublimelinter.com/ For more suggestions about editors and IDEs search the forum, … | |
Re: Hi, at line `9` of the email.php script do: // success page if(mail(...)) header('Location: http://website.tld/thanks.php'); // error page else header('Location: http://website.tld/error.php'); // stop script execution exit; And remove the echo statement at line `11`. Docs: * http://php.net/manual/en/function.header.php | |
![]() | Re: Hi, you could use json or base64, but what happens if you want to search throught collected data? It would be unusable without extra processing. Why don't you normalize the array? Look at section 8 of this tutorial: * https://www.daniweb.com/web-development/php/threads/499320/common-issues-with-mysql-and-php |
Re: Hi, I understand the data is float but I'm not sure about the column type, is this: `decimal`, `float` or `double`? | |
Re: Hi, read this guide: * https://help.ubuntu.com/community/phpMyAdmin In particular follow the instructions for Ubuntu 13.10+, you have to include the configuration file into the server, the guide refers to Apache. Anyway, I prefer to install it directly from source, to get the latest version. Just uncrompress to a directory in `/var/www/`, … | |
Re: Do you want to extract it from a string or the string is a number itself? # case 1 $str1 = "Buy 12 apples, 1.5kg of beans and 4 onions, it's already 12:35 hurry up, it's l4t3!"; # case 2 $str2 = '12'; In first case by using `preg_match_all()` with … | |
Re: Hi, in order to write a response you have to send an header and then call `end()`: res.writeHead(200, {'Content-Type': 'text/html'}); res.write('2working'); res.end(); Also, probably mistype, on console log you wrote that it listens on port 8080, but it's executing on 8889. Docs: * https://nodejs.org/api/http.html#http_response_writehead_statuscode_statusmessage_headers * https://nodejs.org/api/http.html#http_response_end_data_encoding_callback | |
Re: You use it outside and just add the variable that carries the result of the loop, for example: $rows = ''; foreach($result as $row) $rows .= " <tr> <td>{$row['article']}</td> <td>{$row['price']}</td> </tr> "; $content = " <p>Display order list:</p> <table> <thead> <tr> <th>Item</th> <th>Price</th> </tr> </thead> <tbody> {$rows} </tbody> </table> "; … | |
Re: You should be able to start and stop it as a daemon: sudo service mongod start sudo service mongod stop | |
Re: Hi, [the overview explains](https://developers.google.com/maps/documentation/javascript/styling#overview) that there are two methods to load these styles. In the first case you can change the default style by assigning the array to the **MapOptions** object: map.setOptions({styles: styleArray}); Documentation for the first method: * https://developers.google.com/maps/documentation/javascript/styling#styling_the_default_map * https://developers.google.com/maps/documentation/javascript/reference#MapOptions The second method uses the **StyledMapType** class and … | |
Re: Hi, by default the composer autoload is set to `FALSE`. So open `/application/config/config.php` and replace this: $config['composer_autoload'] = FALSE; With: $config['composer_autoload'] = FCPATH . 'vendor/autoload.php'; `FCPATH` is defined in the root **index.php** file, if the vendor directory is at the same level, then it should work fine, otherwise define the … | |
Re: Hi, it's a WYSIWYG text editor for HTML pages: http://www.tinymce.com/ | |
Re: Hi, in pratice apt does not resolve that repository, you can change it, read these links: * https://wiki.debian.org/SourcesList * http://http.debian.net/ In practice you can set `http://httpredir.debian.org/debian` and let the server choose the best mirror, or you can manually define which mirrors you want to use. | |
Re: Hi, first problem is `CURDATE()`, the query won't be cached, you could try to send this date from PHP and see if it improves the execution, at least you should see a difference when the query is repeated on the same range. | |
Re: Yes, check the W3C Validator: https://validator.w3.org/ |
The End.