Cài đặt FTP Server với ProFTPD Đầu tiên bạn cần cài đặt EPEL repository để có thể cài đặt ProFTPD dùng lệnh yum. Tiếp theo cài đặt ProFTPD yum install proftpd Cấu hình ProFTPD Cấu hình mặc định của ProFTPD đã dùng được rồi, nếu muốn chỉnh sửa thêm bạn hãy edit file /etc/proftpd.conf Tiếp theo, thêm..
Read moreRclone là một công cụ đồng bộ hóa dữ liệu tương tự Rsync nhưng lại được tập trung phát triển chức năng kết nối với các dịch vụ lưu trữ đám mây. Ưu điểm của việc sử dụng dịch vụ lưu trữ đám mây đó là tốc độ cao (do có server được đặt trên khắp thế..
Read moreChúng ta đã không hoàn toàn xa lạ gì với việc boot USB UEFI – Legacy hiện nay. Tuy nhiên, chế độ boot UEFI mặc định chỉ hỗ trợ định dạng FAT32, mà Windows chỉ nhận hầu hết USB hiện nay trên phân vùng đầu tiên cho dù có thể phân vùng USB thành nhiều..
Read moreDatabase Connections In Magento By default, Magento will automatically connect to it’s database and provide two separate resources which you can use to access data: core_read and core_write. As you can probably guess, core_read is for reading from the database while core_write is for writing to the database. It is important to ensure that you..
Read moreSQL <?php /** * @author Linhdh * @website http://181988.xyz * @project update price and specialPrice */ error_reporting(E_ALL | E_STRICT); define(‘MAGENTO_ROOT’, getcwd()); $mageFilename = MAGENTO_ROOT . ‘/app/Mage.php’; require_once $mageFilename; Mage::app(); $ids = Mage::getModel(‘catalog/product’)->getCollection()->getAllIds(); Mage::getSingleton(‘catalog/product_action’)->updateAttributes( $ids, array(‘status’=>1, ‘visibility’=>4), 0 );
Read moreSQL <?php /** * @author Linhdh * @website http://181988.xyz * @project update price and specialPrice */ include(‘app/Mage.php’); //Mage::App(‘default’); Mage::app()->setCurrentStore(Mage_Core_Model_App::ADMIN_STORE_ID); error_reporting(E_ALL | E_STRICT); Mage::setIsDeveloperMode(true); ini_set(‘display_errors’, 1); ob_implicit_flush (1); $mediaApi = Mage::getModel(“catalog/product_attribute_media_api”); $_products = Mage::getModel(‘catalog/product’)->getCollection(); $i =0; $total = count($_products); $count = 0; foreach($_products as $_prod) { $_product = Mage::getModel(‘catalog/product’)->load($_prod->getId()); $_md5_values = array(); //protected base image $base_image..
Read moreSQL <?php /** * @author Linhdh * @website http://181988.xyz * @project update price and specialPrice */ $mageFilename = ‘app/Mage.php’; require_once $mageFilename; Mage::setIsDeveloperMode(true); ini_set(‘display_errors’, 1); umask(0); Mage::app(‘admin’); Mage::register(‘isSecureArea’, 1); Mage::app()->setCurrentStore(Mage_Core_Model_App::ADMIN_STORE_ID); set_time_limit(0); ini_set(‘memory_limit’,’1024M’); /***************** UTILITY FUNCTIONS ********************/ function _getConnection($type = ‘core_read’){ return Mage::getSingleton(‘core/resource’)->getConnection($type); } function _getTableName($tableName){ return Mage::getSingleton(‘core/resource’)->getTableName($tableName); } function _getAttributeId($attribute_code = ‘price’){ $connection = _getConnection(‘core_read’); $sql..
Read moreI recently had to transfer the inventory of an old Shop Factory site into Magento 1.7. Magento offers a powerful facility to do this via CSV using its DataFlow profiles but this is not without its quirks and pitfalls so I thought I’d share my experiences. Importing product data First, you will need to know..
Read moreNhiều bạn có liên hệ hỏi mình về sự ảnh hưởng từ khóa trên kết quả tìm kiếm Google, tất nhiên là bị ảnh hưởng chứ, rất nhiều là đằng khác. Thời gian đầu mình chứng kiến nhiều từ khóa mất top, thậm chí không còn xuất hiện trên Google nữa. Nhưng sau khoảng thời..
Read moreThông thường, bạn có thể sử dụng các dịch vụ miễn phí như UptimeRobot, PingThat, tuy nhiên bạn sẽ bị giới hạn số lượng website, thời gian check, giới hạn SMS thông báo và thường xuyên nhận được thông báo nâng cấp. Với công cụ mình biết này thì khác, bạn có thể theo dõi không giới..
Read moreĐây là thư viện để các bạn không phải sửa từng chút một trong code nữa thêm include hoặc require trong config.php là được <?php namespace { if (!function_exists(‘\mysql_connect’)) { define (‘MYSQL_ASSOC’, 1); define (‘MYSQL_NUM’, 2); define (‘MYSQL_BOTH’, 3); define (‘MYSQL_CLIENT_COMPRESS’, 32); define (‘MYSQL_CLIENT_SSL’, 2048); define (‘MYSQL_CLIENT_INTERACTIVE’, 1024); define (‘MYSQL_CLIENT_IGNORE_SPACE’, 256); function mysql_connect( $hostname =..
Read moreĐể tạo email tên miền riêng với Yandex đã có nhiều bài viết trên mạng giới thiệu, tuy nhiên tất cả hướng dẫn đều thiếu bước verify rất quan trọng cho tên miền, tránh bị vào spam. Do được rất nhiều người hỏi, nên mình quyết định sẽ viết một bài riêng theo trải nghiệm thực tế..
Read moreĐây là tin vui đối với hacker và các chuyên gia nghiên cứu bảo mật: Bạn đã có thể sử dụng hệ điều hành Kali Linux ngay trong một trình duyệt web. Kali Linux là một trong những bản phân phối được cộng đồng bảo mật yêu thích nhất và giờ đã được tích hợp..
Read moreTRIM là một lệnh quan trọng trong Windows, giúp kéo dài tuổi thọ của ổ SSD cũng như duy trì hiệu suất làm việc của thiết bị lưu trữ thể rắn này. Từ phiên bản Windows 7, lệnh TRIM cho ổ SSD được kích hoạt tự động nên bạn không cần phải lo lắng trong..
Read more
[VPS] Netdata – Công cụ theo dõi hệ thống Real-time
Bạn có thể sử dụng tool này trên server để theo dõi gần như toàn bộ tình trạng hệ thống: Total and Per Core CPU usage, interrupts, softirqs and frequency. Total Memory, RAM, Swap and Kernel usage. Disk I/O (per disk: bandwidth, operations, backlog, utilization, etc). Monitors Network interfaces including: bandwidth, packets, errors, drops, etc)…
Read more