Skip to main content
Category

Wordpress

Get Children Pages

By Wordpress No Comments

$my_wp_query = new WP_Query();$all_wp_pages = $my_wp_query->query(array(‘post_type’ => ‘page’)); // Obtienes las páginas como un objeto$portfolio =  get_page_by_title($title);  //Debes obtener el title de la página actual antes y ponerlo acá $portfolio_children…

Read More

Limit WordPress Content

By Wordpress No Comments

function content($limit,$content) {  $content = explode(‘ ‘, $content, $limit);  if (count($content)>=$limit) {    array_pop($content);    $content = implode(» «,$content).’…’;  } else {    $content = implode(» «,$content);  }  $content =…

Read More

ACF bootstrap slider

By Wordpress No Comments

ACF: HTML: <div id=»bootstrap-touch-slider» class=»carousel bs-slider fade  control-round indicators-line hidden-xs hidden-sm» data-ride=»carousel» data-pause=»hover» data-interval=»5000″ >   <!– Indicators –>   <ol class=»carousel-indicators»>       <?php       // check if the repeater…

Read More

Esconder Wysiwyg WordPress Editor

By Wordpress No Comments

En functions.php  agrega lo siguiente: add_action( ‘admin_init’, ‘hide_editor’ );function hide_editor() {  // Get the Post ID.  $post_id = $_GET[‘post’] ? $_GET[‘post’] : $_POST[‘post_ID’] ; $cats = get_the_category();  $cat_name = $cats[0]->name;…

Read More

Galleryview nextgen open image on click

By Wordpress No Comments

Edit file   plugins/wordpress-nextgen-galleryview/GalleryView/scripts/jquery.galleryview-2.0.jsline 873  aprox. else {                        p = $(»);   //(before: p = $(»);                        p.attr(«href», j_frames.eq(i).find(‘img’).eq(0).attr(‘src’));   //(include this line)       …

Read More