Repository navigation
Expand file tree
/
Copy patherror.html
More file actions
executable file
·132 lines (120 loc) · 3.62 KB
/
Copy patherror.html
File metadata and controls
executable file
·132 lines (120 loc) · 3.62 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<style>
:root {
--color-primary: #474762;
--color-secondary: #A7FF52;
--color-accent: #6051ED;
}
body {
font-family: 'Montserrat', sans-serif;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
height: 100vh;
margin: 0;
background-color: #f7f7f7;
color: #333;
padding: 20px;
box-sizing: border-box;
}
.error-container {
text-align: center;
max-width: 600px;
background: white;
padding: 40px;
border-radius: 8px;
box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}
h1 {
color: var(--color-primary);
margin-bottom: 20px;
font-size: 24px;
}
.error-message {
margin: 20px 0;
line-height: 1.6;
color: #666;
}
.error-code {
font-family: monospace;
background-color: #f0f0f0;
padding: 8px 16px;
border-radius: 4px;
font-size: 14px;
color: var(--color-primary);
margin: 10px 0;
display: inline-block;
}
.suggestions {
margin-top: 20px;
text-align: left;
font-size: 14px;
color: #666;
}
.suggestions ul {
margin: 10px 0;
padding-left: 20px;
}
.suggestions li {
margin: 8px 0;
}
.retry-button {
margin-top: 20px;
padding: 12px 24px;
background-color: var(--color-secondary);
border: none;
border-radius: 4px;
color: #000;
font-weight: bold;
cursor: pointer;
transition: all 0.2s ease;
font-size: 14px;
}
.retry-button:hover {
background-color: var(--color-accent);
color: white;
transform: translateY(-1px);
}
</style>
<link href="https://fonts.googleapis.com/css2?family=Montserrat:wght@400;700&display=swap" rel="stylesheet">
</head>
<body>
<div class="error-container">
<h1>Nu s-a putut încărca pagina</h1>
<div class="error-message">
A apărut o eroare la încărcarea paginii:<br>
<strong id="error-url"></strong>
</div>
<div class="error-code" id="error-code"></div>
<div class="suggestions">
<strong>Sugestii:</strong>
<ul id="suggestions-list">
<li>Verificați conexiunea la internet</li>
<li>Asigurați-vă că adresa URL este corectă</li>
</ul>
</div>
<button class="retry-button" onclick="window.location.reload()">Încearcă din nou</button>
</div>
<script>
// Primim parametrii din URL
const urlParams = new URLSearchParams(window.location.search);
const errorUrl = urlParams.get('url');
const errorCode = urlParams.get('code');
const errorDesc = urlParams.get('desc');
// Actualizăm elementele cu informațiile de eroare
document.getElementById('error-url').textContent = errorUrl || 'Unknown URL';
document.getElementById('error-code').textContent = `${errorDesc || 'Unknown Error'} (${errorCode || 'Unknown'})`;
// Adăugăm sugestii specifice în funcție de codul de eroare
const suggestionsList = document.getElementById('suggestions-list');
if (errorCode === '-101') {
suggestionsList.innerHTML += '<li>Este posibil ca serverul să fie temporar indisponibil sau să blocheze accesul</li>';
} else if (errorCode === '-201') {
suggestionsList.innerHTML += '<li>Certificatul de securitate al site-ului nu poate fi validat</li>';
}
</script>
</body>
</html>