Date index for Jan 2004


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: [achievo] include link in email to modify project directly



I got this message in response to a similar question I asked a bit ago. Hope
it helps.

Robert

Start Message
Hi,

Robert Beguiristain wrote:

[cut]
 http://SERVER/dispatch.php?atknodetype=todo.todo&atkaction=edit&atkselector
=todo.id=4942
[cut]


End Message

Thanks for the helpful tip. I'm sure it's of some use to users. I may
add this functionality to standard Achievo in the future.

I've got an additional tip. If you add &atklevel=-1 to the urls you use
directly in mails, then you're sure not to have the session data mixed
up. If you leave out the atklevel=-1, things may go astray when you
already had an Achievo window open and then open the link from inside
your mailclient.

As you may notice, all urls opened from the main menu also have -1 as an
atklevel.

What's even better, if you generate these links from inside Achievo
somewhere, there's a function you can use to generate such a
'session-safe' url for you:

$url = session_url(
          dispatch_url("todo.todo",
                       "edit",
                       array("atkselector"=>"todo.id=4942")
                      ),
          SESSION_NEW);

(indented for readability)

If you use this, then several things are done for you.

First, dispatch_url calls the correct dispatcher (usually dispatch.php),
and properly urlencodes the atkselector parameter.
Second, the session_url method will wrap some session variables around
your url to make it session safe.

Greetings,
Ivo


[ Achievo mailing list - http://www.achievo.org/ ]
[ to unsubscribe send an e-mail to achievo-unsubscribe dot 

http://www.achievo.org/lists achievo.org - ©1999-2002 ibuildings.nl BV