Hi,
My database has the following setup
productid | productname | category id
and I want to output them like so:
category #1
item 1
item 2
item 3
category #2
item 1
item 2
item 3
I used group by the group them together and that works fine, but I want to loop through each group and display the contents of that group. How would I...
My website uses:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
And this meta:
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
I created my database and tables in phpMyAdmin making sur...
Looking for a reg ex to null (empty) the string if it any contains the bad word..
$string1 = "Ihatestackoverflow";
$string2 = "I HaTe sackoverflow";
$string3 = "1HaTestackoverflow";
$badword = "hate";
# result
# string1 = "";
# string2 = "";
# string3 = "";
...
Hi
Anybody know how to send values like Name, email, city, country, phone etc to populate the new account form on the paypal checkout page? I am taking billing and shipping address on my site only. just want to send the same to the checkout page so that the user won't have to fill it up again on that page.
I am using the paypal ipn cla...
I'm working on a model that tracks user data and stores it in a session, where appropriate. Here's the basic structure of it:
public function __construct() {
parent::__construct();
$this->load->database();
$this->load->library('session');
if (!is_null($this->session->userdata('user'))) {
$arrData = $this->sess...
Right due to not getting the right answer last time, I will reword this.
I want to create a page where all fixtures from 'tbl_fixtures' are shown.
id - compname - home_user - home_team - away_user - away_team - date
That is the table setup.
The date column is a timestamp.
I want to show all fixtures in blocks based on the date column...
Is there a canonical function/method for escaping a string to be used in a preg_, such that any special PCRE characters will be interpreted as literal. Basically, a know way to ensure that something like
I am a fancy string (well, that guy ... said I was fancy)
is transformed into
I am a fancy string \(well, that guy \.\.\. said I ...
Hi all,
I have a form (that consists of 25+ fields) and the values for these fields, range from a tiny value to a concatenated string. This is like a search tool. Now when the user fills the form and submits the info, he gets to see all the relevant data that matches the criteria in the form. I am displaying 15 records at a time to the ...
I have a question about markItUp!'s preview function.
Inside jquery.markitup.js i have these settings:
previewTemplatePath:'~/templates/preview.php',
previewParserPath:'~/templates/preview.php',
previewParserVar:'data'
I'm not sure what to do with previewParserPath and previewParserVar. Is it possible to grab the content sent by mark...
Hi,
This question is already asked/answered by other members but my case is a bit different..
Problem: How to reverse words in a string? You can use strpos(), strlen(), substr() but not other very useful functions such as explode(), strrev() etc.
This is basically an interview question so I need to demonstrate ability to manipulate st...
Hey,
I'm having problems with cookies on my website. After validating user credentials, the following code is executed if "remember me" is set:
session_start();
$_SESSION['username'] = $myusername;
if(isset($_POST['remember'])){
setcookie("cookname", $_SESSION['username'], time() + 60 * 60 * 24 * 100, "/");
}
Every page o...
>pecl install zip
got the following error:
checking for the location of zlib... configure: error: zip support requires ZLIB.
Use --with-zlib-dir=<DIR> to specify prefix where ZLIB include and library are located
what does this mean?
...
I want to 'echo' a string separated by delimeters like:
sergio|tapia|1999|10am
the Body of an HTML page.
How can I achieve this? Thank you!
...
I'm trying to set up a quick PHP demo using the Youtube API that adds a video (using its ID) to a pre-created playlist (using its ID as well). The documentation for the PHP API doesn't specify how to do this. I'm referring to this documentation: http://code.google.com/apis/youtube/2.0/developers_guide_php.html#Adding_a_Playlist_Video
Do...
I'm trying to access Gmail by using three-legged Oauth PHP code provided by Google ('google-mail-xoauth-tools') here: http://code.google.com/apis/gmail/oauth/code.html. I have my domain registered and everything seems to go fine with OAuth, but after I authorize access I get this error:
Fatal error: Uncaught exception 'Zend_Mail_Protoc...
I have an array with the following data:
[steamid] => stdClass Object
(
[0] => Shakyor
)
How can I get the 'Shakyor' string from there?
$array->$steamid doesn't work.
$array->$steamid[0] doesn't work.
$array->$steamid->0 is not legal markup obviously.
...
I want to implement a web page (using HTML/PHP, whatever else), that will populate data int the top half of the page (seem image below). The top half will contain links. When the user clicks on the links, I want to populate the bottom half of the page with detailed information about the item clicked on in the link in the upper half of ...
Hi there! I'm working on a real estate site and need to make notification mailer: when new property is inserted on a site, people who subscribed for notification in that particular country and/or area and/or city and/or particular property operation (rental, selling) will receive a notification on email. One person could subscribe for di...
i wonder if there is open source cms coded in python that is as big as drupal (joomla or wordpress)?
thanks
...
In my Symfony 1.4 project I am using the doctrine:generate-admin task to create the modules that compose my backend system. One such module is "journeys". When I view the source of the "journeys/new" page (which displays the form to create a new journey entity) the action of the form is simply "journeys" (I expected it to be "journeys/cr...