Why can't I log in through metaTrader 5 - Follow Up Deployment
Browse files- index.html +33 -1
- prompts.txt +2 -1
index.html
CHANGED
|
@@ -189,6 +189,7 @@
|
|
| 189 |
<option value="binance">Binance</option>
|
| 190 |
<option value="coinbase">Coinbase</option>
|
| 191 |
<option value="kraken">Kraken</option>
|
|
|
|
| 192 |
</select>
|
| 193 |
</div>
|
| 194 |
<div>
|
|
@@ -199,6 +200,20 @@
|
|
| 199 |
<label class="block text-sm mb-1">API Secret</label>
|
| 200 |
<input type="password" id="api-secret" class="w-full bg-gray-700 border border-gray-600 rounded-lg px-3 py-2" placeholder="Enter API Secret">
|
| 201 |
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 202 |
<div class="flex space-x-3">
|
| 203 |
<button id="exchange-connect-submit" class="btn btn-primary flex-1 py-2">Connect</button>
|
| 204 |
<button id="exchange-connect-cancel" class="btn btn-danger flex-1 py-2">Cancel</button>
|
|
@@ -915,6 +930,16 @@
|
|
| 915 |
}, 2000);
|
| 916 |
});
|
| 917 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 918 |
// Exchange Connection Handling
|
| 919 |
document.getElementById('connect-exchange-btn').addEventListener('click', function() {
|
| 920 |
document.getElementById('exchange-connect-modal').classList.remove('hidden');
|
|
@@ -939,8 +964,15 @@
|
|
| 939 |
this.disabled = true;
|
| 940 |
|
| 941 |
try {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 942 |
// In a real app, this would call your backend API to verify credentials
|
| 943 |
-
// Here we simulate a successful connection
|
| 944 |
await new Promise(resolve => setTimeout(resolve, 1500));
|
| 945 |
|
| 946 |
// Update UI to show connected state
|
|
|
|
| 189 |
<option value="binance">Binance</option>
|
| 190 |
<option value="coinbase">Coinbase</option>
|
| 191 |
<option value="kraken">Kraken</option>
|
| 192 |
+
<option value="metatrader5">MetaTrader 5</option>
|
| 193 |
</select>
|
| 194 |
</div>
|
| 195 |
<div>
|
|
|
|
| 200 |
<label class="block text-sm mb-1">API Secret</label>
|
| 201 |
<input type="password" id="api-secret" class="w-full bg-gray-700 border border-gray-600 rounded-lg px-3 py-2" placeholder="Enter API Secret">
|
| 202 |
</div>
|
| 203 |
+
<div id="mt5-fields" class="hidden space-y-4">
|
| 204 |
+
<div>
|
| 205 |
+
<label class="block text-sm mb-1">MT5 Server</label>
|
| 206 |
+
<input type="text" id="mt5-server" class="w-full bg-gray-700 border border-gray-600 rounded-lg px-3 py-2" placeholder="Enter MT5 Server">
|
| 207 |
+
</div>
|
| 208 |
+
<div>
|
| 209 |
+
<label class="block text-sm mb-1">MT5 Login</label>
|
| 210 |
+
<input type="text" id="mt5-login" class="w-full bg-gray-700 border border-gray-600 rounded-lg px-3 py-2" placeholder="Enter MT5 Login">
|
| 211 |
+
</div>
|
| 212 |
+
<div>
|
| 213 |
+
<label class="block text-sm mb-1">MT5 Password</label>
|
| 214 |
+
<input type="password" id="mt5-password" class="w-full bg-gray-700 border border-gray-600 rounded-lg px-3 py-2" placeholder="Enter MT5 Password">
|
| 215 |
+
</div>
|
| 216 |
+
</div>
|
| 217 |
<div class="flex space-x-3">
|
| 218 |
<button id="exchange-connect-submit" class="btn btn-primary flex-1 py-2">Connect</button>
|
| 219 |
<button id="exchange-connect-cancel" class="btn btn-danger flex-1 py-2">Cancel</button>
|
|
|
|
| 930 |
}, 2000);
|
| 931 |
});
|
| 932 |
|
| 933 |
+
// Show/hide MT5 specific fields
|
| 934 |
+
document.getElementById('exchange-select').addEventListener('change', function() {
|
| 935 |
+
const mt5Fields = document.getElementById('mt5-fields');
|
| 936 |
+
if (this.value === 'metatrader5') {
|
| 937 |
+
mt5Fields.classList.remove('hidden');
|
| 938 |
+
} else {
|
| 939 |
+
mt5Fields.classList.add('hidden');
|
| 940 |
+
}
|
| 941 |
+
});
|
| 942 |
+
|
| 943 |
// Exchange Connection Handling
|
| 944 |
document.getElementById('connect-exchange-btn').addEventListener('click', function() {
|
| 945 |
document.getElementById('exchange-connect-modal').classList.remove('hidden');
|
|
|
|
| 964 |
this.disabled = true;
|
| 965 |
|
| 966 |
try {
|
| 967 |
+
// Handle MT5 differently since it requires server/password
|
| 968 |
+
if (exchange === 'metatrader5') {
|
| 969 |
+
// MT5 requires server, username and password fields
|
| 970 |
+
alert('For MetaTrader 5, please also specify server and login credentials in your broker app');
|
| 971 |
+
return;
|
| 972 |
+
}
|
| 973 |
+
|
| 974 |
+
// For other exchanges, verify credentials
|
| 975 |
// In a real app, this would call your backend API to verify credentials
|
|
|
|
| 976 |
await new Promise(resolve => setTimeout(resolve, 1500));
|
| 977 |
|
| 978 |
// Update UI to show connected state
|
prompts.txt
CHANGED
|
@@ -1 +1,2 @@
|
|
| 1 |
-
why is it that i cant log in through the exchange link
|
|
|
|
|
|
| 1 |
+
why is it that i cant log in through the exchange link
|
| 2 |
+
Why can't I log in through metaTrader 5
|