233 lines
13 KiB
PHP
233 lines
13 KiB
PHP
<? global $config, $gdb, $mdb;?>
|
|
<div class="row">
|
|
<div class="col col-xs-12">
|
|
<div class="panel panel-info panel-border top">
|
|
<div class="progress progress-bar-xl">
|
|
<div class="progress-bar progress-bar-success" role="progressbar" aria-valuenow="<?= round( $this -> links_visited / $this -> links_internal_all * 100 );?>" aria-valuemin="0" aria-valuemax="100" style="width: <?= round( $this -> links_visited / $this -> links_internal_all * 100 );?>%; min-width: 250px;">
|
|
<span>Sprawdzone: <b><?= round( $this -> links_visited / $this -> links_internal_all * 100 );?>%</b> (<?= $this -> links_visited . '/' . $this -> links_internal_all;?>)</span>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div class="panel panel-info panel-border top">
|
|
<div class="panel-heading">
|
|
<span class="panel-title">Szczegóły projektu: <u><?= $this -> project['name'];?></u></span>
|
|
</div>
|
|
<div class="panel-heading pb5" style="height: auto;">
|
|
<?= \Html::button(
|
|
array(
|
|
'text' => 'Wstecz',
|
|
'url' => '/projects/view_list/',
|
|
'icon' => 'fa-mail-reply',
|
|
'class' => 'btn-dark btn-sm'
|
|
)
|
|
);?>
|
|
</div>
|
|
<div class="panel-body">
|
|
<div class="row">
|
|
<div class="col-xs-12">
|
|
<form method="POST" action="/projects/details/&id=<?= $this -> project_id;?>" id="form-furl" class="form-horizontal">
|
|
<div class="form-group">
|
|
<label class="col-lg-2 control-label">Szukaj url:</label>
|
|
<div class="col-lg-8">
|
|
<div class="input-group">
|
|
<input type="text" id="furl" class=" form-control" name="url" value="<?= $this -> filtr_url;?>">
|
|
<span class="input-group-addon pointer" onclick="document.location.href = '/projects/details/&id=<?= $this -> project_id;?>&furl=clear';"><i class="fa fa-close"></i></span>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</form>
|
|
</div>
|
|
<div class="col-xs-12 mb10">
|
|
<a href="/projects/details/&id=<?= $this -> project_id;?>&mte=<?= $this -> filtr_mte ? $tmp = '0' : $tmp = '1';?>" class="btn btn-sm btn-default <? if ( $this -> filtr_mte ) echo 'btn-danger';?>">bez meta title</a>
|
|
<a href="/projects/details/&id=<?= $this -> project_id;?>&mke=<?= $this -> filtr_mke ? $tmp = '0' : $tmp = '1';?>" class="btn btn-sm btn-default <? if ( $this -> filtr_mke ) echo 'btn-danger';?>">bez meta keywords</a>
|
|
<a href="/projects/details/&id=<?= $this -> project_id;?>&mde=<?= $this -> filtr_mde ? $tmp = '0' : $tmp = '1';?>" class="btn btn-sm btn-default <? if ( $this -> filtr_mde ) echo 'btn-danger';?>">bez meta description</a>
|
|
<a href="/projects/details/&id=<?= $this -> project_id;?>&irb=<?= $this -> filtr_irb ? $tmp = '0' : $tmp = '1';?>" class="btn btn-sm btn-default <? if ( $this -> filtr_irb ) echo 'btn-danger';?>">zablokowane dla robotów</a>
|
|
<a href="/projects/details/&id=<?= $this -> project_id;?>&grb=<?= $this -> filtr_grb ? $tmp = '0' : $tmp = '1';?>" class="btn btn-sm btn-default <? if ( $this -> filtr_grb ) echo 'btn-danger';?>">zablokowane dla Google</a>
|
|
<a href="/projects/details/&id=<?= $this -> project_id;?>&wor=<?= $this -> filtr_wor ? $tmp = '0' : $tmp = '1';?>" class="btn btn-sm btn-default <? if ( $this -> filtr_wor ) echo 'btn-danger';?>">bez przekierowania</a>
|
|
<a href="/projects/details/&id=<?= $this -> project_id;?>&wir=<?= $this -> filtr_wir ? $tmp = '0' : $tmp = '1';?>" class="btn btn-sm btn-default <? if ( $this -> filtr_wir ) echo 'btn-danger';?>">z przekierowaniem lub niedostępne</a>
|
|
<a href="/projects/details/&id=<?= $this -> project_id;?>&hid=<?= $this -> filtr_hid ? $tmp = '0' : $tmp = '1';?>" class="btn btn-sm btn-default <? if ( $this -> filtr_hid ) echo 'btn-danger';?>">pokaż ukryte</a>
|
|
<a href="/projects/details/&id=<?= $this -> project_id;?>&edf=<?= $this -> filtr_edf ? $tmp = '0' : $tmp = '1';?>" class="btn btn-sm btn-default <? if ( $this -> filtr_edf ) echo 'btn-danger';?>">z linkami wychodzącymi dofollow</a>
|
|
<a href="/projects/details/&id=<?= $this -> project_id;?>&filtr_edfrops=<?= $this -> filtr_edfrops ? 0 : 1;?>" class="btn btn-sm btn-default <? if ( $this -> filtr_edfrops ) echo 'btn-danger';?>">z linkami wychodzącymi (ROPS)</a>
|
|
<a href="/projects/details/&id=<?= $this -> project_id;?>&f404=<?= $this -> filtr_404 ? $tmp = '0' : $tmp = '1';?>" class="btn btn-sm btn-default <? if ( $this -> filtr_404 ) echo 'btn-danger';?>">404</a>
|
|
<a href="/projects/details/&id=<?= $this -> project_id;?>&filtr_tables=<?= $this -> filtr_tables ? $tmp = '0' : $tmp = '1';?>" class="btn btn-sm btn-default <? if ( $this -> filtr_tables ) echo 'btn-danger';?>">z tabelami</a>
|
|
<a href="/projects/details/&id=<?= $this -> project_id;?>&filtr_iframe=<?= $this -> filtr_iframe ? $tmp = '0' : $tmp = '1';?>" class="btn btn-sm btn-default <? if ( $this -> filtr_iframe ) echo 'btn-danger';?>">z iframe</a>
|
|
<a href="/projects/details/&id=<?= $this -> project_id;?>&filtr_h1=<?= $this -> filtr_h1 ? $tmp = '0' : $tmp = '1';?>" class="btn btn-sm btn-default <? if ( $this -> filtr_h1 ) echo 'btn-danger';?>">bez h1</a>
|
|
<a href="/projects/details/&id=<?= $this -> project_id;?>&filtr_images_alt=<?= $this -> filtr_images_alt ? $tmp = '0' : $tmp = '1';?>" class="btn btn-sm btn-default <? if ( $this -> filtr_images_alt ) echo 'btn-danger';?>">zdjęcia bez alt</a>
|
|
</div>
|
|
<div class="col-xs-12 mb10">
|
|
<a href="#" class="btn btn-sm btn-default" onclick="$( 'input.checkbox-url' ).each( function(){ if( $( this ).is( ':checked' ) ) { $( this ).prop( 'checked', false ); } else { $( this ).prop('checked', true ); } } );">zaznacz/odznacz wszystkie</a>
|
|
<a href="#" class="btn btn-sm btn-default" id="delete-checked">ukryj zaznaczone</a>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div class="panel panel-success panel-border top">
|
|
<div class="panel-body">
|
|
<? if ( is_array( $this -> links_internal ) ): foreach ( $this -> links_internal as $link ):?>
|
|
<div class="row">
|
|
<div class="col-xs-12 mt10">
|
|
<div id="link-<?= $link['id'];?>">
|
|
<a href="#" class="btn btn-xs btn-danger" onclick="$( this ).blur(); $.prompt( 'Na pewno chcesz ukryć wybrany link?', { title: 'Potwierdź?', submit: function(e,v,m,f) { if ( v == true ) document.location.href = '/projects/hide_url/&project_id=<?= $this -> project_id;?>&id=<?= $link['id'];?>'; }, buttons: { 'tak': true, 'nie': false }, focus: 0 } );" title="Ukryj link: <?= $link['url'];?>"><i class="fa fa-trash"></i></a>
|
|
<a href="#" class="btn btn-xs btn-success details-toggle" link-id="<?= $link['id'];?>">
|
|
<i class="fa fa-bars"></i>
|
|
</a>
|
|
<input type="checkbox" class="checkbox-url mr5 ml5" name="urls[]" value="<?= $link['id'];?>" style="position: relative; top: 3px;" />
|
|
<a href="<?= $link['url'];?>" target="_blank">
|
|
<?= $link['url'];?>
|
|
</a>
|
|
</div>
|
|
<div id="details-<?= $link['id'];?>" class="link-details">
|
|
<div class="row">
|
|
<div class="col-xs-12">
|
|
<form class="form-horizontal">
|
|
<?= \Html::form_text(
|
|
array(
|
|
'text' => $link['title'] . '<span class="ml5">(' . strlen( $link['title'] ) . ' znaków)</span>',
|
|
'label' => 'Meta title'
|
|
)
|
|
);?>
|
|
<?= \Html::form_text(
|
|
array(
|
|
'text' => $link['meta_keywords'] . '<span class="ml5">(' . strlen( $link['meta_keywords'] ) . ' znaków)</span>',
|
|
'label' => 'Meta keywords'
|
|
)
|
|
);?>
|
|
<?= \Html::form_text(
|
|
array(
|
|
'text' => $link['meta_description'] . '<span class="ml5">(' . strlen( $link['meta_description'] ) . ' znaków)</span>',
|
|
'label' => 'Meta description'
|
|
)
|
|
);?>
|
|
<?= \Html::form_text(
|
|
array(
|
|
'text' => $link['meta_robots'] ? $link['meta_robots'] : $tmp = '--- brak ---',
|
|
'label' => 'Meta robots'
|
|
)
|
|
);?>
|
|
<?= \Html::form_text(
|
|
array(
|
|
'text' => $link['meta_googlebot'] ? $link['meta_googlebot'] : $tmp = '--- brak ---',
|
|
'label' => 'Meta googlebot'
|
|
)
|
|
);?>
|
|
<?= \Html::form_text(
|
|
array(
|
|
'text' => round( $link['text_lenght'] / $link['code_lenght'] * 100 ) . '% (' . $link['text_lenght'] . '/' . $link['code_lenght'] . ')',
|
|
'label' => 'Stosunek treści do kodu'
|
|
)
|
|
);?>
|
|
<?= \Html::form_text(
|
|
array(
|
|
'text' => '<b>' . $link['response_code'] . '</b> - ' . \S::get_server_response_details( $link['response_code'] ),
|
|
'label' => 'Odpowiedź serwera'
|
|
)
|
|
);?>
|
|
|
|
<?
|
|
$out_links = '';
|
|
|
|
if ( is_array( $link['external_links'] ) and !empty( $link['external_links'] ) )
|
|
{
|
|
$out_links .= '<ul style="margin-left: 20px;">';
|
|
foreach ( $link['external_links'] as $ext_link )
|
|
{
|
|
$out_links .= '<li><a href="' . $ext_link['url'] . '" target="_blank">' . $ext_link['url'] . '</a> - ';
|
|
if ( !$ext_link['nofollow'] )
|
|
$out_links .= '<span class="text-danger">dofollow</span>';
|
|
else
|
|
$out_links .= '<span>nofollow</span>';
|
|
if ( $ext_link['title'] )
|
|
$out_links .= ' | <span>' . $ext_link['title'] . '</span>';
|
|
$out_links .= '</li>';
|
|
}
|
|
$out_links .= '</ul>';
|
|
}
|
|
else
|
|
$out_links .= '--- brak ---';
|
|
?>
|
|
|
|
<?= \Html::form_text(
|
|
array(
|
|
'text' => $mdb -> get( 'project_links_internal', 'url', [ 'id' => $link['parent_id'] ] ),
|
|
'label' => 'Rodzic'
|
|
)
|
|
);?>
|
|
|
|
<?= \Html::form_text(
|
|
array(
|
|
'text' => $link['canonical'] ? $link['canonical'] : '-',
|
|
'label' => 'Canonical'
|
|
)
|
|
);?>
|
|
|
|
|
|
<?= \Html::form_text(
|
|
array(
|
|
'text' => $out_links,
|
|
'label' => 'Linki zewnętrzne'
|
|
)
|
|
);?>
|
|
</form>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<? endforeach; endif;?>
|
|
</div>
|
|
</div>
|
|
<?= $this -> pager;?>
|
|
<script type="text/javascript">
|
|
$( function()
|
|
{
|
|
$( 'body' ).on( 'click', '.details-toggle', function(e)
|
|
{
|
|
var link_id = $( this ).attr( 'link-id' );
|
|
$( '#details-' + link_id ).toggle();
|
|
});
|
|
|
|
$( 'body' ).on( 'click', '.link-container', function(e)
|
|
{
|
|
if ( !$( e.target ).is( 'i' ) && !$( e.traget ).is( 'input' ) )
|
|
{
|
|
var id = $( this ).attr( 'id' );
|
|
|
|
$( '.link-details' ).not( '#link-details-' + id ).hide();
|
|
$( '#link-details-' + id ).toggle();
|
|
return false;
|
|
}
|
|
});
|
|
|
|
$( 'body' ).on( 'change', '#furl', function()
|
|
{
|
|
$( '#form-furl' ).submit();
|
|
});
|
|
|
|
$( 'body' ).on( 'click', '#delete-checked', function()
|
|
{
|
|
$.prompt( 'Na pewno chcesz ukryć wybrane linki?',
|
|
{
|
|
title: 'Potwierdź?',
|
|
submit: function(e,v,m,f)
|
|
{
|
|
if ( v == true )
|
|
{
|
|
var checkedValues = $('input:checkbox:checked').map(function() {
|
|
return this.value;
|
|
}).get();
|
|
|
|
document.location.href = "/projects/hide_url/&project_id=<?= $this -> project_id;?>&id=" + checkedValues;
|
|
}
|
|
},
|
|
buttons:
|
|
{
|
|
'tak': true,
|
|
'nie': false
|
|
},
|
|
focus: 0
|
|
} );
|
|
});
|
|
});
|
|
</script>
|