'redirect' switch


Say, after creating a new story you want to redirect the user to the frontpage instead of presenting the rendered story. Because of editor actions are redirects built-in to the app source we need a snip of javascript to make it work the way we want.

We can use the <% response.message %> macro - it usualy displays status messages above the main content area, depending on the action and the success state of the action. That messages are strings, defined in the 'messages.properties' file of the blog-default language. [1]

E.g. successfully creating a new story sets the response.message to the value of 'confirm.storyCreate'.

This is just what we need to create our own redirect-hook. Whenever a new page is loaded, we check for the value of response.message and let our own action roll.

Example code works like so:

...


link   
 


antville.TagCloud


hey, i wanted to do that since a very long time, but never came around to it.

The antville.TagCloud is currently in beta and while i am testing a few more, tricky features, here is some documentation on the widget.

          • < - - - - -

The base data is the feeds and change-date information provided by antville.org - so, in a way we are taking the blogs subdomain names for tags themselves. The result is a visualisation of how often a blog is changed over time. The data is aggregated and a Javascript file is written every 10 minutes. That file can be included/called from your skin using a script tag, a user defined stylesheet can be applied to the data, like so....

- - - - - >< - - - - -

That's all for now, a demo is available at the smileys blog - comments are welcome.

-- enjoy



link   
 


Link to a single day


  Layout / Site Layout / Main page of a single day ... Whenever a user selects a single day via the calendar, this skin will be used to display the list of stories of this day.

problem: say you removed the calendar widget from the skin, but you need to create a link to the most recent "Page of a single day" (to get an offset for the built-in day-navigation: "older / newer stories")

solution: in your skin compose the link like this ...

Latest Stories

... that should create a link like this one -- Latest Stories

-- Antville Macros » site.lastupdate



link   
 
 
Online for 8206 days
Last update: 09.05.08, 08:12
»Preparing for sodium amytal«
status
Youre not logged in ... Login
recent
mks @ 25k posts
    hohoo - looks like [mks] will see its 25.000th...
by KenoshaKid (11.12.07, 15:53)
'redirect' switch Say, after creating
a new story you want to redirect the user to...
by KenoshaKid (02.12.07, 12:54)

November 2024
So.Mo.Di.Mi.Do.Fr.Sa.
12
3456789
10111213141516
17181920212223
24252627282930
Dezember
menu
... home
... topics
... Home
... Tags


... antville home

RSS Feed

Made with Antville
powered by
Helma Object Publisher