angrygoose907
New member
### Hướng dẫn: Cách tự động sao chép VPS bằng mã iMacros
** Bước 1: Cài đặt imacros **
Imacros là một tiện ích mở rộng trình duyệt miễn phí cho phép bạn tự động hóa các tác vụ lặp đi lặp lại.Bạn có thể cài đặt nó từ [trang web Imacros] (Progress Customer Community).
** Bước 2: Tạo tập lệnh mới **
Khi bạn đã cài đặt iMacros, hãy mở trình chỉnh sửa iMacros và tạo tập lệnh mới.Bạn có thể làm điều này bằng cách nhấp vào nút ** "tập lệnh mới" **.
** Bước 3: Thêm mã sau vào tập lệnh của bạn: **
`` `
/ * Auto clone vps */
var vps_host = "host-vps-host";
var vps_user = "tên của bạn-vps-username";
var vps_pass = "của bạn-VPS-password";
hàm clonevps () {
// Mở bảng điều khiển VPS trong một tab mới.
window.open ("https: //" + vps_host + "/clientarea.php");
// Chờ trang đăng nhập để tải.
WaitUntilEuityPresent ("Input [name = username]");
// Nhập tên người dùng và mật khẩu của bạn.
Document.QuerySelector ("Input [name = username]"). value = vps_user;
document.QuerySelector ("Input [name = password]"). value = vps_pass;
// Nhấp vào nút Đăng nhập.
document.QuerySelector ("nút [type = gửi]"). Nhấp ();
// Đợi trang danh sách VPS tải.
WaitUntilEuityPresent ("Bảng [id = vpslist]");
// Nhận số lượng VPS trong danh sách.
var numvpss = document.QuerySelectorall ("Bảng [id = vpslist] tr"). LEGN;
// Tạo một VPS mới.
document.QuerySelector ("A [href = '#addvps']"). Nhấp ();
// Chờ trang tạo VPS tải.
WaitUntILEuityPresent ("Input [name = hostName]");
// Nhập tên máy chủ cho VPS mới.
document.QuerySelector ("Input [name = hostName]"). value = "My-New-Vps";
// Nhấp vào nút Tạo.
document.QuerySelector ("nút [type = gửi]"). Nhấp ();
// Đợi cho việc tạo VPS hoàn thành.
WaitUntilEuityPresent ("Bảng [id = vpslist] tr: nth-con (" + (numvpss + 1) + ")");
}
`` `
** Bước 4: Chạy tập lệnh **
Để chạy tập lệnh, nhấp vào nút ** "chạy" **.Tập lệnh sẽ tự động sao chép VPS của bạn.
### hashtags:
* #VPs
* #Automation
* #imacros
* #đám mây
* #tutorial
=======================================
### Instructions: How to Auto Clone VPS with iMacros Code
**Step 1: Install iMacros**
iMacros is a free browser extension that allows you to automate repetitive tasks. You can install it from the [iMacros website](https://www.imacros.net/).
**Step 2: Create a new script**
Once you have installed iMacros, open the iMacros editor and create a new script. You can do this by clicking on the **"New Script"** button.
**Step 3: Add the following code to your script:**
```
/* Auto Clone VPS */
var VPS_HOST = "your-vps-host";
var VPS_USER = "your-vps-username";
var VPS_PASS = "your-vps-password";
function cloneVPS() {
// Open the VPS control panel in a new tab.
window.open("https://" + VPS_HOST + "/clientarea.php");
// Wait for the login page to load.
waitUntilElementPresent("input[name=username]");
// Enter your username and password.
document.querySelector("input[name=username]").value = VPS_USER;
document.querySelector("input[name=password]").value = VPS_PASS;
// Click the login button.
document.querySelector("button[type=submit]").click();
// Wait for the VPS list page to load.
waitUntilElementPresent("table[id=vpslist]");
// Get the number of VPSs in the list.
var numVPSs = document.querySelectorAll("table[id=vpslist] tr").length;
// Create a new VPS.
document.querySelector("a[href='#addvps']").click();
// Wait for the VPS creation page to load.
waitUntilElementPresent("input[name=hostname]");
// Enter a hostname for the new VPS.
document.querySelector("input[name=hostname]").value = "my-new-vps";
// Click the create button.
document.querySelector("button[type=submit]").click();
// Wait for the VPS creation to complete.
waitUntilElementPresent("table[id=vpslist] tr:nth-child(" + (numVPSs + 1) + ")");
}
```
**Step 4: Run the script**
To run the script, click on the **"Run"** button. The script will automatically clone your VPS.
### Hashtags:
* #VPs
* #Automation
* #imacros
* #cloud
* #tutorial
** Bước 1: Cài đặt imacros **
Imacros là một tiện ích mở rộng trình duyệt miễn phí cho phép bạn tự động hóa các tác vụ lặp đi lặp lại.Bạn có thể cài đặt nó từ [trang web Imacros] (Progress Customer Community).
** Bước 2: Tạo tập lệnh mới **
Khi bạn đã cài đặt iMacros, hãy mở trình chỉnh sửa iMacros và tạo tập lệnh mới.Bạn có thể làm điều này bằng cách nhấp vào nút ** "tập lệnh mới" **.
** Bước 3: Thêm mã sau vào tập lệnh của bạn: **
`` `
/ * Auto clone vps */
var vps_host = "host-vps-host";
var vps_user = "tên của bạn-vps-username";
var vps_pass = "của bạn-VPS-password";
hàm clonevps () {
// Mở bảng điều khiển VPS trong một tab mới.
window.open ("https: //" + vps_host + "/clientarea.php");
// Chờ trang đăng nhập để tải.
WaitUntilEuityPresent ("Input [name = username]");
// Nhập tên người dùng và mật khẩu của bạn.
Document.QuerySelector ("Input [name = username]"). value = vps_user;
document.QuerySelector ("Input [name = password]"). value = vps_pass;
// Nhấp vào nút Đăng nhập.
document.QuerySelector ("nút [type = gửi]"). Nhấp ();
// Đợi trang danh sách VPS tải.
WaitUntilEuityPresent ("Bảng [id = vpslist]");
// Nhận số lượng VPS trong danh sách.
var numvpss = document.QuerySelectorall ("Bảng [id = vpslist] tr"). LEGN;
// Tạo một VPS mới.
document.QuerySelector ("A [href = '#addvps']"). Nhấp ();
// Chờ trang tạo VPS tải.
WaitUntILEuityPresent ("Input [name = hostName]");
// Nhập tên máy chủ cho VPS mới.
document.QuerySelector ("Input [name = hostName]"). value = "My-New-Vps";
// Nhấp vào nút Tạo.
document.QuerySelector ("nút [type = gửi]"). Nhấp ();
// Đợi cho việc tạo VPS hoàn thành.
WaitUntilEuityPresent ("Bảng [id = vpslist] tr: nth-con (" + (numvpss + 1) + ")");
}
`` `
** Bước 4: Chạy tập lệnh **
Để chạy tập lệnh, nhấp vào nút ** "chạy" **.Tập lệnh sẽ tự động sao chép VPS của bạn.
### hashtags:
* #VPs
* #Automation
* #imacros
* #đám mây
* #tutorial
=======================================
### Instructions: How to Auto Clone VPS with iMacros Code
**Step 1: Install iMacros**
iMacros is a free browser extension that allows you to automate repetitive tasks. You can install it from the [iMacros website](https://www.imacros.net/).
**Step 2: Create a new script**
Once you have installed iMacros, open the iMacros editor and create a new script. You can do this by clicking on the **"New Script"** button.
**Step 3: Add the following code to your script:**
```
/* Auto Clone VPS */
var VPS_HOST = "your-vps-host";
var VPS_USER = "your-vps-username";
var VPS_PASS = "your-vps-password";
function cloneVPS() {
// Open the VPS control panel in a new tab.
window.open("https://" + VPS_HOST + "/clientarea.php");
// Wait for the login page to load.
waitUntilElementPresent("input[name=username]");
// Enter your username and password.
document.querySelector("input[name=username]").value = VPS_USER;
document.querySelector("input[name=password]").value = VPS_PASS;
// Click the login button.
document.querySelector("button[type=submit]").click();
// Wait for the VPS list page to load.
waitUntilElementPresent("table[id=vpslist]");
// Get the number of VPSs in the list.
var numVPSs = document.querySelectorAll("table[id=vpslist] tr").length;
// Create a new VPS.
document.querySelector("a[href='#addvps']").click();
// Wait for the VPS creation page to load.
waitUntilElementPresent("input[name=hostname]");
// Enter a hostname for the new VPS.
document.querySelector("input[name=hostname]").value = "my-new-vps";
// Click the create button.
document.querySelector("button[type=submit]").click();
// Wait for the VPS creation to complete.
waitUntilElementPresent("table[id=vpslist] tr:nth-child(" + (numVPSs + 1) + ")");
}
```
**Step 4: Run the script**
To run the script, click on the **"Run"** button. The script will automatically clone your VPS.
### Hashtags:
* #VPs
* #Automation
* #imacros
* #cloud
* #tutorial