Merge branch 'master' of https://github.com/mitsukarenai/Projet-Autoblog
This commit is contained in:
commit
e10b5ddba4
3 changed files with 40 additions and 38 deletions
6
.gitignore
vendored
6
.gitignore
vendored
|
@ -1,5 +1,7 @@
|
|||
0.3/.versionlock
|
||||
0.3/.xsaflock
|
||||
0.3/rss.xml
|
||||
0.3/resources/rss.xml
|
||||
.project
|
||||
0.3/user.css
|
||||
0.3/resources/user.css
|
||||
0.3/autoblogs/*
|
||||
!0.3/autoblogs/autoblog.php
|
||||
|
|
|
@ -566,7 +566,7 @@ if( !empty($_POST['generic']) && ALLOW_NEW_AUTOBLOGS && ALLOW_NEW_AUTOBLOGS_BY_L
|
|||
$error = array_merge( $error, createAutoblog('generic', $sitename, $siteurl, $rssurl, $error));
|
||||
|
||||
if( empty($error))
|
||||
$success[] = '<iframe width="1" height="1" frameborder="0" src="'. urlToFolderSlash( $siteurl ) .'/index.php"></iframe><b style="color:darkgreen">Autoblog '. $sitename .' crée avec succès.</b> → <a target="_blank" href="'. urlToFolderSlash( $siteurl ) .'">afficher l\'autoblog</a>';
|
||||
$success[] = '<iframe width="1" height="1" frameborder="0" src="'. urlToFolderSlash( $siteurl ) .'/index.php"></iframe><b style="color:darkgreen">Autoblog '. $sitename .' crée avec succès.</b> → <a target="_blank" href="'. AUTOBLOGS_FOLDER . urlToFolderSlash( $siteurl ) .'">afficher l\'autoblog</a>';
|
||||
}
|
||||
else {
|
||||
// checking procedure
|
||||
|
@ -844,48 +844,47 @@ if( !empty($_POST['opml_file']) && ALLOW_NEW_AUTOBLOGS && ALLOW_NEW_AUTOBLOGS_BY
|
|||
</p>
|
||||
|
||||
<div class="clear"><a href="?sitemap">sitemap</a> | <a href="?export">export<sup> JSON</sup></a> | <a href="?exportopml">export<sup> OPML</sup></a></div>
|
||||
|
||||
<?php
|
||||
$subdirs = glob(AUTOBLOGS_FOLDER . "*");
|
||||
$autoblogs = array();
|
||||
foreach($subdirs as $unit)
|
||||
{
|
||||
if(is_dir($unit))
|
||||
<div id="contentVignette">
|
||||
<?php
|
||||
$subdirs = glob(AUTOBLOGS_FOLDER . "*");
|
||||
$autoblogs = array();
|
||||
foreach($subdirs as $unit)
|
||||
{
|
||||
if( !file_exists(ROOT_DIR . '/' . $unit . '/.disabled')) {
|
||||
$ini = parse_ini_file(ROOT_DIR . '/' . $unit . '/vvb.ini');
|
||||
if($ini)
|
||||
{
|
||||
$config = new stdClass;
|
||||
$unit=substr($unit, 2);
|
||||
foreach ($ini as $key=>$value)
|
||||
if(is_dir($unit))
|
||||
{
|
||||
if( !file_exists(ROOT_DIR . '/' . $unit . '/.disabled')) {
|
||||
$ini = parse_ini_file(ROOT_DIR . '/' . $unit . '/vvb.ini');
|
||||
if($ini)
|
||||
{
|
||||
$key = strtolower($key);
|
||||
$config->$key = $value;
|
||||
$config = new stdClass;
|
||||
$unit=substr($unit, 2);
|
||||
foreach ($ini as $key=>$value)
|
||||
{
|
||||
$key = strtolower($key);
|
||||
$config->$key = $value;
|
||||
}
|
||||
$autoblogs[$unit] = $config;
|
||||
unset($ini);
|
||||
}
|
||||
$autoblogs[$unit] = $config;
|
||||
unset($ini);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
uasort($autoblogs, "objectCmp");
|
||||
$autoblogs_display = '';
|
||||
uasort($autoblogs, "objectCmp");
|
||||
$autoblogs_display = '';
|
||||
|
||||
if(!empty($autoblogs)){
|
||||
foreach ($autoblogs as $key => $autoblog) {
|
||||
$opml_link='<a href="'.$key.'/?opml">opml</a>';
|
||||
$autoblogs_display .= '<div class="vignette">
|
||||
<div class="title"><a title="'.escape($autoblog->site_title).'" href="'.$key.'/"><img width="15" height="15" alt="" src="./?check='.$key.'"> '.escape($autoblog->site_title).'</a></div>
|
||||
<div class="source">config <sup><a href="'.$key.'/vvb.ini">ini</a> '.$opml_link.'</sup> | '.escape($autoblog->site_type).' source: <a href="'.escape($autoblog->site_url).'">'.escape($autoblog->site_url).'</a></div>
|
||||
</div>';
|
||||
if(!empty($autoblogs)){
|
||||
foreach ($autoblogs as $key => $autoblog) {
|
||||
$opml_link='<a href="'.$key.'/?opml">opml</a>';
|
||||
$autoblogs_display .= '<div class="vignette">
|
||||
<div class="title"><a title="'.escape($autoblog->site_title).'" href="'.$key.'/"><img width="15" height="15" alt="" src="./?check='.$key.'"> '.escape($autoblog->site_title).'</a></div>
|
||||
<div class="source">config <sup><a href="'.$key.'/vvb.ini">ini</a> '.$opml_link.'</sup> | '.escape($autoblog->site_type).' source: <a href="'.escape($autoblog->site_url).'">'.escape($autoblog->site_url).'</a></div>
|
||||
</div>';
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
echo $autoblogs_display;
|
||||
?>
|
||||
|
||||
echo $autoblogs_display;
|
||||
?>
|
||||
</div>
|
||||
<div class="clear"></div>
|
||||
|
||||
<?php echo "<p>".count($autoblogs)." autoblogs hébergés</p>"; ?>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
* ------------
|
||||
* Please do NOT edit this file. Updating your Autoblogs farm will be easier.
|
||||
* If you want to add your own CSS, use the file user.css
|
||||
*
|
||||
*
|
||||
*/
|
||||
|
||||
body {background-color:#efefef;text-align:center;color:#333;font-family:sans-serif;}
|
||||
|
@ -18,7 +18,8 @@ input[type="submit"] {width:8em;}
|
|||
input[type="text"]#socialaccount, input[type="text"]#statusneturl, input[type="text"]#shaarliurl,input[type="text"].smallinput {width:20em;}
|
||||
div.form {padding:0.2em;border:1px solid #fff;}
|
||||
div.form:hover {background-color:#FAF4DA;border:1px dotted;}
|
||||
.vignette {width:20em;height:2em;float:left;margin:0; padding:20px;background-color:#eee;border: 1px solid #888;}
|
||||
#contentVignette {text-align: center;}
|
||||
.vignette {width:20em;height:2em;display: inline-block;text-align:justify;margin:0; padding:20px;background-color:#eee;border: 1px solid #888;}
|
||||
.vignette:hover {background-color:#fff;}
|
||||
.vignette .title {font-size: 14pt;text-shadow: #ccc 0px 5px 5px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;}
|
||||
.vignette .title a:hover {color:darkred; text-decoration:none;}
|
||||
|
|
Loading…
Reference in a new issue