The smartsite paging macro is very useful macro for paging through the results of long queries. A basic implementation of the paging navigation is very straightforward with the extension vipers of the paging macro. This example uses the paging macro. No further recordset is provided and no recordcount can be calculated, so the totalcount parameter is used. The result of the extension vipers is an url to the same page with some querystring parameters. Before iXperion 1.1 the url was enriched...
Posted by Erwin Rijss on Wednesday, July 08, 2009 7:43:31 PM
-
5 comments
Vipers are very strong programming directives for creating logic and displaying data. Vipers can be used, for example, to create decision trees. At first you would think about the If macro and the Switch macro to create flow and branching but there are Viper equivalents as well: sys.iff() and sys.choice(). The result of the branching is often some HTML. One of the problems you'll encounter is the fact that the -sign cannot be used within your Viper. An example: The viper above will generate an error....
Posted by Erwin Rijss on Wednesday, August 29, 2007 10:15:38 AM
-
3 comments
Creating a mechanism for posting comments is just a simple form. Once posted, an SQLQuery macro can be used to insert the posted data in a comments table. JavaScript and an item of contenttype Application Page, which contains the storage logic, would simplify the whole case. But it would be nice if a user could preview his comment before posting. With JavaScript, and especially AJAX, it is a piece of cake. But the guidelines for web-applications predicts us to make this application work without JavaScript...
Posted by Erwin Rijss on Tuesday, August 28, 2007 11:33:45 AM
-
3 comments
A weblog is easily created by creating two simple contenttypes: Blog and Blog Entry. Both contenttypes can be derived from the Web Page contenttype. The Blog contenttype stores basisc information about the author and a short introduction. The Blog Entry contenttype is used to add blog entries to the site. The Rendertemplate of the Blog Entry contenttype is straightforward: display the Title and Body field and create the opportunity to add some comments. The Rendertemplate for the Blog contenttype displays a...
Posted by Erwin Rijss on Monday, August 27, 2007 12:31:52 PM
-
0 comments
Formatting of datatables has become very sophisticated. Different parameters are available to order the data. The most-used of these parameters is, without doubt, the Rowformat parameter. This parameter formats each row of the datatable the way we want. Within the Rowformat parameter the local this.field() viper gives access to the different fields in the datatable Another powerful parameter is the Groupformat parameter. This parameter groups rows by a given field. All rows having the same value of a field...
Posted by Erwin Rijss on Friday, August 24, 2007 5:47:13 PM
-
0 comments