IRC logs

20150304

Logs from channel #fedext on freenode - our official support channel.

IRC log range: 20150304*

20150304

  • 02:24:19 <TYPO3ua> Hello, all!
  • 02:25:47 <TYPO3ua> I have question ...
  • 02:28:19 <TYPO3ua> I about EXT: view ... OBSOLETE - Feature set now available in TYPO3 core
  • 02:30:27 <TYPO3ua> How to use the opportunities and functionality EXT: view without EXT: view.
  • 02:30:32 <TYPO3ua> ???
  • 09:49:55 <Kaimane> Using {v:iterator.filter(subject: '{Vehicle.Equipments}', filter: '3', propertyName: 'CategoryId')} but output is still "Array". My goal is to get all items of {Vehicle.Equipments} where CategoryId is 3: {Vehicle.Equipments.x.CategoryId}. But why do I get "Array"?`
  • 09:56:36 <NamelessCoder> Kaimane what would you expect f:iterator.filter to return, if not a filtered version of the input array? If you try to output an array directly in Fluid, it will just write "Array"
  • 09:58:42 <Kaimane> NamelessCoder: I expect a filtered version ;-) But how to work with that output "Array"?
  • 09:58:43 <NamelessCoder> you have to use that expression somewhere that an array is expected, like in <f:for each="{array -> v:iterator.filter(...)}">
  • 10:00:13 <NamelessCoder> and you can of course <f:debug> it. But outputting it as a string will not work.
  • 10:00:46 <Kaimane> Namelesscoder: <f:debug> does not work. It also outputs "array".
  • 10:01:27 <NamelessCoder> then you have some spaces around the value
  • 10:02:17 <NamelessCoder> <f:debug>{variable}</f:debug> debugs {variable. <f:debug>{variable} </f:debug> debugs {variable} as cast to a TextNode inside f:debug because it has text.
  • 10:02:48 <Kaimane> Okay. My fault. That does the trick: {v:iterator.filter(subject: '{Vehicle.Equipments}', filter: '3', propertyName: 'CategoryId') -> f:debug()}
  • 10:03:25 <NamelessCoder> your ideal expression, following all rules, might look like: {vehicle.equipments -> v:iterator.filter(filter: '3', propertyName: 'CategoryId') -> f:debug()}. Your variables are a bit oddly named
  • 10:03:47 <NamelessCoder> and by the way you never need to do '{variable}' *especially* when the variable is not a string.
  • 10:04:17 <NamelessCoder> {v:iterator(subject: vehicle.equipments)} is the same but does not try to create an additional TextNode
  • 10:31:49 <Kaimane> NamelessCoder: Thank you very much for your support. Now it works as expected!
  • 10:32:25 <NamelessCoder> yw :)
  • 10:33:57 <Kaimane> But there is another question: I use <f:alias map="{categories: {1: 'Kategorie 1', 2: 'Kategorie 2', 3: 'Kategorie 3'}}"></f:alias> and would like to output {categories.{i.cycle}} within the <f:alias> tag but fluid does not render the string. How to use an interator within a variable?
  • 10:35:46 <NamelessCoder> check the "Dynamic variable access" example on https://fluidtypo3.org/library/try-fluid-now.html
  • 11:03:39 <Kaimane> NamelessCoder: Okay, I have to use <v:variable.get/>. Works like a charm ;-)
  • 11:07:13 <Kaimane> Third and last question for today ... Is there a possibility to check if an array is empty? <f:if> does not the trick if the condition is {array} == ''. <f:debug> prints array(empty).
  • 11:07:55 <Akii> {arr -> f:count()} == 0
  • 11:10:17 <NamelessCoder> <f:if condition="{array}" else="This happens if empty" />
  • 11:10:35 <Akii> ah yes, that works as well
  • 11:10:39 <NamelessCoder> that's the most efficient way you can check any array/iterator ;)
  • 11:23:46 <Denyerec> NamelessCoder, if I want to checkout an extension based on its tag it's "git checkout 3.0.0" right ?
  • 11:24:05 <Denyerec> This gives the me "You are in detatched HEAD" state, but that's OK if I'm just consuming the extension and not developing it, right ?
  • 11:26:38 <NamelessCoder> if you have all the tags locally then yep. However, it should create a new branch for you - so I think you may not have all the tags
  • 11:26:54 <NamelessCoder> try "git tag" for a list
  • 11:27:39 <Denyerec> git tag shows the list of tags
  • 11:27:42 <Denyerec> I've done a remote update
  • 11:27:53 <Denyerec> Still can't fix this realURL tho, I was making sure the extensions were up to date.
  • 11:27:53 <NamelessCoder> and "git branch" says you're in "detached from x.y.z"?
  • 11:28:11 <Denyerec> "no branch"
  • 11:28:17 <Denyerec> I didnt do checkout -b
  • 11:28:23 <Denyerec> Just checkout <tagname>
  • 11:28:26 <NamelessCoder> yep
  • 11:36:56 <Denyerec> Right
  • 11:37:02 <Denyerec> So now I'm stuck where RealURL is set to Autoconf
  • 11:37:09 <Denyerec> and my entire site has numeric URLs
  • 11:37:11 <Denyerec> any advice?
  • 11:37:17 <Denyerec> Other than hanging myself before the client calls ?
  • 11:37:17 <Denyerec> :/
  • 11:39:35 <7F1AADL5V> [vhs] NamelessCoder closed pull request #778: [DOC] Add changes into CHANGELOG.md for 2.3.0 (development...changelog) https://github.com/FluidTYPO3/vhs/pull/778
  • 11:39:35 <21WABINKJ> [vhs] NamelessCoder pushed 2 new commits to development: https://github.com/FluidTYPO3/vhs/compare/2dd170cd631a...c7babfae54f8
  • 11:39:35 <21WABINKJ> vhs/development f3c4d62 Viktor Livakivskyi: [DOC] Add changes into CHANGELOG.md for 2.3.0...
  • 11:39:36 <21WABINKJ> vhs/development c7babfa Claus Due: Merge pull request #778 from InvisibleKind/changelog...
  • 13:21:55 <Denyerec> Anyone around who's worked with realUrl and tx-news
  • 13:22:01 <Denyerec> I have a headache I can't resolve :(
  • 15:41:52 <Denyerec> v:page.breadCrumb shows pages that are set to "hide in menu"
  • 15:41:58 <Denyerec> have I missed a parameter, perhaps ?
  • 15:44:53 <Denyerec> It's unclear in the oucmnetation what the defaults are.
  • 15:45:01 <Denyerec> showHiddenInMenu is shown in the usage example as "1"
  • 15:45:07 <Denyerec> which would suggest the default value is 1
  • 15:45:20 <Denyerec> Am I misreading that ?
  • 15:46:12 <Denyerec> In the code it's registered as FALSE,FALSE
  • 15:46:20 <Denyerec> So the documentation is misleading me there.
  • 15:46:26 <Denyerec> Either way, my page still shows :(
  • 15:46:33 <Denyerec> (Despite being set as hidden in menus)