Bài đăng

Auto complete in jquery

Hình ảnh
Auto complete in jquery Require A smile and... done. Autocomplete with default Create file aucomplete.html and start edit it: Add input tag with text type <body>       <input type="text" /> </body> Import jquery 1.9.1 and jquery ui 1.9.2 <body>      <input type="text" /> </body> <script src="http://code.jquery.com/jquery-1.9.1.js"></script> <script   src="https://code.jquery.com/ui/1.12.0/jquery-ui.js"   integrity="sha256-0YPKAwZP7Mp3ALMRVB2i8GXeEndvCq3eSl/WsAl1Ryk="   crossorigin="anonymous"></script> Add js function call autocomplete <body> <input type="text" /> </body> <script src="http://code.jquery.com/jquery-1.9.1.js"></script> <script   src="https://code.jquery.com/ui/1.12.0/jquery-ui.js"   integrity="sha256-0YPKAwZP7Mp3ALMRVB2i8GXeEndvCq3eSl/WsAl1Ry...

How to delay startup application in Ubuntu

Hình ảnh
How to delay startup application in Ubuntu Start startup application Type startup application in Ubuntu search. Select application Type application script to start or browse path. Add sleep for startup application Insert sleep code before application name/path. sleep <time>; Just so easy! After you saved the changes, it takes place in next boot.

Mở đầu về hình ảnh trong Open CV và python

Mở đầu về hình ảnh trong Open CV và Python Đây là link bài gốc , bạn nên đọc tiếng Anh vì tác giả giải thích rất cặn kẽ. Trước khi thực hiện bạn phải cài Python và Open CV: (mình dùng Python 2.7 và Open CV 3 Cách cài => google :v # import the necessary packages import cv2 # load the image and show it image = cv2 . imread ( "image.jpg" ) cv2 . imshow ( "original" , image ) cv2 . waitKey ( 0 ) Đầu tiên import thư viện cv2. Sau đó đọc file ảnh "image.jpg" cùng thư mục. Hiển thị hình ảnh nguyên bản. Đợi người dùng nhấn bất kỳ nút gì để thoát. print image . shape Hiển thị 3 thông số của hình ảnh: (320, 430,3). image.shape[0]=320 ứng với 320 dòng => chiều cao của ảnh. image.shape[1]=430 ứng với 320 cột => chiều ngang của ảnh. 3 chính là thuộc tính RBG của ảnh. Tiếp theo ta căn chỉnh kích thước của hình ảnh. Ví dụ dưới là các bước để căn chỉnh hình ảnh theo chiều cao 100px. # we need to keep in mind as...

Laravel, composer and PHP artisan

Laravel, composer and PHP artisan Laravel và composer Creat laravel project: composer create-project --prefer-dist laravel/laravel project_name Ex: Create laravel project name todolist composer create-project --prefer-dist laravel/laravel todolist Build project locahost: php artisan serve Set project key: php artisan key:generate   To turn on maintenance mode, use artisan down php artisan down Check the current version of laravel installation? php artisan –version // Output: // Laravel Framework version 5.2.45 Put Laravel application in “maintenance mode” php artisan down // Output: // Application is now in maintenance mode. Display the environment laravel is running php artisan env // Output: // Current application environment: local Run Database migrations php artisan migrate // This executes all the defined migrations and create database tables. To start Laravel project.   php artisan serve By, default this ...

Chuyển đổi địa chỉ vật lý và địa chỉ ảo trong bộ nhớ chính

Hình ảnh
MEMORY MANAGEMENT  Chuyển đổi địa chỉ: quá trình ánh xạ một địa chỉ từ không gian địa chỉ này sang không gian địa chỉ khác. Bài tập1: Xét một không gian địa chỉ có 8 trang, mỗi trang có kích thước 1KB. ánh xạ vào bộ nhớ vật lý có 32 khung trang  a) Địa chỉ logic gồm bao nhiêu bit ?  b) Địa chỉ physic gồm bao nhiêu bit ? c) Bảng trang có bao nhiêu mục?Mỗi mục trong bảng trang cần bao nhiêu bit? Giải:  Nhận xét: Không gian địa chỉ có 8 trang-> cần 3 bit để biểu diễn(2^3=8)), kích thước d= 2^10 -> cần 10 bit biểu diễn, ánh xạ vào bộ nhớ vật lyscos 32 khung trang-> cần 5 bit biểu diễn(2^5=32) a) Địa chỉ logic: page +ofset= 3+ 10 = 13 b) Địa chỉ vật lý: frame +ofset= 5+10 =15 c) Số mục của bảng trang = số trang =8. Mỗi mục trong bảng trang cần 5 bit. Lưu ý: trong bảng trang chỉ có chứa khung trang, vì trang được đánh mặc định tăng dần 0,1,2,3,.....