- Strength to Increase Rep
- +0
- Strength to Decrease Rep
- -0
- Upvotes Received
- 2
- Posts with Upvotes
- 2
- Upvoting Members
- 1
- Downvotes Received
- 0
- Posts with Downvotes
- 0
- Downvoting Members
- 0
27 Posted Topics
Re: [code=sql]SELECT * FROM emails LIMIT (1, 10)[/code] That would be the SQL query for your first page. Then: [code=sql]SELECT * FROM emails LIMIT (11,10)[/code] For the second page. Repeat, and you have it | |
Re: If I were you, I would deal with this by using a foreach statement (and I'm presuming you're using mysql here): <?php $array = ( [8] => 3 [9] => 4 [10] => 5 [11] => 6 [12] => 7 ); foreach ($array as $item_id=>$item_qty) { // connect to mysql … | |
Re: Have you uncommented the extension in php.ini for mysqli? That may be your problem. | |
Re: Take a look [url=http://www.forum.jaoudestudios.com/viewtopic.php?f=13&t=103]here[/url] for a couple of small functions that will help you, in terms of handling user input. Also, if you're passing a variable from $_GET, then you can use a type-finding function to help your security. Eg. if you have something like "?id=53" in your URL, then … | |
Re: Ask your server host to change that (unlikely) or get a new one. That's the only way, probably. | |
Re: MySQL. Easy, look it up. I would think that if you had been using PHP for a year, you would know about the different SQL languages by now. Anyway, look up MySQL, and if you need to go get a book about it from the library. Making a database for … | |
Re: This is assuming of course, you're guarding against SQL injections, before you send all this stuff... | |
Re: Well, I don't know all your database, but here's a sample script I would use: [code=php] if (!logged_in) { $query1 = mysql_query("SELECT * FROM membersinfo WHERE id = 'president'"); while ($row = mysql_fetch array($sql)) { echo "<tr> <td>$sub_office</td> <td>$fname $lname</td> <td>$hphone / $cphone</td> <td>$eml</td> <td>$adress, $cty, $st $zp</td> <td>$sub_name</td> </tr>"; … ![]() | |
Re: Just wondering, where is line 40? But some errors I spotted: 1. Your "$ownerid = $_SESSION['id']" needs a semicolon. 1. I think that your if ((!isset($_POST['Buy Dog'])) has an extra parentheses at the beginning. 3. And finally, you don't need to keep on opening and closing the php tags. Unless … | |
Re: Ok... 1. When you do "$this->mail_id = $mail_id;", you're referencing the same thing. $this->mail_id is used inside functions to reference the variables in the parent class. So, basically, your email() function is unneeded. 2. Also, if all you're doing is echoing your query, and not using mysql_query, then obviously you're … | |
Re: Javascript and PHP can't go together. So is my information, anyway. | |
Re: Others would be $_GET, $_POST, and $_FILES. For a full list, see [url=http://hk2.php.net/manual/en/reserved.variables.php]here[/url]. | |
Re: Take a look [url=http://snippets.dzone.com/posts/show/2604]here[/url]. Rather simple, really. | |
Re: php.ini has a value to set the maximum execution time. In the .ini, it's max_execution_time. For your script, it would be set_time_limit ($seconds). Although if you have an execution time of over 30 seconds, you might have a problem with your script somewhere. | |
Re: I would not suggest you publish your password online. Also, can you be be more specific about your problem? | |
Re: I don't think your placement inside the HTML will make a different. Also, if you have to SELECT from different tables, then you can't really combine them. Well, you can with UNION, but I think separate queries from different tables would be better. | |
Re: Just as an added suggestion, if you have mostly HTML and not a lot of PHP, you can just post the HTML regularly, and then add the php in. For example: [code=php] <br /> <a href="activity_list.php?id=<?php echo $row['id']; ?>"><b>Activity List</b></a> <br /> <iframe frameborder="0" width="100%" src="activity_list.php?id=<?php echo $row['id']; ?>" > … | |
Re: 1. I'm presuming you're using MySQL? 2. What do you mean by "all the information held within the database"? Does that mean all the tables, or all the rows within the tables? If you means the rows within the tables, it's very simple [code=php] // connect to mysql and use … | |
Re: I'm also pretty sure that you need single or double quotations for your statements, i.e. $bank['bank_balance']. Also, it would make it a lot easier if you you highlighting for the code (i.e. [code=php]CODE[/ code]). | |
Re: Just don't use $HTTP_POST_FILES, sinces that's deprecated. You can just use $_FILES instead. | |
Re: MySQL is what you would want to use for your database. I would suggest you use PHP to access the MySQL, as is it really use to connect with that. ![]() | |
Re: OK, the W3schools form is nice, but that's just a html. To send mail, you would need to use php, and that's means you need to use some real code (i.e. not dreamweaver). The obvious function for that would be mail(). Also, to put it into a database, you would … | |
Re: I'm thinking with PHP you can just use str_match. But if you want something a bit more advanced, have you every looked at [url=http://www.sphider.eu/about.php]Sphider[/url]? | |
Re: Just asking for a "sample site" in php isn't that easy. What exactly are you looking for? | |
Re: First off, I would suggest you delete all that spam from your guestbook. Second, what is in recaptchalib.php? If there's something wrong, I would suggest you look at the page you included. | |
Re: [code=html] <form action="delete.php" method="post"> <input type="submit" value="Delete" /> </form> [/code] [code=php] <?php //delete.php mysql_query("DELETE * from exampletable"); ?> [/code] | |
Re: You need to put session_start() on the first line of your code. Otherwise, it won't work. |
The End.