Remove console.logs
This commit is contained in:
parent
c16fed9b50
commit
ce9d215098
226
application/views/admin/blog_post_preview.php
Normal file
226
application/views/admin/blog_post_preview.php
Normal file
|
@ -0,0 +1,226 @@
|
|||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
?>
|
||||
|
||||
<div class="col-sm-8 col-sm-pull-4">
|
||||
<div class="like-toggle-icon-container floating">
|
||||
<button class="like-toggle-icon" title="❤ Toggle Like!"></button>
|
||||
<span class="like-count">0</span>
|
||||
</div>
|
||||
|
||||
<div class="blog">
|
||||
<div class="blog-item">
|
||||
<img class="img-fluid img-blog" src="" width="100%" alt="" />
|
||||
<div class="blog-content">
|
||||
<div class="entry-meta">
|
||||
<span>
|
||||
<i class="far fa-user"></i>
|
||||
<span id="author-name"></span>
|
||||
</span>
|
||||
<span style="cursor:pointer" data-toggle="tooltip" data-placement="bottom">
|
||||
<i class="far fa-calendar"></i>
|
||||
</span>
|
||||
|
||||
<span style="cursor:pointer" data-toggle="tooltip" data-placement="bottom">
|
||||
<i class="far fa-edit"></i>
|
||||
</span>
|
||||
|
||||
<span>
|
||||
<i class="far fa-folder-open"></i>
|
||||
<span id="categoryName"></span>
|
||||
</span>
|
||||
|
||||
<span style="cursor:pointer" data-toggle="tooltip" data-placement="bottom" title="<?= lang('blog_approximate_reading_time') ?>">
|
||||
<i class="far fa-clock"></i>
|
||||
0 min
|
||||
</span>
|
||||
|
||||
<span>
|
||||
<a rel="gotoid" href="#comments">
|
||||
<i class="far fa-comment"></i>
|
||||
0
|
||||
</a>
|
||||
</span>
|
||||
|
||||
<span>
|
||||
<a href="#" style="cursor:pointer">
|
||||
<i class="far fa-heart"></i>
|
||||
<span class="like-count">0</span>
|
||||
</a>
|
||||
</span>
|
||||
</div>
|
||||
<h1 class="post-title"><?= $title ?></h1>
|
||||
<h2 class="post-subtitle"><?= $desc ?></h2>
|
||||
</div>
|
||||
</div>
|
||||
<div class="blog-item">
|
||||
<div class="blog-content">
|
||||
<div class="blog-post">
|
||||
<?= $content ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="blog-item">
|
||||
<div class="blog-content">
|
||||
<div class="row">
|
||||
<div class="col-sm-6">
|
||||
<h3>
|
||||
<i class="fa fa-tags"></i>
|
||||
Tags
|
||||
</h3>
|
||||
<div class="tags" id="tags">
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-sm-6">
|
||||
<h3>
|
||||
<i class="far fa-user"></i> Über
|
||||
</h3>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="blog-item">
|
||||
<div class="blog-content">
|
||||
<div class="container">
|
||||
<h3>
|
||||
<i class="far fa-hand-point-right"></i> <?= lang('blog_articels'); ?></h3>
|
||||
<div class="recommended-articles row">
|
||||
<!-- --><?php //foreach ($randomPosts as $item) { ?>
|
||||
<!-- <div class="col-sm-4">-->
|
||||
<!-- <div class="card">-->
|
||||
<!-- --><?php //if ($item['postImage'] != ''): ?>
|
||||
<!-- <a href="--><?//= base_url('blog/post/' . $item['postUrl']) ?><!--">-->
|
||||
<!-- <img src="--><?//= $item['postImage'] ?><!--?w=200" alt="--><?//= $item['postTitle'] ?><!--" class="card-img-top">-->
|
||||
<!-- </a>-->
|
||||
<!-- --><?php //endif; ?>
|
||||
<!-- <div class="card-body">-->
|
||||
<!-- <a href="--><?//= base_url('blog/post/' . $item['postUrl']) ?><!--">-->
|
||||
<!-- <h5 class="card-title">--><?//= $item['postTitle'] ?><!--</h5>-->
|
||||
<!-- </a>-->
|
||||
<!-- <small class="card-text">-->
|
||||
<!-- <i class="far fa-user"></i>-->
|
||||
<!-- <a href="--><?//= base_url('user/' . $item['postAuthorUsername']) ?><!--">-->
|
||||
<!-- --><?//= $item['postAuthorDisplayname'] ?>
|
||||
<!-- </a>-->
|
||||
<!-- </small>-->
|
||||
<!-- </div>-->
|
||||
<!-- </div>-->
|
||||
<!-- </div>-->
|
||||
<!-- --><?php //} ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="blog-item">
|
||||
<div class="blog-content">
|
||||
<div class="container">
|
||||
<div id="comments">
|
||||
<h3>
|
||||
<!-- <i class="far fa-comments"></i> --><?//= lang('blog_comments') ?><!-- (-->
|
||||
<!-- <span class="comment-count">--><?//= $commentCount; ?><!--</span>-->
|
||||
)
|
||||
</h3>
|
||||
<ul class="comment-list" id="comment-list">
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- <div class="blog-item">-->
|
||||
<!-- <div class="blog-content">-->
|
||||
<!-- <div id="comment-form">-->
|
||||
<!-- <h3>-->
|
||||
<!-- <i class="far fa-comment"></i>-->
|
||||
<!-- --><?//= lang('blog_comment_new'); ?><!--</h3>-->
|
||||
<!-- <div id="notice-container"></div>-->
|
||||
<!-- --><?php //if (!empty($_SESSION['user'])): ?>
|
||||
<!-- <form class="form-horizontal" id="commentForm">-->
|
||||
<!-- <div class="form-group">-->
|
||||
<!-- <div class="col-sm-12">-->
|
||||
<!-- <textarea rows="4" class="form-control" name="comment"-->
|
||||
<!-- placeholder="--><?//= lang('blog_comment') ?><!--"-->
|
||||
<!-- required id="commentField" wrap="soft"></textarea>-->
|
||||
<!-- <input id="reply-id" name="reply-id" value="new" type="hidden">-->
|
||||
<!-- </div>-->
|
||||
<!-- </div>-->
|
||||
<!-- <button type="submit"-->
|
||||
<!-- class="btn btn-green btn-lg col-sm-12"-->
|
||||
<!-- id="addComment">--><?//= lang('blog_comment_send'); ?><!--</button>-->
|
||||
<!-- </form>-->
|
||||
<!-- --><?php //else: ?>
|
||||
<!-- <h4>--><?//= lang('blog_comment_required_login') ?><!--</h4>-->
|
||||
<!-- <a href="/login" class="btn btn-green btn-lg col-sm-12">--><?//= lang('login') ?><!--</a>-->
|
||||
<!-- --><?php //endif; ?>
|
||||
<!-- </div>-->
|
||||
<!-- <!--/#comment-form-->-->
|
||||
<!-- </div>-->
|
||||
<!-- <!--/#comments-->-->
|
||||
<!-- </div>-->
|
||||
<!-- --><?php //if (!empty($prevPost)):
|
||||
// $prevPost = $prevPost[0]; ?>
|
||||
<!-- <div class="blog-item col-xs-6" style="width:calc(50% - 5px);">-->
|
||||
<!-- <a href="--><?//= base_url('blog/post/' . $prevPost['postUrl']) ?><!--">-->
|
||||
<!-- <div class="pull-left"-->
|
||||
<!-- style="background: url(--><?//= $prevPost['postImage'] ?>/*?w=150) center;background-size:cover;width:100px;height:100px;border-radius: 4px;margin:10px 0;"></div>*/
|
||||
/* <div class="float-right" style="width: calc(100% - 110px)">*/
|
||||
/* <h5>*/
|
||||
/* <i class="fa fa-arrow-left"></i> */<?//= lang('blog_previous_article') ?><!--</h5>-->
|
||||
<!-- <h4 style="font-size:20px">--><?//= $prevPost['postTitle'] ?><!--</h4>-->
|
||||
<!-- </div>-->
|
||||
<!-- </a>-->
|
||||
<!-- </div>-->
|
||||
<!-- --><?php //endif; ?>
|
||||
<!-- --><?php //if (!empty($nextPost)):
|
||||
// $nextPost = $nextPost[0]; ?>
|
||||
<!-- <div class="blog-item col-xs-6 float-right" style="width:calc(50% - 5px);">-->
|
||||
<!-- <a href="--><?//= base_url('blog/post/' . $nextPost['postUrl']) ?><!--">-->
|
||||
<!-- <div class="float-right"-->
|
||||
<!-- style="background: url(--><?//= $nextPost['postImage'] ?>/*?w=150) center;background-size:cover;width:100px;height:100px;border-radius: 4px;margin:10px 0;"></div>*/
|
||||
/* <div class="pull-left" style="width: calc(100% - 110px);text-align:right;">*/
|
||||
/* <h5>*/<?//= lang('blog_next_article') ?>
|
||||
<!-- <i class="fa fa-arrow-right"></i>-->
|
||||
<!-- </h5>-->
|
||||
<!-- <h4 style="font-size:20px">--><?//= $nextPost['postTitle'] ?><!--</h4>-->
|
||||
<!-- </div>-->
|
||||
<!-- </a>-->
|
||||
<!-- </div>-->
|
||||
<!-- --><?php //endif; ?>
|
||||
<!-- <!--/.blog-item-->-->
|
||||
<!-- --><?php //endif; ?>
|
||||
</div>
|
||||
</div>
|
||||
<!--/.col-md-8-->
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<!-- Login-Modal -->
|
||||
<div class="modal fade" id="loginModal" tabindex="-1" role="dialog" aria-labelledby="meinModalLabel">
|
||||
<div class="modal-dialog modal-dialog-centered" role="document">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<h4 class="modal-title" id="meinModalLabel">Du musst dafür angemeldet sein!</h4>
|
||||
<button type="button" class="close" data-dismiss="modal" aria-label="Schließen">
|
||||
<span aria-hidden="true">×</span>
|
||||
</button>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<p>Um diese Aktion auszufühen, musst du dich mit deinem Account angemeldet haben.<br>
|
||||
Solltest du noch kein Besitzer eines <?= lang('website_name') ?>-Accounts sein, kannst du
|
||||
kostenfrei
|
||||
einen solchen
|
||||
erstellen.</p>
|
||||
<p>
|
||||
<a href="/faq#accounts" target="_blank">Was bringt mir ein Account?</a>
|
||||
</p>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<a href="/login" class="btn btn-primary">Anmelden</a>
|
||||
<a href="/login/register" class="btn btn-green">Registrieren</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
|
@ -8,7 +8,6 @@ $(document).ready(function () {
|
|||
$("#comment-list").html("<h2><i class='fa fa-cog fa-spin'></i> Loading Comments</h2>");
|
||||
},
|
||||
success: function (data) {
|
||||
console.log(data);
|
||||
$("#comment-list").html(data);
|
||||
},
|
||||
error: function () {
|
||||
|
@ -17,7 +16,6 @@ $(document).ready(function () {
|
|||
});
|
||||
|
||||
$('.blog .info-box').each((el) => {
|
||||
console.log(el);
|
||||
});
|
||||
});
|
||||
|
||||
|
@ -69,8 +67,6 @@ var addComment = function () {
|
|||
$('#addComment').attr('disabled', '');
|
||||
},
|
||||
success: function (data) {
|
||||
console.log(data);
|
||||
|
||||
if (data.type === 'success') {
|
||||
$('#commentField').val('');
|
||||
$('#notice-container').html('<div class="alert alert-success" role="alert">Dein Kommentar wurde <b>erfolgreich</b> gesendet!</div>');
|
||||
|
@ -92,8 +88,7 @@ var addComment = function () {
|
|||
}
|
||||
},
|
||||
error: function (data) {
|
||||
console.log(data);
|
||||
$('#notice-container').html('<div class="alert alert-danger" role="alert"><b>Error:</b> Comment couldn\'t be sent caused by an unkown error! Please try again later or contact the admin to get help!</div>')
|
||||
$('#notice-container').html('<div class="alert alert-danger" role="alert"><b>Error:</b> Comment couldn\'t be sent caused by an unkown error! Please try again later or contact the admin to get help!</div>');
|
||||
$('div.loading-container', item).css('background-color', '#ff4136');
|
||||
$('div.loading-container i', item).removeClass('fa-cog').removeClass('fa-spin').addClass('fa-exclamation').css("color", '#fff');
|
||||
$(item).delay(3000).fadeOut(2000);
|
||||
|
@ -132,4 +127,4 @@ function likeDislike(postID) {
|
|||
}
|
||||
}
|
||||
});
|
||||
};
|
||||
}
|
||||
|
|
|
@ -5,7 +5,6 @@ function loadPlayer() {
|
|||
url: '/tools/csgo/data/' + $('#player-id').text(),
|
||||
method: 'GET',
|
||||
success: function (result) {
|
||||
console.log(result);
|
||||
var playerName = $('#player-name');
|
||||
if (result.player_exists) {
|
||||
$('#player-id').text(result.id);
|
||||
|
|
|
@ -250,13 +250,10 @@ $('#new-category-submit').click(function () {
|
|||
display_name: display_name
|
||||
},
|
||||
success: function (data) {
|
||||
console.log(data);
|
||||
var duplicates = $('select[name="category"] option[value="' + data + '"]').eq(0);
|
||||
if (jQuery.isEmptyObject(duplicates)) {
|
||||
console.log('test');
|
||||
$('select[name="category"]').append('<option value="' + data + '" selected="">' + display_name + '</option>');
|
||||
} else {
|
||||
console.log('kein guter Test');
|
||||
duplicates.attr('selected', '');
|
||||
}
|
||||
}
|
||||
|
@ -456,7 +453,6 @@ $('#deleteModal').on('show.bs.modal', function (event) {
|
|||
|
||||
function deletePostFinally(id, url, selector) {
|
||||
var row = $("#" + selector + "-" + id);
|
||||
console.log(row);
|
||||
$.ajax({
|
||||
url: url,
|
||||
method: 'POST',
|
||||
|
@ -597,8 +593,6 @@ function loadNotificationsAsync() {
|
|||
url: '/Main/getNotifications',
|
||||
method: 'post',
|
||||
success: (data) => {
|
||||
console.log(data);
|
||||
|
||||
if (data.status === 'success') {
|
||||
for (let notification of data.notifications) {
|
||||
$('#notificationMenu').append(`
|
||||
|
|
|
@ -4,8 +4,6 @@ $('#statusModal').on('show.bs.modal', (e) => {
|
|||
const id = btn.data('id');
|
||||
const state = btn.data('state');
|
||||
|
||||
console.log(id, state);
|
||||
|
||||
const modal = $('#statusModal');
|
||||
$('#feedbackState option').each(() => {
|
||||
$(this).removeAttr('disabled').removeAttr('selected');
|
||||
|
@ -34,9 +32,6 @@ function archiveFeedback(id) {
|
|||
id
|
||||
},
|
||||
success: (result) => {
|
||||
// result = JSON.parse(result);
|
||||
console.log(result);
|
||||
|
||||
if (result.type === 'success') {
|
||||
setTimeout(() => {
|
||||
row.find('#loader').css({
|
||||
|
|
|
@ -183,8 +183,6 @@ $(document).ready(function () {
|
|||
passwordCon = $('.passConfirm').val(),
|
||||
url = window.location.href;
|
||||
|
||||
console.log(url);
|
||||
|
||||
$.ajax({
|
||||
url: url,
|
||||
method: 'POST',
|
||||
|
@ -193,7 +191,6 @@ $(document).ready(function () {
|
|||
passwordConfirm: passwordCon
|
||||
},
|
||||
success: function (data) {
|
||||
console.log(data);
|
||||
setTimeout(function () {
|
||||
$('.loading-msg i').removeClass('active');
|
||||
}, 1000);
|
||||
|
@ -215,7 +212,6 @@ $(document).ready(function () {
|
|||
},
|
||||
error: function (data) {
|
||||
// TODO
|
||||
console.log(data);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
@ -282,7 +278,6 @@ $(document).ready(function () {
|
|||
},
|
||||
error: function (data) {
|
||||
// TODO
|
||||
console.log(data);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
@ -300,7 +295,6 @@ function registerAccount(username, email, password, passwordRepeat) {
|
|||
passwordRepeat: passwordRepeat
|
||||
},
|
||||
success: function (data) {
|
||||
console.log(data);
|
||||
setTimeout(function () {
|
||||
$('.loading-msg i').removeClass('active');
|
||||
}, 1000);
|
||||
|
@ -352,7 +346,6 @@ function registerAccount(username, email, password, passwordRepeat) {
|
|||
}, 1650);
|
||||
},
|
||||
error: function (data) {
|
||||
console.log(data);
|
||||
const registerResult = {
|
||||
state: false,
|
||||
messages: [],
|
||||
|
|
|
@ -8,7 +8,6 @@ $('#input input').keyup(function(event){
|
|||
}
|
||||
});
|
||||
$(function() {
|
||||
console.log('test');
|
||||
generateNickname();
|
||||
});
|
||||
|
||||
|
@ -41,7 +40,6 @@ function generateNickname() {
|
|||
$('#generate').button('loading');
|
||||
},
|
||||
success: function(data) {
|
||||
console.log(data);
|
||||
if(data !== "MySQL Error") {
|
||||
$('#nickname').val(data);
|
||||
$('#history').append(`<li class="list-group-item">${data}</li>`);
|
||||
|
|
|
@ -35,7 +35,6 @@ function loadEntries() {
|
|||
firstRun = false;
|
||||
running = false;
|
||||
},
|
||||
error: console.log
|
||||
});
|
||||
}
|
||||
}
|
||||
|
|
|
@ -14,9 +14,7 @@ function searchEntries() {
|
|||
const rank = $('#searchForRank').val();
|
||||
const lang = $('#searchForLang').data('value');
|
||||
const country = $('#searchForCountry').data('value');
|
||||
console.log(rank);
|
||||
if (!s_running && ((s_itemsLeft || val_changed) && (query.val().length > 0 || (type === 'type-users' && (rank !== '' || lang !== '' || country !== ''))))) {
|
||||
console.log(rank);
|
||||
$.ajax({
|
||||
url: '/posts/getSearchPosts',
|
||||
data: {
|
||||
|
@ -59,7 +57,6 @@ function searchEntries() {
|
|||
val_changed = false;
|
||||
|
||||
},
|
||||
error: console.log
|
||||
});
|
||||
}
|
||||
}
|
||||
|
@ -163,7 +160,6 @@ function initUserSearch() {
|
|||
url: '/posts/getAvailableCountries',
|
||||
success: (data) => {
|
||||
const countrySelect = $('#searchForCountry').find('.dropdown-menu');
|
||||
console.log(data);
|
||||
for(let country of data.countries) {
|
||||
countrySelect.append(`
|
||||
<a href="#" class="dropdown-item" data-value="${country.country}">
|
||||
|
@ -180,7 +176,6 @@ function initUserSearch() {
|
|||
$('#searchForCountry').find('.dropdown-item[data-value=' + urlAttribute + ']').click();
|
||||
}
|
||||
},
|
||||
error: console.log
|
||||
});
|
||||
|
||||
$.ajax({
|
||||
|
@ -203,7 +198,6 @@ function initUserSearch() {
|
|||
$('#searchForLang').find('.dropdown-item[data-value=' + urlAttribute + ']').click();
|
||||
}
|
||||
},
|
||||
error: console.log
|
||||
});
|
||||
}
|
||||
|
||||
|
|
|
@ -35,7 +35,6 @@ $('#birthdate-year').change(function () {
|
|||
|
||||
function updateMonthSelection() {
|
||||
const defaultMonth = parseInt($('#birthdate-month').attr('data-default')) || 0;
|
||||
console.log(defaultMonth);
|
||||
$('#birthdate-month option').eq(defaultMonth).attr('selected', 'selected');
|
||||
}
|
||||
|
||||
|
@ -47,7 +46,6 @@ function updateDaySelection() {
|
|||
}
|
||||
|
||||
const defaultDay = parseInt($('#birthdate-day').attr('data-default')) || 0;
|
||||
console.log(defaultDay);
|
||||
$('#birthdate-day option').eq(defaultDay).attr('selected', 'selected');
|
||||
}
|
||||
|
||||
|
|
|
@ -6,7 +6,6 @@ $(document).ready(function () {
|
|||
initSubHeaderOffsetTop = $('#profile-sub-header').offset().top;
|
||||
|
||||
$('section[data-type="background"]').each(function () {
|
||||
// console.log(parallaxActive);
|
||||
var $bgobj = $(this);
|
||||
$bgobj.css('height', parseFloat($('#profile-sub-header').css('top')) - $(window).scrollTop() - 60);
|
||||
$(window).scroll(function () {
|
||||
|
@ -23,12 +22,12 @@ $(document).ready(function () {
|
|||
});
|
||||
});
|
||||
$('section[data-type="foreground"]').each(function () {
|
||||
var $bgobj = $(this);
|
||||
const $bgobj = $(this);
|
||||
|
||||
$(window).scroll(function () {
|
||||
if (parallaxActive) {
|
||||
var yPos = -($(window).scrollTop() / $bgobj.data('speed'));
|
||||
var coords = '50% ' + yPos + 'px';
|
||||
const yPos = -($(window).scrollTop() / $bgobj.data('speed'));
|
||||
const coords = '50% ' + yPos + 'px';
|
||||
$bgobj.css({backgroundPosition: coords});
|
||||
$bgobj.css('transform', 'translate3d(0,' + yPos + 'px, 0)')
|
||||
}
|
||||
|
@ -79,7 +78,6 @@ function sendFollowerRequest() {
|
|||
url: "/user/switchFollowing",
|
||||
method: "POST",
|
||||
success: function (data) {
|
||||
console.log(data);
|
||||
switch (data.code) {
|
||||
case 0:
|
||||
$('#mustBeLoggedInModal').modal('show');
|
||||
|
@ -97,7 +95,6 @@ function sendFollowerRequest() {
|
|||
break;
|
||||
}
|
||||
},
|
||||
error: console.log
|
||||
});
|
||||
}
|
||||
|
||||
|
|
|
@ -34,11 +34,9 @@ $(window).load(function () {
|
|||
|
||||
let sortBy = $(this).attr('data-sort');
|
||||
let sortAsc = $(this).attr('data-asc') === 'true';
|
||||
console.log(sortAsc);
|
||||
if (prevSort.attr('data-sort') === sortBy) {
|
||||
sortAsc = !sortAsc;
|
||||
$(this).attr('data-asc', sortAsc);
|
||||
console.log(sortAsc);
|
||||
}
|
||||
|
||||
if (sortAsc) {
|
||||
|
@ -85,6 +83,5 @@ function autoHeight() {
|
|||
|
||||
$(document).ready(function() {
|
||||
$('.vote-btn').each((el) => {
|
||||
console.log(el);
|
||||
});
|
||||
});
|
|
@ -21,7 +21,6 @@ function loadPostData() {
|
|||
addReplyButtonListener();
|
||||
addPostMediaListener();
|
||||
},
|
||||
error: console.log
|
||||
});
|
||||
}
|
||||
|
||||
|
|
Reference in New Issue
Block a user