[TYPO3-english] CoolURI + Macina Banners
Guus Leeuw Jr
guus.leeuw at itpassion.com
Tue Nov 2 07:47:10 CET 2010
Hello,
I'm trying to integrate Macina Banners with CoolURI. Shouldn't be too
difficult, as macinabanners works on the basis of a URL parameter called
tx_macinabanners_pi1[banneruid].
So I made an image banner with a link to page id 61
(/solutions/24x7-monitoring). This banner has uid=2.
Converting that is easy:
<part>
<parameter>tx_macinabanners_pi1[banneruid]</parameter>
<lookindb>
<to>SELECT title FROM pages where uid in (SELECT url FROM
tx_macinabanners_banners WHERE uid=$1)</to>
<t3conv>1</t3conv>
</lookindb>
</part>
The problem with this is that the title is then taken as full CoolURI URI:
http://www.mydomain.com/24x7-monitoring where as it should have been
http://wwww.mydomain.com/solutions/24x7-monitoring.
If I simply
<part>
<parameter>tx_macinabanners_pi1[banneruid]</parameter>
<lookindb>
<to> SELECT url FROM tx_macinabanners_banners WHERE uid=$1</to>
<t3conv>1</t3conv>
</lookindb>
</part>
the generated URL looks like:
http://www.mydomain.com/61/solutions/24x7-monitoring
So, I'm kinda at a loss as to what to look up. The page id by itself doesn't
help, and I can't quite figure out how to query the link_cache table based
on the parameter. Maybe there is a way to call a function that will get me
the full page path within my domain, which then would be sensible enough for
CoolURI to map back to a page.
Hmm... An Idea: Apparently, if I look up the url in
tx_macinabanners_banners, the generated URL becomes
/61/solutions/24x7-monitoring. What if I just simply make the whole
parameter disappear, much like cHash, would that help? Let's see... No,
doesn't help either. The generated link is then
/2/solutions/24x7-monitoring...
Anybody any idea as to what I should be generating in CoolUriConf.xml so as
to make the correct path (/solutions/24x7-monitoring) appear?
Regards,
Guus
More information about the TYPO3-english
mailing list