prettyurls: some fixes to the htaccess editor

This commit is contained in:
real_nowhereman 2007-11-09 08:09:15 +00:00
parent e3f853092e
commit a1ef058ab0
3 changed files with 6 additions and 5 deletions

View File

@ -1,6 +1,6 @@
<?php <?php
$lang['plugin']['prettyurls']['errors'] = array ( $lang['plugin']['prettyurls']['errors'] = array (
-2 => 'I can\' find or create an <code>.htaccess</code> file in your root '. -2 => 'I can\'t find or create an <code>.htaccess</code> file in your root '.
'directory. PrettyURLs might not work properly, see the config panel.' 'directory. PrettyURLs might not work properly, see the config panel.'
); );
@ -8,8 +8,8 @@
$lang['admin']['plugin']['prettyurls'] = array( $lang['admin']['plugin']['prettyurls'] = array(
'head' => 'PrettyURLs Configuration', 'head' => 'PrettyURLs Configuration',
'description'=>'This raw editor let you edit your '. 'description'=>'This raw editor let you edit your '.
'<code><a class="hint" href="http://wiki.flatpress.org/doc:plugins:prettyurls">.htaccess</a></code>.', '<code><a class="hint" href="http://wiki.flatpress.org/doc:plugins:prettyurls#htaccess">.htaccess</a></code>.',
'cantsave' => 'If file were writable you could edit it', 'cantsave' => 'You can\'t edit this file, because it\'s not <strong>writable</strong>. You can give writing permission or copy and paste to a file and then upload as <a class="hint" href="http://wiki.flatpress.org/doc:plugins:prettyurls#manual_upload">described here</a>',
'submit' => 'Save' 'submit' => 'Save'
); );
$lang['admin']['plugin']['prettyurls']['msgs'] = array( $lang['admin']['plugin']['prettyurls']['msgs'] = array(

View File

@ -495,7 +495,7 @@ STR;
$this->smarty->assign('cantsave', $this->smarty->assign('cantsave',
( (file_exists($f) && !is_writable($f)) && !is_writable(ABS_PATH) ) ( !is_writable(ABS_PATH) || (file_exists($f) && !is_writable($f)) )
); );
$this->smarty->assign('htaccess', $txt); $this->smarty->assign('htaccess', $txt);
} }

View File

@ -7,7 +7,8 @@
{html_form} {html_form}
<p> <p>
<textarea id="htaccess" name="htaccess" cols="70" rows="16">{$htaccess|escape:'html'}</textarea> <textarea id="htaccess" name="htaccess"
{if $cantsave}readonly="readonly" {/if}cols="70" rows="16">{$htaccess|escape:'html'}</textarea>
</p> </p>
<div class="buttonbar"> <div class="buttonbar">