[Moin-user] Changing a default action on a page

Dexter Arver darver at vmware.com
Mon Jul 2 14:15:12 EDT 2007


I did what you were trying to do by modifying MoinMoin/Page.py. Basically,
just inject an html form like this (around line 1248) : 
"
            loginform = '''
<form action="" method="POST">
<div class='userprefs' lang="en" dir="ltr">
<input type="hidden" name="action" value="login" />
<table border='0'>
  <tr>
    <td> <b>Name</b> </td>
    <td> <input type="text" name="name" size='32' /> </td>
  </tr>
  <tr>
    <td> <b>Password</b> </td>
    <td> <input type="password" name="password" size='32' /> </td>
  </tr>
  <tr>
    <td> </td>
    <td> <input type="submit" name="login" value="Login" /> </td>
  </tr>
</table>
</div>
</form>
'''
            request.write(loginform)
"

Hope that helps!

-Dexter

-----Original Message-----
From: moin-user-bounces at lists.sourceforge.net
[mailto:moin-user-bounces at lists.sourceforge.net] On Behalf Of Pavel Laskov
Sent: Monday, July 02, 2007 8:21 AM
To: moin-user at lists.sourceforge.net
Subject: [Moin-user] Changing a default action on a page

Hi,

Is there a way to change a default action on a page? For example, I 
would like to require a login action on a front page. Unfortunately setting

page_front_page = 'MyPage?action=login'

in a configudation file does not bring the desired result. Is there a 
clean way to achieve this?

With best regards,

-- 

+------------------------------------------------------+
   Pavel Laskov, Ph.D.                                _/
                                                _   _/__
   Fraunhofer Institut FIRST IDA               /~\ / /
   Kekulestr. 7, 12489 Berlin                 ~\_/<_/
                                              |\  /
   email: laskov at first.fhg.de                 \ \/|
   tel: +49 30 6392 1870                      |\_\/
   fax: +49 30 6392 1805                      \/ /
   http://ida.first.fhg.de/~laskov/            \/
+------------------------------------------------------+

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Moin-user mailing list
Moin-user at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/moin-user




More information about the Moin-user mailing list