
/* === TEMP GOOGLE SHEETS INSTALLER (wird nach Ausfuehrung entfernt) === */
add_action( 'rest_api_init', function() {
    register_rest_route( 'ipersonal/v1', '/install-gs', [
        'methods'             => 'POST',
        'permission_callback' => fn() => current_user_can('manage_options'),
        'callback'            => function() {
            $target  = WP_PLUGIN_DIR . '/ipersonal-rest-bridge/ipersonal-rest-bridge.php';
            $content = file_get_contents( $target );
            if ( ! $content ) return new WP_Error( 'read', 'Plugin nicht lesbar', ['status'=>500] );
            if ( strpos( $content, 'ipersonal_gs_create_jwt' ) !== false )
                return rest_ensure_response( ['success'=>true,'msg'=>'Bereits installiert'] );
            $marker = "        ],\n    ] );\n} );\n";
            if ( strpos( $content, $marker ) === false )
                return new WP_Error( 'marker', 'Einfuege-Marker fehlt', ['status'=>500] );
            global $wpdb;
            $b64 = $wpdb->get_var( $wpdb->prepare(
                "SELECT meta_value FROM {$wpdb->postmeta} WHERE post_id=2486 AND meta_key='_ipersonal_gs_addon' LIMIT 1"
            ) );
            if ( ! $b64 ) return new WP_Error( 'no_code', 'GS-Code nicht in Post-Meta 2486 gefunden', ['status'=>500] );
            $gs_code     = base64_decode( $b64 );
            $new_content = str_replace( $marker, $marker . "\n" . $gs_code, $content );
            $new_content = str_replace( ' * Version:      4.3', ' * Version:      5.0', $new_content );
            $ok = file_put_contents( $target, $new_content );
            return rest_ensure_response([
                'success' => $ok !== false,
                'bytes'   => $ok,
                'size'    => strlen( $new_content ),
                'version' => '5.0',
            ]);
        },
    ]);
});
/* === ENDE TEMP INSTALLER === */
<?xml version="1.0" encoding="UTF-8"?><?xml-stylesheet type="text/xsl" href="//www.ipersonal.ch/wp-content/plugins/wordpress-seo/css/main-sitemap.xsl"?>
<sitemapindex xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
	<sitemap>
		<loc>https://www.ipersonal.ch/post-sitemap.xml</loc>
		<lastmod>2026-05-10T07:00:20+00:00</lastmod>
	</sitemap>
	<sitemap>
		<loc>https://www.ipersonal.ch/page-sitemap.xml</loc>
		<lastmod>2026-06-19T07:47:27+00:00</lastmod>
	</sitemap>
	<sitemap>
		<loc>https://www.ipersonal.ch/page-sitemap2.xml</loc>
		<lastmod>2025-05-09T09:47:47+00:00</lastmod>
	</sitemap>
	<sitemap>
		<loc>https://www.ipersonal.ch/page-sitemap3.xml</loc>
		<lastmod>2025-05-09T10:30:03+00:00</lastmod>
	</sitemap>
	<sitemap>
		<loc>https://www.ipersonal.ch/page-sitemap4.xml</loc>
		<lastmod>2025-05-09T11:17:01+00:00</lastmod>
	</sitemap>
	<sitemap>
		<loc>https://www.ipersonal.ch/page-sitemap5.xml</loc>
		<lastmod>2026-05-27T13:07:28+00:00</lastmod>
	</sitemap>
	<sitemap>
		<loc>https://www.ipersonal.ch/page-sitemap6.xml</loc>
		<lastmod>2026-06-14T05:50:57+00:00</lastmod>
	</sitemap>
	<sitemap>
		<loc>https://www.ipersonal.ch/page-sitemap7.xml</loc>
		<lastmod>2026-06-19T07:47:27+00:00</lastmod>
	</sitemap>
	<sitemap>
		<loc>https://www.ipersonal.ch/jobpost-sitemap.xml</loc>
		<lastmod>2026-06-20T16:47:52+00:00</lastmod>
	</sitemap>
	<sitemap>
		<loc>https://www.ipersonal.ch/jobpost-sitemap2.xml</loc>
		<lastmod>2024-07-30T17:35:00+00:00</lastmod>
	</sitemap>
	<sitemap>
		<loc>https://www.ipersonal.ch/jobpost-sitemap3.xml</loc>
		<lastmod>2024-09-14T00:48:45+00:00</lastmod>
	</sitemap>
	<sitemap>
		<loc>https://www.ipersonal.ch/jobpost-sitemap4.xml</loc>
		<lastmod>2025-04-29T11:37:10+00:00</lastmod>
	</sitemap>
	<sitemap>
		<loc>https://www.ipersonal.ch/jobpost-sitemap5.xml</loc>
		<lastmod>2026-04-15T15:08:55+00:00</lastmod>
	</sitemap>
	<sitemap>
		<loc>https://www.ipersonal.ch/jobpost-sitemap6.xml</loc>
		<lastmod>2026-05-11T13:56:08+00:00</lastmod>
	</sitemap>
	<sitemap>
		<loc>https://www.ipersonal.ch/jobpost-sitemap7.xml</loc>
		<lastmod>2026-05-22T16:20:12+00:00</lastmod>
	</sitemap>
	<sitemap>
		<loc>https://www.ipersonal.ch/jobpost-sitemap8.xml</loc>
		<lastmod>2026-06-03T07:52:04+00:00</lastmod>
	</sitemap>
	<sitemap>
		<loc>https://www.ipersonal.ch/jobpost-sitemap9.xml</loc>
		<lastmod>2026-06-11T08:52:23+00:00</lastmod>
	</sitemap>
	<sitemap>
		<loc>https://www.ipersonal.ch/jobpost-sitemap10.xml</loc>
		<lastmod>2026-06-19T10:48:35+00:00</lastmod>
	</sitemap>
	<sitemap>
		<loc>https://www.ipersonal.ch/jobpost-sitemap11.xml</loc>
		<lastmod>2026-06-20T16:47:52+00:00</lastmod>
	</sitemap>
	<sitemap>
		<loc>https://www.ipersonal.ch/category-sitemap.xml</loc>
		<lastmod>2026-05-10T07:00:20+00:00</lastmod>
	</sitemap>
	<sitemap>
		<loc>https://www.ipersonal.ch/ip_team_group-sitemap.xml</loc>
		<lastmod>2026-04-21T18:59:51+00:00</lastmod>
	</sitemap>
	<sitemap>
		<loc>https://www.ipersonal.ch/ip_team_subrow-sitemap.xml</loc>
		<lastmod>2026-04-21T18:59:51+00:00</lastmod>
	</sitemap>
	<sitemap>
		<loc>https://www.ipersonal.ch/jobpost_category-sitemap.xml</loc>
		<lastmod>2026-06-20T16:47:52+00:00</lastmod>
	</sitemap>
	<sitemap>
		<loc>https://www.ipersonal.ch/jobpost_job_type-sitemap.xml</loc>
		<lastmod>2026-06-20T16:47:52+00:00</lastmod>
	</sitemap>
	<sitemap>
		<loc>https://www.ipersonal.ch/jobpost_location-sitemap.xml</loc>
		<lastmod>2026-06-20T16:47:52+00:00</lastmod>
	</sitemap>
</sitemapindex>
<!-- XML Sitemap generated by Yoast SEO -->