Creating New Page with WP_INSERT_POST Issue

Use post_name instead of post_slug (post_slug isn’t valid in wp_insert_post). Just make sure you don’t accidentally create pages with duplicate slugs.

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