-
- 2 Posts
Hi,
maybe I miss something but I tried to make a tv visible on certain pages only and get to no result.
My first problem is to create a rule with a correct constraint to affect a certain page only. According to the docs I used the following params:
Action: core-resource/update
User Group: A certain user group of my installation
Field: tv9 (tv with id 9)
Containing Panel: modx-panel-resource
Rule: tv visible
Value: 0 (for testing to just hide it from that page to see if it works, should finally be 1 )
Constraint Class: modResource
Constraint Field: id
Constraint: 2 (page id 2)
The result is that the tv now is hidden from ALL pages. Seems my constraint settings are not working. Do I have entered the wrong values?
The second question is how to show the tv for certain pages (defined by id) only: Since all tvs are visible for all pages by default, I don’t think I can just set the rule-value to 1 for visibility, right? Thus, do I have to create a first rule that hides the tv from all pages first and then create a second rule to make it visible for the pages I like to have the tv visible?
Thx for help.
-
- 49 Posts
i have same question... is it real?
dont work constraint with tvs!
maybe here is an example of plugin with wich i can do it?
I've had the same problem; it doesn't appear to work as expected. Any constraints will apply to all resources, not just the one specified.
-
- 24,544 Posts
Did you try modx-panel-resource-tv instead of modx-panel-resource?
------------------------------------------------------------------------------------------
PLEASE, PLEASE specify the version of MODX you are using.
MODX info for everyone:
http://bobsguides.com/modx.html
I've tried leaving the TV in the modx-panel-resource-tv region, nothing changes. Rule still applies to all pages.
Using MODx 2.2.4-pl (traditional)
Hi, will this be fixed for the next version 2.2.6?
Thanks
Web development (Barcelona, Spain)
..............................................
Bryte Digital Dialogues
..............................................
Calle Nicaragua 48 5º 5ª,
08029 Barcelona, Spain
[email protected]
T +34 93 419 64 39
www.bryte.es
www.bryte.nl
In think I have found a "Work arround":
1. Create new profile (example: only show certain TV for specific resource)
2. Create new set
3. Create a new tab, and assign TV with your constrain (rule). Let´s say only for resource with id = X
4. Show or hide TV ( in my case only show when resource id = x)
5. Set the region. (title from the new tab)
6. Activate
Go back to you first set and put "modx-panel-resource-tv" invisible.
Web development (Barcelona, Spain)
..............................................
Bryte Digital Dialogues
..............................................
Calle Nicaragua 48 5º 5ª,
08029 Barcelona, Spain
[email protected]
T +34 93 419 64 39
www.bryte.es
www.bryte.nl
-
- 534 Posts
Seems quite interesting, but I could not fully follow =),
I'm stuck at step 3 where I should add the constraint, cant find this in the TV tab of the set-settings^^... could you eventually make some screenshots (picasa or so is nice to host them, see mine above)?
[ed. note: exside last edited this post 11 years, 5 months ago.]