Search:
Type: Posts; User: The Little Guy
Search :
Search took 0.08 seconds.
Your going to need to explain this a bit more.
the best way is to add unique keys to your table. So, depending on what columns need to be unique is what you would put the key on examples:
email, username -- This would require that the email...
Do you really want to do that?
Remember Databases can hold TONS of data and still run at lightning speed. So you can then just search for information between certain dates, for example:
...
You can write a cron job in any language you wish, as long as the server can run/understand the file.
purging the database contents isn't always a good idea, so you may want to think whether you...
are you trying to build averages? if so, you should store each vote in a table.
article_id | vote | date | ip
then you can easily get an average:
select avg(vote) as average from votes...
I would write a mysqldump cron:
cron.sh:
#!/bin/bash
mysqldump -h localhost -u superuser -pmy_pass myDatabase table1 table2 table3 > ~/myfile.sql
mysql -h localhost -u superuser -pmy_pass...
create table mytable2 select * from myoriginal where 0;
Try this:
Select *
from uploads left join documents on (uploads.user = documents.user)
WHERE uploads.user = '$userID'
ORDER BY uploads.title ASC, documents.title ASC
I do orders on tables with 500 million rows, and it runs in under 2 seconds. It just depends on how good your indexes are.
Mysql doesn't always put the new record at the end of the file, if...
You have two '?' in your query but only one replacement in your bind
I would revise that to this:
$Date4 = "";
if(!empty($row['field'])) {
$Date4 = date("D d-M-y", strtotime($person['om20']));
}
echo $Date4;
not sure, but I think you want to check out http://php.net/substr
Not sure what db your using by in MySQL you would do this:
SELECT count(*) as total, login_time from LOGIN group by login_time;
add a unique index to product_id, then with your insert do:
INSERT IGNORE INTO ....
by adding IGNORE, you don't add the row if it already exists.
also, you should use...
I just wanted to make it faster to use my library. The goal of the library is the same as jquery's goal, "Write less. Do more."
use() does work, but it is still not what I am after.
<?php
$live->get_http("http://godaddy.com")->callback(function() use($live){
echo "<h2>$live->title</h2>";
});
?>
echo it out, then copy and paste it into the terminal. Does it still work?
echo '/usr/bin/php -q /var/www/html/test.php '.$en.' > /dev/null 2>/dev/null &';
hmm... that isn't really going to help me :(
It seems as if this is the best I am going to get:
<?php
require_once 'phpLive.php';
$live->get_http("http://google.com")->callback(function(){ ...
Don't do that, that could be insecure. You really only want to pass reference values through a get, such as an id number to a unique value in a database.
I would stick with sessions, they are easy...
$total = count(glob("mydir/*.jpg"));
echo $total;
You might be able to do something like this:
(untested)
<?php
$sql = mysql_query("select name, id, dob, month(regdate) as cmonth from users order by month(regdate)");
$array = array();...
Okay, in jquery $ is created in the jquery.js file, when you call $ within a function you don't need to make it global because it already is.
example:
$("a").click(function(){
...
I would like to have it readily available as soon as I make the new Closure function (or what ever it is called).
So people who use this library don't have to make the instance global within the...
Yes, and assuming your using php, it would look something like this:
$conn1 = mysql_connect("mysite1.com", "123", "123");
mysql_select_db("mydatabase1", $conn1);
$conn2 =...
Like this:
select name, id, dob from users order by month(regdate);