sasa
-
Posts
2,804 -
Joined
-
Last visited
-
Days Won
1
Posts posted by sasa
-
-
try
$query = "UPDATE contacts SET merchant_id$i='".$new_mid."' WHERE merchant_id$i='".$old_mid."'";
remove dots
-
change to
ORDER BY 'posts'.'post_date' DESC";
change comma to dot
-
change to
$datoformat = array(); foreach($result as $results) $datoformat[] = date("Y-m-d", strtotime($results->date_time)); $datoformat = array_map('trim', $datoformat); $values = array_count_values($datoformat); $yesterday = date('Y-m-d', strtotime("-1 days")); $total = $values[$yesterday]; echo $total;
-
add modifer s
$regex = "~<b>Address:</b>.*?</p>~s";
-
are you shure that your Value1 isn't '2,213.54'?
-
you insert email in 1st try block
in this query
$mysqli->query("INSERT INTO coming_soon_emails VALUES('email', SUBSTRING(MD5(UUID()),FLOOR(RAND()*25),5), UNIX_TIMESTAMP())");
you try to insert string 'email' not value of variable $email
if you tray to insert variable $email it didn't work to because $email is inserted before in try block
change your 2nd query to UPDATE or 1st to SELECT
-
try to trim variable first
$name = ucfirst(strtolower(trim($results[$i]['name'])));
-
change
if(isset($_GET['question'])) { $question = $_GET['question']; $query .= " WHEN qid is '$qid' LIMIT 0, 1"; }
to
if(isset($qid) { //$question = $_GET['question']; $query .= " WHERE qid = '$qid'"; }
-
$email=$row ["email"];
remove $
-
$name = preg_replace("/ /", "", $name);
but for this i use str_replace() function
-
remove break; commands from your code
it's cause that just 1st loop execute
-
preg_match_all('~<tr\sbgcolor="#CCCCCC">\s*<td\salign=right></td>\s*<td\salign=center\svalign=center\swidth=10><a\shref="(.*?)">~siU', $data, $link);
-
you can do it in MYSQL with LPAD() function
http://dev.mysql.com/doc/refman/5.0/en/string-functions.html#function_lpad
-
you query returns more than 1 result but you print just one
-
you must filter results to given set and then order
SELECT book_id, book, book_display FROM books WHERE book_status = 'active' AND FIND_IN_SET(book_id, '13,4,5,6,7,8,9,10,2,3' ) ORDER BY FIND_IN_SET(book_id, '13,4,5,6,7,8,9,10,2,3' )
-
can you print_r ($_POST) and post results
-
you can order your table with FIND_IN_SET() function
SELECT ... FROM ... WHERE .... ORDER BY FIND_IN_SET(id, '1,4,5,6,7,8,9,10,2,3')
-
try
<?php $url = 'http://www.amazon.co.uk/gp/offer-listing/B002PLB2F4/?condition=new'; $html = file_get_contents($url); preg_match_all('~<ul class="sellerInformation">.*?(alt="|<b>)([^"<]+)("|<)~is', $html, $matchesarray); print_r($matchesarray[2]); ?>
-
try
<?php $test = 'slika.jpg | http://preview.filesonic.com/img/350541.jpg'; $test = explode('|', $test); $dest = trim($test[0]); $sorc = trim($test[1]); copy ($sorc, $dest); ?>
-
$bool = ctype_alnum($text) and !ctype_alpha($text);
-
shure you can
-
try in this way
echo "<form action='editevent.php' method='get'><input type='hidden' name='eventid' value='{$row['eventid']}'><INPUT TYPE='submit' name='submit' VALUE='Edit'></form>\n";
-
you must fetch result
$row = mysql_fetch_array($result);
and after test against $row['group']
if($result["group"]==1){
-
change method atribute to get
subject or add 0's to a barcode
in PHP Coding Help
Posted
somthing like this