I am trying to write a peice of code that will hook into this:
var builder_blvd = {
// Enter into editing a layout
edit : function ( name, page )
{
// Get the ID from the beginning
var page = page.split('[(=>)]');
// Prepare the edit tab
$('#builder_blvd .nav-tab-wrapper a.nav-edit-builder').text(themeblvd.edit_layout+': '+name).addClass(page[0]+'-edit');
$('#builder_blvd #edit_layout .ajax-mitt').html(page[1]);
// Setup hints
$('.sortable:not(:has(div))').addClass('empty');
$('.sortable:has(div)').removeClass('empty');
// Setup sortables
$('.sortable').sortable({
handle: '.widget-name',
connectWith: '.sortable'
});
// Sortable binded events
$('.sortable').bind( 'sortreceive', function(event, ui) {
$('.sortable:not(:has(div))').addClass('empty');
$('.sortable:has(div)').removeClass('empty');
});
// Setup widgets
$('#builder_blvd .widget').themeblvd('widgets');
// Setup options
$('#builder_blvd').themeblvd('options', 'setup');
// Take us to the tab
$('#builder_blvd .nav-tab-wrapper a').removeClass('nav-tab-active');
$('#builder_blvd .nav-tab-wrapper a.nav-edit-builder').show().addClass('nav-tab-active');
$('#builder_blvd .group').hide();
$('#builder_blvd .group:last').fadeIn();
}
};
I want to hook into $('#builder_blvd #edit_layout .ajax-mitt').html(page[1]); to trigger a piece of code that removes a DOM element from the that whenever it posts. The above code is from a parent theme and I'd rather leave it untouched if possible.
Here's what I tried to get this working:
jQuery(document).ready(function($) {
$('#builder_blvd #edit_layout .ajax-mitt').bind( 'change', function(event, ui) {
$('#edit_builder #titlediv').remove();
});
});
Any ideas how to fix this?