• Hi,
    Im developing a new pluging and I need help.
    I made a Geo Positional aplication outside Worpress and now Im trying to conect it to WordPress.
    My aplication consists on Maps por GPS devices and I want to add some WP post with the maps helping people to guide.
    My guide is the oficial wp-template-hierarchy:
    wp-template-hierarchy.png
    My aplication output a variable $map_id that is numeric ($map_id=1, $map_id=3, etc).
    I get to echo the global variable in the index.php(WP output ) as:
    <?php echo 'The MAP ID is: ' . $map_id; ?>
    The problem is that I dont know how to assign a particular page to each map(always dispalys the worpress prontpage).
    For example:
    https://www.geoserver.com/?map=2
    (wordpress is installed in root, and working)

    Then I created a in wp-admin/edit.php?post_type=page a SINGULAR PAGE-STATIC PAGE that is variable post=2.

    Now I need to wordpress to shows the post_id=2(at bottom) when the map_id=2 is on top.

    Im trying modifing this part:

    function xmlrpc_getpostcategory( $content ) {
    	global $post_default_category;
    	if ( preg_match( '/<category>(.+?)<\/category>/is', $content, $matchcat ) ) {
    		$post_category = trim( $matchcat[1], ',' );
    		$post_category = explode( ',', $post_category );
    	} else {
    		$post_category = $post_default_category;
    	}
    	return $post_category;
    }

    I tried:

    } else {
    		$post_category = $map_id;

    No luck. Some help where to search or some advice.

  • The topic ‘[Plugin WP Geo Posts]’ is closed to new replies.