[TYPO3-Solr] TypoScript in ###IF:###
Stephan Schuler
Stephan.Schuler at netlogix.de
Fri May 4 11:59:17 CEST 2012
Hey Lars.
I guess you're mixing things (read: expecting things from subparts/marks hat you might have heard of from Fluid).
When using subparts and markers, they are just fetched and replaced. Think of the most basic things you can do with preg_match and str_replace. If there is some conditions or other kind of "calculation", it has to be done in pure typoscript (including user funcs, of course).
Every further magic (like your calculation of a condition, but I can think of something even more advanced) would not be part of the basic TYPO3 supart/marks/template handling but something very specific inside of one particular extension.
I don't know if the solr extension implemented such a thing. But I really hope it doesn't but stick to default behavior of TYPO3.
The thing you're trying to express is possible with Fluid. Not exactly, but almost.
<f:if condition="{settings.template.expandedCollapseLinks}">
<f:then>foo</f:then>
<f:else>bar</f:else>
</f:if>
But Fluid and subparts/marks don't play well with each other. It might work in some etch cases. But in general, they are completely different. You can use Fluid inside of subparts/marks as a text fragment, or you can use the output of subpart/marks in Fluid as a text block. But don't expect them to handover variables nicely.
Therefore:
If such a thing is already possible with solr, I would expect it to become deprecated in further versions and point to some Fluid rendering.
If such a thing is not possible with solr, I would not expect the TYPO3 core or the solr ext to implement it, since Fluid is already present and just ready for this.
Regards,
Stephan Schuler
Web-Entwickler
Telefon: +49 (911) 539909 - 0
E-Mail: Stephan.Schuler at netlogix.de
Website: media.netlogix.de
--
netlogix GmbH & Co. KG
IT-Services | IT-Training | Media
Andernacher Straße 53 | 90411 Nürnberg
Telefon: +49 (911) 539909 - 0 | Fax: +49 (911) 539909 - 99
E-Mail: info at netlogix.de | Internet: http://www.netlogix.de
netlogix GmbH & Co. KG ist eingetragen am Amtsgericht Nürnberg (HRA 13338)
Persönlich haftende Gesellschafterin: netlogix Verwaltungs GmbH (HRB 20634)
Umsatzsteuer-Identifikationsnummer: DE 233472254
Geschäftsführer: Stefan Buchta, Matthias Schmidt
-----Ursprüngliche Nachricht-----
Von: typo3-project-solr-bounces at lists.typo3.org [mailto:typo3-project-solr-bounces at lists.typo3.org] Im Auftrag von Lars Peipmann
Gesendet: Freitag, 4. Mai 2012 02:16
An: typo3-project-solr at lists.typo3.org
Betreff: [TYPO3-Solr] TypoScript in ###IF:###
Hy there,
I tried this code to use one results.htm for different pages/searches:
<!-- ###IF:###TS:plugin.tx_solr.template.expandCollapseLinks###|==|1###
begin -->
...
<!-- ###IF:###TS:plugin.tx_solr.template.expandCollapseLinks###|==|1###
end -->
In my case it is not working. Did I something wrong, could there be a bug in the code or would it be a new feature?
Best, lars
_______________________________________________
TYPO3-project-solr mailing list
TYPO3-project-solr at lists.typo3.org
http://lists.typo3.org/cgi-bin/mailman/listinfo/typo3-project-solr
More information about the TYPO3-project-solr
mailing list