Title: Gustavo Lanzas's Replies | WordPress.org

---

# Gustavo Lanzas

  [  ](https://wordpress.org/support/users/audioel/)

 *   [Profile](https://wordpress.org/support/users/audioel/)
 *   [Topics Started](https://wordpress.org/support/users/audioel/topics/)
 *   [Replies Created](https://wordpress.org/support/users/audioel/replies/)
 *   [Reviews Written](https://wordpress.org/support/users/audioel/reviews/)
 *   [Topics Replied To](https://wordpress.org/support/users/audioel/replied-to/)
 *   [Engagements](https://wordpress.org/support/users/audioel/engagements/)
 *   [Favorites](https://wordpress.org/support/users/audioel/favorites/)

 Search replies:

## Forum Replies Created

Viewing 9 replies - 1 through 9 (of 9 total)

 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[CAS Maestro] has_cap deprecated since version 2.0.0](https://wordpress.org/support/topic/has_cap-deprecated-since-version-2-0-0/)
 *  [Gustavo Lanzas](https://wordpress.org/support/users/audioel/)
 * (@audioel)
 * [8 years, 6 months ago](https://wordpress.org/support/topic/has_cap-deprecated-since-version-2-0-0/#post-9849090)
 * Hey Joe – I fixed this a few months back for an instance I run for a college 
   library website. The issue is where the menu page and options page are added.
   In the current code, it uses a numeric capability (which is deprecated). I replaced
   it with a named capability (‘manage_options’), and was able to fix the issue.
 * You can find the menu page code around line #432, and the options code around
   line #443 of cas-maestro.php
 * Old:
 *     ```
       $settings_page = add_options_page(__('CAS Maestro', "CAS_Maestro"), 
       						__('CAS Maestro', "CAS_Maestro"), 8, 
       						'wpcas_settings', 
       						array(&$this,'admin_interface'));
       ```
   
 * Updated:
 *     ```
       $settings_page = add_options_page(
       					    __('CAS Maestro', "CAS_Maestro"),
                               __('CAS Maestro', "CAS_Maestro"),
                               'manage_options',
       						'wpcas_settings', 
       						array(&$this,'admin_interface')
                           );
       ```
   
 * Hope this helps!
 *   Forum: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   In reply to: [java exploit hack in wp 3.3. beta](https://wordpress.org/support/topic/java-exploit-hack-in-wp-33-beta/)
 *  [Gustavo Lanzas](https://wordpress.org/support/users/audioel/)
 * (@audioel)
 * [14 years, 2 months ago](https://wordpress.org/support/topic/java-exploit-hack-in-wp-33-beta/page/2/#post-2347797)
 * Tekno23 – thank you so much for doing that! Worked great, and I had a LOT of 
   sites to run it on.
 * Does anyone have any idea how this code is getting injected in?
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Timely All-in-One Events Calendar] [Plugin: All-in-One Event Calendar] CSS](https://wordpress.org/support/topic/plugin-all-in-one-event-calendar-css/)
 *  [Gustavo Lanzas](https://wordpress.org/support/users/audioel/)
 * (@audioel)
 * [14 years, 7 months ago](https://wordpress.org/support/topic/plugin-all-in-one-event-calendar-css/#post-2416282)
 * You guys should do what almost everyone else (like the events calendar) does 
   and allow the user to copy template / css files to the theme directory, and edit
   them there. It’s not too hard to have your plugin check to see if the files are
   there before rendering.
 * This is pretty much a foolproof way of letting users have full customization 
   control, and you don’t have to worry about breaking anything when there’s an 
   update.
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Custom Field Template] [Plugin: Custom Field Template] Multiple custom field](https://wordpress.org/support/topic/plugin-custom-field-template-multiple-custom-field/)
 *  [Gustavo Lanzas](https://wordpress.org/support/users/audioel/)
 * (@audioel)
 * [14 years, 8 months ago](https://wordpress.org/support/topic/plugin-custom-field-template-multiple-custom-field/#post-2324555)
 * You can create a lot more than two templates – not sure how many, but the plugin
   will keep adding one more blank template to the admin as you fill them in.
 * Not sure what you mean by “formats”.
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[The Events Calendar] [Plugin: The Events Calendar] All day selector issue & times don't stick](https://wordpress.org/support/topic/plugin-the-events-calendar-all-day-selector-issue-times-dont-stick/)
 *  [Gustavo Lanzas](https://wordpress.org/support/users/audioel/)
 * (@audioel)
 * [14 years, 9 months ago](https://wordpress.org/support/topic/plugin-the-events-calendar-all-day-selector-issue-times-dont-stick/#post-2306007)
 * I’m having the same exact problem here. Not sure when this started happening,
   since the site has been running for some time. Using WP 3.2.1 and TEC 1.6.5.
 *   Forum: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   In reply to: [[Plugin: Custom Field Template] File and Image Display](https://wordpress.org/support/topic/plugin-custom-field-template-file-and-image-display/)
 *  [Gustavo Lanzas](https://wordpress.org/support/users/audioel/)
 * (@audioel)
 * [15 years, 7 months ago](https://wordpress.org/support/topic/plugin-custom-field-template-file-and-image-display/#post-1332763)
 * Linicio – all you have to do is wrap an if statement around the button:
 *     ```
       <?php if($downloadlink = get_post_meta($post->ID, 'download_link', true)) { ?>
   
       <a href="<?php echo $downloadlink; ?>">Download</a>
   
       <?php }; ?>
       ```
   
 * if you want it to do something else instead of just disappear, replace the last
   line with:
 *     ```
       <?php } else { ?>
   
       <b>Nothing to download here!</b>
   
       <?php }; ?>
       ```
   
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Photo Gallery, Sliders, Proofing and Themes - NextGEN Gallery] [Plugin: NextGEN Gallery] How to add navigation within the Album or Gallery](https://wordpress.org/support/topic/plugin-nextgen-gallery-how-to-add-navigation-within-the-album-or-gallery/)
 *  [Gustavo Lanzas](https://wordpress.org/support/users/audioel/)
 * (@audioel)
 * [15 years, 10 months ago](https://wordpress.org/support/topic/plugin-nextgen-gallery-how-to-add-navigation-within-the-album-or-gallery/#post-1641615)
 * Mfro – it goes in gallery.php. However, please keep in mind that the code as 
   above doesn’t work 100% – it only works when you’re navigating to a gallery from
   an album, embedded in the same page.
 * I may have a much better solution soon – but I’m under deadline right now, so
   it will take me a little bit to post. 🙂
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Photo Gallery, Sliders, Proofing and Themes - NextGEN Gallery] [Plugin: NextGEN Gallery] How to add navigation within the Album or Gallery](https://wordpress.org/support/topic/plugin-nextgen-gallery-how-to-add-navigation-within-the-album-or-gallery/)
 *  [Gustavo Lanzas](https://wordpress.org/support/users/audioel/)
 * (@audioel)
 * [15 years, 10 months ago](https://wordpress.org/support/topic/plugin-nextgen-gallery-how-to-add-navigation-within-the-album-or-gallery/#post-1641604)
 * I have a very convoluted way of doing this right now, but it works fine as long
   as you navigate to the gallery from an album. I’m sure there’s a much easier,
   elegant way of doing this. 🙂
 * Does anyone have any idea how to pull $album into the gallery template? I’m doing
   this right now:
 * `$album = nggdb::find_album( get_query_var('album') );`
 * And it only seems to grab it when you navigate from an album.
 *     ```
       <?php
       /* create album navigation */
       $slug = basename(get_permalink());
        $galleries = array();
           $query = "SELECT * FROM <code>wp_ngg_gallery</code> ORDER BY <code>wp_ngg_gallery</code>.<code>gid</code> ASC";
               $result = mysql_query($query) or die(mysql_error()); ?>
   
       <div class="gallery_navigation">   
   
       <?php    /* create array with results keyed by gid */
           while($row = mysql_fetch_array($result)){
               $galleries[$row['gid']]  = stripslashes($row['title']);
           };
           /* build links for galleries */
           foreach ( $album->gallery_ids as $gals ) {
           $nav .= '<li class="menu-item"><a href="'.get_bloginfo('url').'/photo-galleries/'.$slug.'/?album='.$album->id.'&gallery='.$gals.'">'.$galleries[$gals].'</a></li>';
           };
       ?>
   
       <ul class="menu">
       <li class="title"><?php echo $album->name.":"; ?></li>
       <?php echo $nav; ?>
       </ul>
   
       <script>
       // add current location to gallery navigation
   
       jQuery(window).load(
           function() {
               jQuery("ul.menu li.menu-item:contains('<?php echo $gallery->title; ?>')").addClass("current");
           }
       );
       </script>
   
       </div> <!-- end gallery navigation -->
       ```
   
 * Thanks,
 * Gustavo
 *   Forum: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   In reply to: [Incompatible archive: PCLZIP_ERR_BAD_FORMAT (-10)](https://wordpress.org/support/topic/incompatible-archive-pclzip_err_bad_format-10/)
 *  [Gustavo Lanzas](https://wordpress.org/support/users/audioel/)
 * (@audioel)
 * [16 years, 6 months ago](https://wordpress.org/support/topic/incompatible-archive-pclzip_err_bad_format-10/page/2/#post-1108768)
 * Hello, I had the same problem since 2.8.2, and I solved it by commenting out 
   mbstring.func_overload in my php.ini file:
 * `; mbstring.func_overload = 7`
 * Upgrades and uploads worked perfectly after that.

Viewing 9 replies - 1 through 9 (of 9 total)