// Yahweh Mission Dashboard Integration — WPCode snippet version
// Paste this into a new PHP Snippet in WPCode, set to run "Auto Insert" /
// "Everywhere", and activate it. Functionally identical to the plugin
// version — just packaged as a snippet since this host strips .php files
// out of uploaded plugin zips.
if (!function_exists('ymi_get_api_url')) {
function ymi_get_api_url() {
return rtrim(get_option('ymi_dashboard_api_url', ''), '/');
}
}
// ---- Settings page: Settings -> Yahweh Mission ----
add_action('admin_menu', function () {
add_options_page('Yahweh Mission Dashboard', 'Yahweh Mission', 'manage_options', 'yahweh-mission', 'ymi_render_settings_page');
});
add_action('admin_init', function () {
register_setting('ymi_settings', 'ymi_dashboard_api_url', array(
'sanitize_callback' => 'esc_url_raw',
'default' => '',
));
});
function ymi_render_settings_page() {
if (!current_user_can('manage_options')) {
return;
}
$api_url = get_option('ymi_dashboard_api_url', '');
?>
Yahweh Mission Dashboard
Connects this site to the Yahweh Mission Dashboard so published children, gifts, and projects appear here automatically via the [ymi_children], [ymi_gift_catalog], and [ymi_child_profile] shortcodes.
Connection check
8));
if (is_wp_error($response)) {
echo '
Could not reach the dashboard: ' . esc_html($response->get_error_message()) . '
The Yahweh Mission is a faith-driven charity serving children, families, and vulnerable communities in Bangladesh. What began as a simple act of kindness has grown into a mission of hope, providing education, food, care, spiritual guidance, and support for those who need it most.
We believe every child deserves safety, dignity, love, and the opportunity to build a better future. Through the support of donors, sponsors, volunteers, and prayer partners, we continue to serve with compassion and purpose.
The Yahweh Mission is a faith-driven charity serving children, families, and vulnerable communities in Bangladesh. What began as a simple act of kindness has grown into a mission of hope, providing education, food, care, spiritual guidance, and support for those who need it most.
We believe every child deserves safety, dignity, love, and the opportunity to build a better future. Through the support of donors, sponsors, volunteers, and prayer partners, we continue to serve with compassion and purpose.
Our Vision
A consistent gift gives a child more than relief — it gives them the steady care, education, and hope they need to build a future beyond the circumstances they were born into.
See How Your Giving Helps →
Our Mission
A consistent gift gives a child more than relief — it gives them the steady care, education, and hope they need to build a future beyond the circumstances they were born into.
Accumsan et parturient orci inceptos mi consectetur nulla fermentum curabitur. Luctus ullamcorper sagittis dictumst vestibulum elementum dapibus mi nunc ipsum. Nisi phasellus in etiam nascetur fusce finibus sem. Libero habitant vestibulum penatibus aliquet morbi tempor vivamus purus posuere senectus.
Eros parturient ut sem lobortis mus pretium dapibus. Venenatis egestas dolor laoreet.
Eros parturient ut sem lobortis mus pretium dapibus. Venenatis egestas dolor laoreet.
Eros parturient ut sem lobortis mus pretium dapibus. Venenatis egestas dolor laoreet.
Eros parturient ut sem lobortis mus pretium dapibus. Venenatis egestas dolor laoreet.
More People, More impact
Sagittis fringilla morbi leo feugiat ultricies lacinia dignissim habitasse pede. Elementum magnis praesent pulvinar dictum fusce hac nullam ipsum semper feugiat consectetur.
Restore Nature
Aptent nisl aenean urna scelerisque sollicitudin praesent. Velit sit sociosqu elementum venenatis tellus.
Unite The Society
Aptent nisl aenean urna scelerisque sollicitudin praesent. Velit sit sociosqu elementum venenatis tellus.
Make Big Impact
Aptent nisl aenean urna scelerisque sollicitudin praesent. Velit sit sociosqu elementum venenatis tellus.