Fix WordPress CORS Policy

I’ve had this error come up. “… has been blocked by CORS policy: No ‘Access-Control-Allow-Origin’ header is present on the requested resource.” To fix it, add this code to your .htaccess file: <FilesMatch “\.(php|ttf|ttc|otf|eot|woff|woff2|font.css)$”> <IfModule mod_headers.c> Header set Access-Control-Allow-Origin “*” </IfModule> </FilesMatch>

Posted in Web

mysql Putty Commands

Log onto mysql: mysql -p mysql -u root -p Create a database: mysql> create database [database name]; Show all databases: mysql> show databases; Select database: mysql> use [database name] Show your database tables: mysql> show tables; Find database directory: mysql> select @@datadir; Create user: mysql> grant all privileges on [database name].* to ‘[username]’@’localhost’ identified by […]