i want to auto create pages with shortcode when plugin is activated and delete when deactivated

The problem is a basic PHP problem rather than a WordPress problem. wp_insert_post is expecting ‘post_content’ but you’ve given it ‘$post_content’ and it needs a string as it’s value aka “[gd_shortcode]” not [gd_shortcode]. The same is true of your post status, it has a $ in it that should not be there. See the examples … Read more

How to load plugin static data from cloudfront

There are already plugins to do the rewrites. For example, CDN Linker. By default, it loads / rewrites the static content for ‘wp-includes’ and ‘wp-content’. You may change this default behaviour after the installation / activation or fork it to let this plugin rewrite only the data from the plugins directory.

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)