- Strength to Increase Rep
- +2
- Strength to Decrease Rep
- -0
- Upvotes Received
- 60
- Posts with Upvotes
- 45
- Upvoting Members
- 19
- Downvotes Received
- 0
- Posts with Downvotes
- 0
- Downvoting Members
- 0
47 Posted Topics
Re: [This](This) might help, though I have not tested it. | |
Re: This is a shot in the dark, but after quickly looking at the [docs](https://simplehtmldom.sourceforge.io/docs/1.9/), I believe the issue is that you are trying to parse an XML document using an HTML parser. In line 14, you are specifically looking for 'a' tags. The xml file you linked does not have … | |
Re: Ugh! I've done that, and it broke everything! This reply may be a bit too late, and you may have figured it out already. I'm going to assume that you changed the WordPress Address (URL) or the Site Address (URL), and after updating it, you can no longer access WP … | |
Re: @borobhaisab > And what do the other first two do if they are valid in any way atall ? The ONLY way to make them valid, is to properly place the closing bracket on [trim()](https://www.php.net/manual/en/function.trim.php). Do you remember the [order of operations](https://www.cuemath.com/numbers/pemdas/) in math (PEMDAS)? The same concept applies to … | |
Re: Try this (not tested): ``` $wallet = $user->wallet; if ($sell_video == 0 && $wallet >= 1) { $db->rawQuery("UPDATE ".T_USERS." SET `wallet` = " . $wallet - 0.5 . " WHERE `id` = '".$video->user_id."'"); } ``` | |
Re: This is nothing new, and I am just adding to what others have already contributed. I'm assuming you will be using PDO for this, so this may be what you are likely looking for (not tested): $fuzzy_array = [ '%' . $search_term .'%', '%' . $search_term .'%', '%' . $search_term … | |
Re: In your [previous post](https://www.daniweb.com/programming/web-development/threads/539189/i-m-having-trouble-w-if), you mentioned that: > "ctltbl" is 1 row That leads me to assume that the row has only two values `id` and `expiry`, so that `$expiry` in line 10 refers to the `expiry` value in the result. If so, try this (tested): <?php $link = mysqli_connect("localhost", … | |
Re: Well, they are hitting all the right notes: "discreetly (sic)" "60-40%" (better than 1%) "legally obtained" "banking details" "my number" "keep this private" "legitimate fund" "transferred legitimately" Looks legit | |
![]() | Re: > But the query is not catching. What do you expect the query to return? |
![]() | Re: Try this: echo preg_replace('/@[\w+]/', '@' . ucfirst ($str[1]), $str); or echo preg_replace('/[@][\w+]/', $str[0] . ucfirst ($str[1]), $str); |
Re: $date = (new DateTime())->format('Y-m-d\\TH:i:s.vP'); echo $date; Outputs: 2022-11-17T08:07:33.043-05:00 | |
Re: If you haven't done so already, check out https://codejava.net/java-se/jdbc/connect-to-apache-derby-java-db-via-jdbc | |
![]() | Re: Assuming that your query `SELECT * FROM users WHERE username IN ('test','Test')` result is `$user` as: 0 => [ 'user_id' => 1, 'username' => 'test' ] 1 => [ 'user_id' => 2, 'username' => 'Test' ] Output is: <a href='#' title='1'>@test</a> <a href='#' title='2'>@Test</a> Seems to me that it DOES … ![]() |
Re: The problem is in your column distribution. Try this: .container { display: grid; grid-template-columns: 1fr 1fr 1fr 1fr; grid-template-rows: 1fr 1fr 1fr; grid-template-areas: "header header header header" "leftsidebar main-top main-top rightsidebar" "leftsidebar bottom-left bottom-right rightsidebar" "footer footer footer footer"; } This will fix bottom-left, bottom-right, and also both side bars. | |
Re: > But why it fails to extract further xml sitemap links from this following particular xml sitemap ? That is the big issue! https://bytenota.com/sitemap.xml It is not failing. That particular XML sitemap (https://bytenota.com/sitemap.xml) does not list more XML files. Unlike with www.rocktherankings.com, it is not a `sitemap_index.xml` file. **Update:** If … | |
Re: Howdy! Maybe this article will point you in the right direction to determine when to stop crawling: https://seosly.com/blog/how-to-find-sitemap-of-website/ | |
Re: Disclaimer: I am not a sitemap/seo expert (or an expert in anything else, for that matter). Correct me if I'm wrong, but I think that in order to find the sitemap, you would have to crawl the website anyway. You would start by looking for the sitemap. If you find … | |
Re: How about https://github.com/PatrickZurekUIC/PHP-OOP-Converter (I haven't tested it) | |
Re: "Easy to use" is a very subjective term. What may be easy to use for me, might not be so for you, and *vice versa*. It also depends on the types of features you want on your website. In any case, I'm sure you've already googled for [easy to use … | |
Re: There are two reasons why you are not getting the correct calculation for grand total. First, `$sub_total` is a string, not a number. Why? Because you are assigning to it a string, which results from using `number_format()` on `$fetch_cart['price'] * $fetch_cart['quantity']`. Second, even if `$sub_total` is not a string, you … | |
Re: This may be what you're looking for: https://codepen.io/ndaidong/pen/PpBwVz FWIW, I googled 'javascript move object with mouse' And here is nice, detailed post that you may benefit from: https://javascript.info/mouse-drag-and-drop | |
Re: Assuming that: 1. The structure is consistent and all posts and media counts will be displayed in that `<span>` tag, and 2. You are reading the HTML line-by-line, a regular expression could be useful. <?php $pattern = '/<span[^>]+>([\s\S]+)<\/span>/'; // @see https://stackoverflow.com/a/24029432 // Assuming that you fetch the HTML contents and … | |
Re: Here you go: <?php $sql = "SELECT pic1, pic2, pic3, pic4, pic5 FROM modelprofile WHERE name='$name'"; $result = $conn->query($sql); if($result === false) { trigger_error('Wrong SQL: ' . $sql . ' Error: ' . $conn->error, E_USER_ERROR); } else { while($row = $result->fetch_assoc()) { while(!empty($row)) { for ($pic_counter = 1; $pic_counter <= … | |
Re: You posted this same question to stackoverflow, where you received what I would consider very helpful suggestions, which are pretty much in line with what Dani is suggesting: *debug your code*. Running your code (including the form you edited out of your stackoverflow post), I see the following output after … | |
Re: Hi! I tried browsing to your sites with a few browsers (Chrome, Firefox, Opera, Safari), and the sites display correctly, which is subjective since I don't know what kind of "correctly" it is you are expecting (some screenshots might help). For me, the text is "normal" (?) and doesn't show … | |
Re: 1. Pay attention to grammar and punctuation. 2. Write your content so that a twelve-year-old can understand it. 3. Read. TL;DR I don't want to be THAT guy, but I suspect that if your responses on Quora are similar to your post and comment here, it could be that Quora's … | |
Re: I think the problem is in your update statement. Also, what are you trying to do in line 16? Perhaps you were thinking of assigning the value to another variable (e.g. `$id = $_SESSION['id'];`)? Try: $sql = "UPDATE supplies_table SET files = ? WHERE id=" . $_SESSION['id']; This assumes that … | |
Re: A single line of PHP code? Sure! <?php echo '<div><p>I am not floating.<span style="float: right">Look at me floating!</span></p><div>'; ?> This resource might be helpful to you: https://developer.mozilla.org/en-US/docs/Web/CSS/float | |
Re: So let me get this straight: so you have developed your website locally and want to include js files hosted on the Internet. If I am correct in that assumption, you can use a CDN, such as [Cloudflare](https://www.cloudflare.com/). Good luck! | |
Re: So, on line 60, you are calling a javascript function called `myfunction()` that does not appear anywhere in your code: Uncaught ReferenceError: myFunction is not defined onclick http://localhost/:1 localhost:1:1 onclick http://localhost/:1 | |
Re: I see a few things that stand out to me in your provider form-control snippet. First, in line 6 you are selecting `provider` twice from `mandates`. Perhaps that is not that big of a deal, but it seems unnecessarily redundant. `$prov = "SELECT provider,provider FROM mandates GROUP BY provider";` Second, … | |
Re: It seems that you first need to load [jQuery](https://jquery.com/) for `load()` to work. Something along these lines: <html> <head> <link rel="stylesheet" href="core/css/core-style.css"> <link rel="stylesheet" href="core/style.css"> // --- Load jQuery <script src="[path-to-jquery]/jquery-3.6.1.min.js"></script> </head> <body> <div id="menu"></div> <script> $(function(){ $("#menu").load("menu.html"); }); </script> </body> </html> | |
Re: Use the `disabled` property: <?php $sql = "SELECT closing_date FROM shows"; $result1 = mysqli_query($mysqli, $sql); while ($info = mysqli_fetch_assoc($result1)) { if (date('Y-m-d') > $info['closing_date']) { echo '<input type="submit" name="export_excel" class="btn btn-success float-md-right" value="Export to Excel">'; break; } else { echo '<input type="submit" name="export_excel" class="btn btn-dark float-md-right" value="Export to Excel" disabled>'; … | |
Re: If you're going to develop exclusively for Android, then use Android Studio as rproffitt suggests. However, if you want to go a step further, you could take a look at [Flutter](https://flutter.dev/) and use it to develop apps for Android and iOS using a single code-base. Of course, that means learning … | |
![]() | Re: If I understood correctly from the series or replies above, you want to strip HTML tags from `technical`. Of course, `htmlentities()` would not work because it prints out the tags instead of parsing them. Your regex looks like a good start, but the replacement you are using (empty '') will … |
Re: rproffitt's solution would be ideal. Another way could be without resorting to a database. 1. Read the folder where the file will be saved. 2. If the folder is empty, add 000001 to the filename, then upload the file. 3. The folder is not empty and, assuming that previous files … | |
Re: Making it Joe's instead of Joe would make it possessive (as belonging to Joe), not plural (as referring to many people named Joe). | |
Re: You could try [PHPMailer](https://github.com/PHPMailer/PHPMailer). Read their documentation: it is very thorough. One thing to consider is that, because you do not have user registration, you should first validate the email entered by the user, to make sure it belongs to them and not someone else. Otherwise, you risk your service … | |
Re: Would you be willing to share what Topic 1 to Topic 3 are all about? It seems that you are seeking help with a homework assignment. Nothing wrong with that. We can help you understand the problem and guide you to find a solution for yourself. In order to do … | |
Re: This might be a good place to start: https://www.geeksforgeeks.org/find-all-ranges-of-consecutive-numbers-from-array/ | |
Re: This is just a shot in the dark, but what steps have you taken to troubleshoot the issue? I guess I would start by making sure that (i) your connection to the database is successful and (ii) that the file exists on the server. Next, ensure that you get the … | |
Re: Your `cases` are surrounded by double quotes. Replace the double quotes with single quotes: #include<iostream> using namespace std; int main() { char LtrGrade; cout << "Enter a letter grade: "; cin >> LtrGrade; switch (LtrGrade) { case 'a': case 'A': cout << "\nExcellent"; break; case 'b': case 'B': cout << … | |
Re: I'm curious to know how you solved the problem. Cheers! | |
Re: I'm putting on my Captain Obvious hat, but could it be that you are using `.html` instead of `.php` for your file extension? test.html `<?php echo 'test.html'; ?>` Will display a blank page. When you view the source code, you will see the echo statement. test.php `<?php echo 'test.php'; ?>` … | |
Re: Change `COMMAND` to `Command` in line 20. From: https://dev.mysql.com/doc/dev/connector-net/6.10/html/M_MySql_Data_MySqlClient_MySqlCommand_ExecuteReader.htm | |
Re: My experience with Java is limited, but I have encountered this several times. `"input == null"` means that the file requested in line 44 of your code snippet could not be found. This could be due to several factors, such as case-sensitive file names, the wrong path, or the file … |
The End.