Richard Castera

Application Developer/Designer
  • Home
  • About
  • Projects
News, Web Resources | No Comments | March 2, 2010

Excellent Analytics – Import Google Analytics into Excel

I ran into this nice Excel Plugin that lets you import web analytics data from Google Analytics into a spreadsheet. It’s an open source project and 100% free to download and use for individuals and businesses.

PHP, Web Resources, Wordpress | 1 Comment | March 1, 2010

WordPress – List Scheduled Posts

If you ever wanted to show you readers posts that are scheduled to be published, here’s how to do it.

<?php
$result = new WP_Query('post_status=future&order=DESC&showposts=5');
if ($result->have_posts()) {
    while ($result->have_posts()) : $result->the_post(); ?>
        <?php the_title(); ?>
    <?php endwhile;
}
?>
Web Resources | No Comments | February 28, 2010

CSS – Cross Browser Opacity

A little hack to set Cross-Browser opacity.

.setOpacity {
      opacity: .75; /* Standard: FF gt 1.5, Opera, Safari */
      filter: alpha(opacity=75); /* IE lt 8 */
      -ms-filter: "alpha(opacity=75)"; /* IE 8 */
      -khtml-opacity: .75; /* Safari 1.x */
      -moz-opacity: .75; /* FF lt 1.5, Netscape */
}
PHP, Wordpress | No Comments | February 25, 2010

WordPress – Disable Auto Save

WordPress’s Auto-Save feature is a really nice but there are some drawbacks… this feature increases your database usage. So for those of you that are on really bad shared hosting accounts or just want to turn it off, here’s a quick way of doing it.

Open and insert the following line in your wp-config.php file.

define('WP_POST_REVISIONS', false);

Another method is to remove all of the entries from the database from time to time. You can do tun this query to do it::

DELETE FROM wp_posts WHERE post_type = "revision";
Javascript, Prototype | No Comments | February 24, 2010

Prototype JS – Determine if an object exists in the page loaded

I’m so use to using jQuery that I usually don’t have to look up documentation on how to use certain functions. They almost come naturally because it’s so English-like! Unfortunately Magento uses Prototype as it’s native choice of Javascript Frameworks. I sure wish they would have chosen jQuery! I think they would have more people jumping on their platform. I’m sure they have a good choice for it. Anyway, here’s how to check:

if($('id_of_element') != undefined) {
    alert('Object exists.');
}
Magento, PHP | No Comments | February 24, 2010

Magento – Check if a User is logged in

You may want to check if a user is logged in with Magento, possibly to display a link or promotional item. Here’s how to do it:

<?php
if ($this->helper('customer')->isLoggedIn()) {
    echo("Anonymous user");
}
else {
    echo("Authenticated user");
}
?>
Magento, PHP | 1 Comment | February 24, 2010

Magento – How to Display the Product SKU

Sometime you may need to display the product Sku on the category page. This is easily achieved:

<?php echo($_product->getSku()); ?>
  • Page 3 of 14
  • <
  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • ...
  • 14
  • >
  • Premium Email Templates

    Social Profiles

  • Twitter
  • Facebook
  • LinkedIn
  • Digg
  • Google
  • GitHub

    Last Tweet

  • Beware the heat-seeking Nerf machine-gun coming to a cubicle near you http://om.ly/svHF #fb
  • Follow me
  • Archives

    • August 2010
    • July 2010
    • June 2010
    • May 2010
    • April 2010
    • March 2010
    • February 2010
    • October 2009
    • September 2009
    • August 2009
    • July 2009
    • June 2009
    • May 2009
    • September 2008
    • August 2008
    • July 2008
    • June 2008
  • Categories

    • AJAX
    • Apache
    • Books
    • Drupal
    • Ecommerce
    • Flash
    • Google
    • Javascript
    • jQuery
    • Magento
    • Marketing
    • Mootools
    • My Thoughts
    • MySQL
    • News
    • Photoshop
    • PHP
    • Prototype
    • SEO
    • Web Resources
    • Wordpress
  • My Favorites

    • 37 Signals
    • Andrew Warner
    • Chris Coyier
    • Chris Shiflett
    • Collis Ta'eed
    • Development Seed
    • Drupal
    • HubSpot
    • James Padolsey
    • Joel On Software
    • John Resig
    • jQuery
    • Kevin Rose
    • Life Hacker
    • Magento
    • Mashable
    • Matt Cutts
    • Matt Ryan
    • MySQL
    • NetTuts
    • Noupe
    • Photoshop Tutorials
    • PHP
    • Smashing Magazine
    • Tech Crunch
    • WoorkUp
    • Wordpress

2010 © Copyright. Richard Castera - All Rights Reserved.

Top