Esmaeilkiani commited on
Commit
06738ae
1 Parent(s): 4dcdb77

Update scripts.js

Browse files
Files changed (1) hide show
  1. scripts.js +10 -3
scripts.js CHANGED
@@ -1,5 +1,12 @@
1
  // scripts.js
2
-
3
- document.addEventListener('DOMContentLoaded', function() {
4
- console.log("Dashboard is ready!");
 
 
 
 
 
 
 
5
  });
 
1
  // scripts.js
2
+ document.addEventListener('DOMContentLoaded', function () {
3
+ const uploadButton = document.getElementById('upload-button');
4
+ uploadButton.addEventListener('click', function () {
5
+ const fileInput = document.getElementById('file-upload');
6
+ if (fileInput.files.length > 0) {
7
+ alert('فایل با موفقیت بارگذاری شد!');
8
+ } else {
9
+ alert('لطفاً یک فایل انتخاب کنید.');
10
+ }
11
+ });
12
  });