Hi!
I'm stuck with something like this:
In my database I have two type of links
- Company
- Product
Each Product link has one custom field called "CompanyID" and it
contains "ID" value of Company link.
The problem is:
Currently I am using this global to grab Title and URL
sub {
return $DB->table('Links')->get($_[0]);
}
and <%CompanyInfo($CompanyID)%> to show Company data.
But, this has to be placed at the end of the link template, because if it is placed
at the beginning of link template, all the Product data (Title, URL and other stuff)
are pulled from Company instead of Product link.
Is there a way (and I bet there is :) ) to create a global which will
pull data from Company without messing my Product display.
I just hope that you will understand this mess :)
Thank you!
I'm stuck with something like this:
In my database I have two type of links
- Company
- Product
Each Product link has one custom field called "CompanyID" and it
contains "ID" value of Company link.
The problem is:
Currently I am using this global to grab Title and URL
sub {
return $DB->table('Links')->get($_[0]);
}
and <%CompanyInfo($CompanyID)%> to show Company data.
But, this has to be placed at the end of the link template, because if it is placed
at the beginning of link template, all the Product data (Title, URL and other stuff)
are pulled from Company instead of Product link.
Is there a way (and I bet there is :) ) to create a global which will
pull data from Company without messing my Product display.
I just hope that you will understand this mess :)
Thank you!