stryka
12-29-2006, 09:22 PM
Ok... here's the scenario...
Calling a function that returns a data store array that is stored into cache and I want to sort against that array... Ultimately, i will be calling the cache various times and would like to sort differently on particular calls...
Question1: What is the syntax to sort before my "foreach"
Question2: How do I sort against other fields within the array
Here's how i thought it would work... without sorting on a particular field...
...
...
//test_cache has already been defined with multiple fields and records being returned...
$teststore = $vbulletin->test_cache;
}
ksort($teststore );
foreach ($teststore AS $teststore )
{
eval('$test_template.= "'.fetch_template('test_template').'";');
}
but i don't see any results...
Calling a function that returns a data store array that is stored into cache and I want to sort against that array... Ultimately, i will be calling the cache various times and would like to sort differently on particular calls...
Question1: What is the syntax to sort before my "foreach"
Question2: How do I sort against other fields within the array
Here's how i thought it would work... without sorting on a particular field...
...
...
//test_cache has already been defined with multiple fields and records being returned...
$teststore = $vbulletin->test_cache;
}
ksort($teststore );
foreach ($teststore AS $teststore )
{
eval('$test_template.= "'.fetch_template('test_template').'";');
}
but i don't see any results...