[svn r20121] Fixing SVN#20094 & SVN#20109

skala
Julio Montoya 17 years ago
parent 0dc18e1e49
commit 16f6bcb74e
  1. 109
      main/inc/lib/blog.lib.php

@ -1314,7 +1314,7 @@ class Blog
echo '<div class="row"><div class="form_header">' . get_lang('NewPost') . '</div></div>'; echo '<div class="row"><div class="form_header">' . get_lang('NewPost') . '</div></div>';
// article title // article title
echo '<div class="row" style="float:left;"> echo '<div class="row">
<div class="label" > <div class="label" >
<span class="form_required">*</span>'.get_lang('Title') . ' <span class="form_required">*</span>'.get_lang('Title') . '
</div> </div>
@ -1334,49 +1334,51 @@ class Blog
} }
$oFCKeditor->Value = isset($_POST['post_full_text'])?stripslashes($_POST['post_full_text']):''; $oFCKeditor->Value = isset($_POST['post_full_text'])?stripslashes($_POST['post_full_text']):'';
echo '<div class="row" style="float:left;width:100%"> echo '<div class="row">
<div class="label" style="width:7%" > <div class="label">
' . get_lang('PostFullText') . ' ' . get_lang('PostFullText') . '
</div> </div>
<div style="padding-left:110px;width:90%">'; <div class="formw">';
$oFCKeditor->Create(); $oFCKeditor->Create();
echo '</div> echo ' </div>
</div>'; </div>';
echo '<br /><br />';
// attachment // attachment
echo '<div style="float:left;width:100%"> echo '<div class="row">
<div style="float:left;padding-right:10px"> <div class="label">
' . get_lang('AddAnAttachment') . ' ' . get_lang('AddAnAttachment') . '
</div> </div>
<div style="float:left;"> <div class="formw">
<input type="file" name="user_upload"/> <input type="file" name="user_upload"/>
</div> </div>
</div>'; </div>';
echo '<br /><br />';
// comment // comment
echo '<div style="float:left;width:100%"> echo '<div class="row">
<div style="float:left;padding-right:28px"> <div class="label">
' . get_lang('FileComment') . ' ' . get_lang('FileComment') . '
</div> </div>
<div style="float:left;"> <div class="formw">
<textarea name="post_file_comment" cols="34" /></textarea> <textarea name="post_file_comment" cols="34" /></textarea>
</div> </div>
</div>'; </div>';
echo '<br /><br />';
// submit // submit
echo '<div class="row" style="float:left;padding-left:90px;" > echo '<div class="row">
<div class="label"> <div class="label">
</div> </div>
<div class="formw"> <div class="formw">
<input type="hidden" name="action" value="" /> <input type="hidden" name="action" value="" />
<input type="hidden" name="new_post_submit" value="true" /> <input type="hidden" name="new_post_submit" value="true" />
<button class="save" type="submit" name="Submit">' . get_lang('Save') . '</button> <button class="save" type="submit" name="Submit">' . get_lang('Save') . '</button>
</div> </div>
</div>'; </div>';
echo '</form>'; echo '</form>';
} else { }
else
{
api_not_allowed(); api_not_allowed();
} }
} }
@ -2872,41 +2874,42 @@ class Blog
} }
$list_content_blog=array(); $list_content_blog=array();
$list_body_blog=array(); $list_body_blog=array();
foreach($list_info as $key => $info_log) {
$list_body_blog[]=$info_log[0];
$list_body_blog[]=$info_log[1];
$visibility_icon=($info_log[2]==0) ? 'invisible' : 'visible';
$visibility_info=($info_log[2]==0) ? 'Visible' : 'Invisible';
$my_image.='<a href="' .api_get_self(). '?action=edit&amp;blog_id=' . $info_log[3] . '">';
$my_image.='<img src="../img/edit.gif" border="0" title="' . get_lang('EditBlog') . '" />';
$my_image.="</a>\n";
$my_image.='<a href="' .api_get_self(). '?action=delete&amp;blog_id=' . $info_log[3] . '" ';
$my_image.='onclick="javascript:if(!confirm(\''.addslashes(htmlentities(get_lang("ConfirmYourChoice"),ENT_QUOTES,$charset)). '\')) return false;" >';
$my_image.='<img src="../img/delete.gif" border="0" title="' . get_lang('DeleteBlog') . '" />';
$my_image.="</a>\n";
$my_image.='<a href="' .api_get_self(). '?action=visibility&amp;blog_id=' . $info_log[3] . '">';
$my_image.='<img src="../img/' . $visibility_icon . '.gif" border="0" title="' . get_lang($visibility_info) . '" />';
$my_image.="</a>\n";
$list_body_blog[]=$my_image;
$my_image='';
$list_content_blog[]=$list_body_blog; if (is_array($list_info)) {
$list_body_blog=array(); foreach($list_info as $key => $info_log) {
$list_body_blog[]=$info_log[0];
$list_body_blog[]=$info_log[1];
$visibility_icon=($info_log[2]==0) ? 'invisible' : 'visible';
$visibility_info=($info_log[2]==0) ? 'Visible' : 'Invisible';
$my_image.='<a href="' .api_get_self(). '?action=edit&amp;blog_id=' . $info_log[3] . '">';
$my_image.='<img src="../img/edit.gif" border="0" title="' . get_lang('EditBlog') . '" />';
$my_image.="</a>\n";
$my_image.='<a href="' .api_get_self(). '?action=delete&amp;blog_id=' . $info_log[3] . '" ';
$my_image.='onclick="javascript:if(!confirm(\''.addslashes(htmlentities(get_lang("ConfirmYourChoice"),ENT_QUOTES,$charset)). '\')) return false;" >';
$my_image.='<img src="../img/delete.gif" border="0" title="' . get_lang('DeleteBlog') . '" />';
$my_image.="</a>\n";
$my_image.='<a href="' .api_get_self(). '?action=visibility&amp;blog_id=' . $info_log[3] . '">';
$my_image.='<img src="../img/' . $visibility_icon . '.gif" border="0" title="' . get_lang($visibility_info) . '" />';
$my_image.="</a>\n";
$list_body_blog[]=$my_image;
$my_image='';
$list_content_blog[]=$list_body_blog;
$list_body_blog=array();
}
$parameters='';
//$parameters=array('action'=>Security::remove_XSS($_GET['action']));
$table = new SortableTableFromArrayConfig($list_content_blog, 1,20,'project');
//$table->set_additional_parameters($parameters);
$table->set_header(0, get_lang('Title'));
$table->set_header(1, get_lang('Subtitle'));
$table->set_header(2, get_lang('Modify'));
$table->display();
} }
$parameters='';
//$parameters=array('action'=>Security::remove_XSS($_GET['action']));
$table = new SortableTableFromArrayConfig($list_content_blog, 1,20,'project');
$table->set_additional_parameters($parameters);
$table->set_header(0, get_lang('Title'));
$table->set_header(1, get_lang('Subtitle'));
$table->set_header(2, get_lang('Modify'));
$table->display();
$list_content_blog=array();
/*$sql = "SELECT `blog_id`, `blog_name`, `blog_subtitle`, `visibility` FROM $tbl_blogs ORDER BY `blog_name`"; /*$sql = "SELECT `blog_id`, `blog_name`, `blog_subtitle`, `visibility` FROM $tbl_blogs ORDER BY `blog_name`";
$result = api_sql_query($sql, __FILE__, __LINE__); $result = api_sql_query($sql, __FILE__, __LINE__);

Loading…
Cancel
Save