 |
 |
|
|
|
|
 |
|
|
Tips and Tricks
You asked for it, and we added it. We have so many great developers using ListX right now - it would be best to get some samples straight from the gurus who swear by it. View and Add your samples and tips here!
| You are not authorized to post a reply.
|
|
| Author |
Messages |
|
arijkens
 Posts:16
 |
| 07/12/2008 8:26 AM |
Alert
|
Hi, After a lot of reading, trial-and-error and strong coffee I found some solutions for issues with IIF, ISINROLE, ACTION, Confirmation and ESCAPING. I posted a few topics concerning this and after reading a lot of other forum topics I realised that I'm not the only one facing these issues. So, here are the solutions working for me. Please note: I am a new ListX user (two weeks now) AND not an expert in HTML/JAVE/DNN. So any remarks/ additions are welcome. Greetings, Arjan Example 1: Link Anchor with ACTION This is pretty straightforward and well documented in the help file. I only put it here to be complete...The action is performed when using the link. <a {ACTION,[FileID],OpenFile,,Message} href='#'>Anchor with ACTION</a> Example 2: Link Anchor with ACTION and Confirmation dialog The action is performed only when the user confirms, otherwise nothing happens. <a onclick="if(window.confirm('sure?')) {return true;} return false;" {ACTION,[FileID],OpenFile,,Message} href='#'>Anchor with ACTION and Confirmation dialog</a> Example 3: Link Anchor with Role checking and confirmation dialog The anchor will only be visible if the user is a member of role ROLENAME. When using the link a confirmation dialog pops up. For visibility purposes I did not enter more javacode in this example. {IIF,([FORMAT,"ROLENAME",{ISINROLE}]),"<a onclick=\"if(window.confirm('sure?'))\{ return true;\} return false;\" href='#'>Anchor with Role checking and Confirmation dialog</a>",""} Example 4: Link Anchor with Role Checking and ACTION The anchor will only be visible if the user is a member of role ROLENAME. When using the link, the action will be executed. {IIF,([FORMAT,"ROLENAME",{ISINROLE}]),"<a \{ACTION,[FileID],OpenFile,,Message\} href='#'>Anchor with Role Checking and ACTION</a>",""} Example 5: Link Anchor with Role checking, ACTION and Confirmation dialog The anchor will only be visible if the user is a member of role ROLENAME. When using the link, a confirmation dialog pops up and only if confirmed the action will be executed. {IIF,([FORMAT,"ROLENAME",{ISINROLE}]),"<a onclick=\"if(window.confirm('sure?'))\{ return true;\} return false;\" \{ACTION,[FileID],OpenFile,,Message\} href='#'>Link Anchor with Role checking, ACTION and Confirmation dialog</a>",""} Remember to enable (1.9) Use Compound Conditions and Math in IIF tags in the General menu for proper using IIF |
|
|
|
|
|
| You are not authorized to post a reply. |
|
|
|
ActiveForums 3.6
|
|
| Latest Post
|
 |
|
At R2integrated (formerly Bi4ce), we take support seriously. That's why we support our customers and DNN community with daily monitoring from our experienced engineering team. We ask that the first step taken is to read the relevant documentation and support forums prior to submitting any questions that may already be available or have been answered. We ask that you review the documentation that we provide for our products before posting a question.
The Forums are for our customers to chat, exchange ideas and strategies, and submit feedback. Please be sure to perform keyword searches for previous related forum responses.
To be helpful when submitting a new item, please include the following:
- DNN Version
- Module Version
- Admin Log Viewer Information
- Environment detail: Operating system, .NET framework version, database and version, IIS version, Browser version (if appropriate)
We always try to respond quickly and monitor the forums daily during business hours (EST). Occasionally, requests for a specific project requirement may not apply for the free support offered. For project specific support please submit via our Information Request form.
Thank you for using our Forums.
Click here to register for the Forums
|
|
|
|
| © 2008 by R2integrated (formerly Bi4ce) | DNN® is a registered trademark of DotNetNuke Corporation
|
 |
|
|
|
 |
 |