[EuroPython] How do you make links go from the pulldown menus directly off the site?

Jean-Marc Orliaguet jmo at ita.chalmers.se
Thu Feb 10 10:18:15 CET 2005


Chris Withers wrote:

> Jean-Marc Orliaguet wrote:
>
>> as I said earlier the pulldown menu shows documents *inside* the 
>> site. The Wiki page lies outside the site. So either put a link and 
>> trust the ability of users to click on the link. Or use some 
>> javascript to do the redirection.
>
>
> Can you not rustle up a "link" content object which, when you go to it 
> directly (ie: /folder/mylink) returns a response.redirect to the value 
> of the object's 'link' field?
>
> When you go to mylink/link_view you get a normal view of the content 
> object, likewise with edit?
>
> cheers,
>
> Chris


Yes, indeed, it's easy but the thing is that the link widget is used on 
other pages,  so I'd have to create a new type of widget just för that...

But anyway, since the document portlet that showed rendered pages has 
been removed from the editing pages, the code can now be edited without 
the earlier redirection problem..

So the problem is solved already:
- put the javascript code (redirection / open a new page)  in the edit 
field of the "Propose a track" folder.
- save the changes

* to modify the inline script:
- go to the folder
- edit the folder
- modify the javascript code
- save the changes.

the only problem with the redirection is that the 'back' button won't 
work once one has left the site, but it should be easy to fix.  So the 
question is : redirection or new window?

Otherwise I don't understand why Laura says that it's impossible? is the 
problem the javascript code itself or the annoying redirection issue? 
because for visitors it looks very much possible :-).

regards /JM


More information about the EuroPython mailing list