help with multiple arrays

Looking for volunteers to join your project? Need help with a script but can't afford to pay? Want to offer your services as a volunteer to build up your portfolio? This is the place for you...

Moderator: General Moderators

Post Reply
niravdave
Forum Newbie
Posts: 1
Joined: Mon Jun 01, 2009 9:21 am

help with multiple arrays

Post by niravdave »

hi Guys,

Someone helped me with this code, but I need futher help. I am using this code to pull some information for subcategories on my pages.

I want to implement this code in the meta section for Title, Keywords & description for seo, so i can write my customised title, keyword and description for each subcategory. I believe there will be 3 arrays involved, i tried my best but failed. help much appreciated. As an appreciation token, I will buy you a beer. :)

Code: Select all

 
$Title = array();
 
function AddTitle($ID,$TitleTxt)
{
global $Title;
$Title[$ID]=$TitleTxt;
}
function GetTitle($ID)
{
global $Title;
return $Title[$ID];
}
 
 
AddTitle(1,'This is for subcategory one.');
AddTitle(2,'This is for subcategory two');
AddTitle(3,'This is for subcategory three');
 
 
echo GetTitle($xsubcatid);
 
 
 
please help
dave
User avatar
a94060
Forum Regular
Posts: 543
Joined: Fri Feb 10, 2006 4:53 pm

Re: help with multiple arrays

Post by a94060 »

wrong forum. This should be in PHP - Code
Post Reply