Moving the map

  • Author
    Posts
  • Kierrah

    Hi!

    I’m trying to use Hivepress to spin up an MVP quickly and it looks almost perfect for this but I cannot figure out how to customise the layout. I need to move the map to bigger and more prominent at the top of the listing page but I can’t figure out how to do this? What files am I supposed to be looking at?

    Any help is much appreciated, I’ve been away from WordPress for a few years and I’m a bit lost here.

    Thanks,
    Kierrah

    ihordeveloper

    Thanks! You can try using this PHP snippet to move it to the top:

    add_filter(
    	'hivepress/v1/templates/listings_view_page',
    	function( $template ) {
    		return hivepress()->helper->merge_trees(
    			$template,
    			[
    				'blocks' => [
    					'listing_map' => [
    						'type' => 'content',
    					],
    
    					'page_header' => [
    						'blocks' => [
    							'listing_map' => [
    								'type'   => 'listing_map',
    								'_order' => 15,
    							],
    						],
    					],
    				],
    			]
    		);
    	},
    	1000
    );

    And then adjust its height via CSS:

    .hp-page__header .hp-map {height:200px!important}

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.

Subscribe

Sign In

Don't have an account? Register

Forgot password?

Register

Already have an account? Sign In

Forgot password?

Reset Password

Please enter your username or email address, you will receive a link to create a new password via email.