|
Posted by Andz on 08/13/07 06:19
I'm using explode() to extract and make an array() readable. I'm able
to make the array() from dbase readable.
categories_table {
catid name
1 'test1'
2 'test2'
3 'test3'
}
implode_table {
email catid
test@local 1,2,3
help@local 2,3
}
For example, if test@local logged in to the system, how can test@local
load all the information of the catid he selected?
My code for the moment fetch only all the catid that's being saved
under test@local account.
foreach (getImplodeCategoriesByEmail($email) as $explodeCat) {
$delimiter = ",";
$content = $explodeCat['catid'];
$splitContent = explode($delimiter, $content);
foreach ($splitContent as $result) {
echo $result;
}
}
Assume that getImplodeCategoriesByEmail($email) is fetching all the
records that match the email. This piece of code worked.
It gives me a result of 123.
THE PROBLEM: HOW CAN I LOAD ALL THE INFORMATION OF THE EXTRACTED
CATID???
The output should be like this
1 test1
2 test2
3 test3
What query AND how to implement it? If possible, please include
code.... THANKS and MORE POWER!!!
Navigation:
[Reply to this message]
|