mirror of
https://github.com/usmannasir/cyberpanel.git
synced 2025-11-06 21:35:55 +01:00
update code to add design from main wp page
This commit is contained in:
@@ -384,6 +384,14 @@ app.controller('listWebsites', function ($scope, $http, $window) {
|
||||
|
||||
};
|
||||
|
||||
$scope.getFullUrl = function(url) {
|
||||
if (!url) return '';
|
||||
if (url.startsWith('http://') || url.startsWith('https://')) {
|
||||
return url;
|
||||
}
|
||||
return 'https://' + url;
|
||||
};
|
||||
|
||||
$scope.showWPSites = function(domain) {
|
||||
var site = $scope.WebSitesList.find(function(site) {
|
||||
return site.domain === domain;
|
||||
|
||||
@@ -134,13 +134,13 @@
|
||||
<div class="wp-site-content">
|
||||
<div class="row">
|
||||
<div class="col-sm-3">
|
||||
<img ng-src="{$ wp.screenshot $}"
|
||||
<img ng-src="https://api.microlink.io/?url={$ getFullUrl(wp.url) $}&screenshot=true&meta=false&embed=screenshot.url"
|
||||
alt="{$ wp.title $}"
|
||||
class="img-responsive"
|
||||
style="max-width: 100%; margin-bottom: 10px;"
|
||||
onerror="this.onerror=null; this.src='https://s.wordpress.org/style/images/about/WordPress-logotype-standard.png';">
|
||||
<div class="text-center">
|
||||
<a ng-href="http://{$ wp.url $}" target="_blank" class="btn btn-default btn-sm">
|
||||
<a ng-href="{$ getFullUrl(wp.url) $}" target="_blank" class="btn btn-default btn-sm">
|
||||
<i class="fas fa-external-link-alt"></i> Visit Site
|
||||
</a>
|
||||
<a href="{% url 'AutoLogin' %}?id={$ wp.id $}" target="_blank" class="btn btn-primary btn-sm">
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user