This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SET @oldsite='http://localhost.com'; | |
SET @newsite='http://producao.com.br'; | |
UPDATE wp_options SET option_value = replace(option_value, @oldsite, @newsite) WHERE option_name = 'home' OR option_name = 'siteurl'; | |
UPDATE wp_posts SET post_content = replace(post_content, @oldsite, @newsite); | |
UPDATE wp_links SET link_url = replace(link_url, @oldsite, @newsite); | |
UPDATE wp_postmeta SET meta_value = replace(meta_value, @oldsite, @newsite); | |
UPDATE wp_posts SET guid = replace(guid, @oldsite, @newsite); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Function get_excerpt | |
* | |
* @since 0.1 | |
* | |
* @param string $content with text to excerpt. | |
* @param string $limit number of the limit. | |
* @param string $after with element to print in end excerpt. | |
* | |
* @return string |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// Versão funcionando, pelo menos para minha necessidade | |
// Essa função é disparada com alguns critérios em uma página usada apenas para essa migração. | |
function migration() { | |
include( 'wp-admin/includes/media.php' ); | |
include( 'wp-admin/includes/file.php' ); | |
include( 'wp-admin/includes/image.php' ); | |
$query = new WP_Query( array( | |
'post_type' => 'post', /* O post type que vai usar*/ | |
'posts_per_page' => -1, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(function($){ | |
$('.menu-clientes').on('click', function () { | |
$('html, body').animate({ | |
scrollTop: $("#clientes").offset().top-40 | |
}, 2000); | |
}); | |
})(jQuery); |
NewerOlder