Fossil SCM
chat: fixed links to /env and /self to use the file's current name instead of hard-coded to 'chat'.
Commit
896d7d44b048934d1dee932c8eed6ea4c00c6202079677c5576314e242ea90f0
Parent
cdb8f6902f94aa8…
1 file changed
+4
-2
+4
-2
| --- tools/chat.tcl | ||
| +++ tools/chat.tcl | ||
| @@ -35,10 +35,12 @@ | ||
| 35 | 35 | <p>You must have privileges to use this chatroom</p> |
| 36 | 36 | </div> |
| 37 | 37 | } |
| 38 | 38 | return |
| 39 | 39 | } |
| 40 | + set scriptFile [wapp-param SCRIPT_FILENAME] | |
| 41 | + set cgiFn [file tail $scriptFile] | |
| 40 | 42 | wapp-trim { |
| 41 | 43 | <form accept-encoding="utf-8" id="chat-form"> |
| 42 | 44 | <div id='chat-input-area'> |
| 43 | 45 | <div id='chat-input-line'> |
| 44 | 46 | <input type="text" name="msg" id="sbox" placeholder="Type message here."> |
| @@ -56,12 +58,12 @@ | ||
| 56 | 58 | --></span> |
| 57 | 59 | |
| 58 | 60 | </div><!-- .fossil-doc --> |
| 59 | 61 | <hr> |
| 60 | 62 | <p> |
| 61 | - <a href="chat/env">CGI environment</a> | | |
| 62 | - <a href="chat/self">Wapp script</a> | |
| 63 | + <a href="%string($cgiFn)/env">CGI environment</a> | | |
| 64 | + <a href="%string($cgiFn)/self">Wapp script</a> | |
| 63 | 65 | <style> |
| 64 | 66 | \#dialog { |
| 65 | 67 | width: 97%; |
| 66 | 68 | } |
| 67 | 69 | \#chat-input-area { |
| 68 | 70 |
| --- tools/chat.tcl | |
| +++ tools/chat.tcl | |
| @@ -35,10 +35,12 @@ | |
| 35 | <p>You must have privileges to use this chatroom</p> |
| 36 | </div> |
| 37 | } |
| 38 | return |
| 39 | } |
| 40 | wapp-trim { |
| 41 | <form accept-encoding="utf-8" id="chat-form"> |
| 42 | <div id='chat-input-area'> |
| 43 | <div id='chat-input-line'> |
| 44 | <input type="text" name="msg" id="sbox" placeholder="Type message here."> |
| @@ -56,12 +58,12 @@ | |
| 56 | --></span> |
| 57 | |
| 58 | </div><!-- .fossil-doc --> |
| 59 | <hr> |
| 60 | <p> |
| 61 | <a href="chat/env">CGI environment</a> | |
| 62 | <a href="chat/self">Wapp script</a> |
| 63 | <style> |
| 64 | \#dialog { |
| 65 | width: 97%; |
| 66 | } |
| 67 | \#chat-input-area { |
| 68 |
| --- tools/chat.tcl | |
| +++ tools/chat.tcl | |
| @@ -35,10 +35,12 @@ | |
| 35 | <p>You must have privileges to use this chatroom</p> |
| 36 | </div> |
| 37 | } |
| 38 | return |
| 39 | } |
| 40 | set scriptFile [wapp-param SCRIPT_FILENAME] |
| 41 | set cgiFn [file tail $scriptFile] |
| 42 | wapp-trim { |
| 43 | <form accept-encoding="utf-8" id="chat-form"> |
| 44 | <div id='chat-input-area'> |
| 45 | <div id='chat-input-line'> |
| 46 | <input type="text" name="msg" id="sbox" placeholder="Type message here."> |
| @@ -56,12 +58,12 @@ | |
| 58 | --></span> |
| 59 | |
| 60 | </div><!-- .fossil-doc --> |
| 61 | <hr> |
| 62 | <p> |
| 63 | <a href="%string($cgiFn)/env">CGI environment</a> | |
| 64 | <a href="%string($cgiFn)/self">Wapp script</a> |
| 65 | <style> |
| 66 | \#dialog { |
| 67 | width: 97%; |
| 68 | } |
| 69 | \#chat-input-area { |
| 70 |