Hi I want to get multiple rows from a db
I am using this for the db query
Code: public function getCeleb($product_id) {
$query = $this->db->query("SELECT * FROM " . DB_PREFIX . "product_to_celeb WHERE product_id = '" . (int)$product_id . "'");
foreach ($query->rows as $result) {
$celeb_id = $result['celeb_id'];
}
return $celeb_id;
}
and this to display the returned data
Code: 'celeb_id' => $result['celeb_id']
print_r ($celeb_id);
the problem is i only get one result from the database and i have multiple entries with the same id
thanks in advance
help me, how to find text on an external html site using PHP
Would anyone know how to search an external html file for a work or phrase ?I was thinking something like this --I use script cURL...Code: <?phpif (isset($_POST['submitted'])) { $xurl_1 =
How to replace search button with link?
hi to everbody.i have a search submit form and button like this :<form id="f1" name="title" method="post"
Show specific day of the week
I have been racking my brain trying to get this function to work properly and it is doing so for everything but Sundays. What I am trying to do is display all dates within a specified date range that
remove innitial
and
tagsi am using tiny_mce as a text editor for my CMS.buy now the problem is it add <p> tag with dataso while retrieving the data for front end i get an extra space. so there is any why that i
how to validate date using javascript
I need to validate date in textbox using javascript..The date is must be not greater than TODAY date and not less than before 3 months ..If either of these conditions is fails will show the prompt
quick basic question, hopefully not dumb
I don't know how to search for this, so forgive me if it's been covered...I often see an example like this:$a = $b . " " . $c; // concatenate strings with spaceI'm wondering if there is
DB2 for z/OS, LUW, iSeries
Hello,
Using cURL to PUT
Can somebody help with the correct php code to make a cURL PUT request. Here is a sample of code below that uses POST, but I need to modify this one so that it uses PUT instead.Code: <?php
question about header() security
is is safe to just use the header() function to redirect someone if they are, say, not logged in? or should i always put a die() function underneath the header() function?
What are the two different files you download to update kernel?
What are the two different files you download to update kernel?