Browsing articles in "Scripts & Apps"
27
Dec

Free JavaScript Slideshow (Lightweight-5kb)

Animated JavaScript Slideshow is a free & lightweight script to display images with style.

It simply turns an unordered list into a gallery which can be customized easily.

You can set it to auto-display the images or it can be browsed manually with the prev-next buttons.

The slideshow provides several other controls like:

  • Speed of the slideshow
  • Information to be displayed or not
  • Opacity of the images & more..

P.S. It does not require any JavaScript library.

Compatibility: All Major Browsers
Website: http://www.leigeber.com/2008/12/javascript-slideshow/
Demo: http://sandbox.leigeber.com/javascript-slideshow/

26
Dec

8 Useful WordPress SQL Hacks

Over the past 10 years, the MySQL database has become incredibly popular on the Web. Every WordPress blog is driven by a MySQL database, which contains the blog’s posts, settings, comments and much more.

While plug-ins and even coding hacks can solve some problems and achieve some tasks, sometimes you don’t have any other choice than to execute SQL commands in phpMyAdmin or directly to the database via SSH. Let’s take a look at 8 useful SQL hacks for WordPress. Each section of this post presents a problem, suggests a solution and provides an explanation to help you understand the solution.

1. Creating a Backup of Your Database

The problem. While the tips in the rest of this post have been tested, you should definitely not try any of them without first having a proper backup of your MySQL database.

The solution. To create a manual backup of your WordPress database, follow these simple steps:

  1. Log in to phpMyAdmin and select your WordPress database.
  2. Once done, click the “Export” button located in the horizontal menu.
  3. Choose a compression method (personally, I use gzip), and click the “Execute” button.
  4. Your browser will ask you if you want to download the backup. Of course, select “Yes,” and then store it on your hard drive.

Explanation. Note that creating a backup of your WordPress database can be more easily executed with the WP-DB-Backup plug-in. WordPress users should install this plug-in if they have not yet done so and create regular backups of their data.

2. Batch Delete Post Revisions

The problem. Post revisions, a new WordPress 2.6 feature, can be very useful, but they also increase the size of your MySQL database. Sure, you can manually delete posts revisions, but that’s very long and boring work.

The solution. The solution to this problem is simple: we batch delete post revisions by using a simple SQL query. The result can be almost unbelievable if you have a lot of posts: Your database size will be reduced by half!

  1. Log in to phpMyAdmin and select your WordPress database.
  2. Click the “SQL” button. Paste the following code in the SQL command window:

    • DELETE FROM wp_posts WHERE post_type = “revision”;
  3. You’re done. Depending on how many posts you had in your WordPress database, you may have saved lots of precious space!

Code explanation. The wp_posts table has a field named post_type. This field can have one of many values, such as “post,” “page” or “revision.” When we want to get rid of post revisions, we simply run a command to delete any entry in the wp_posts table in which the post_type field is equal to “revision.”

Source:

  • How to: Batch delete post revisions

Read the rest of this entry »

26
Dec

jQuery.ScrollTo

Its a small, customizable plugin for scrolling elements or the window itself.

Links

  • Project Page
  • Demo
  • Changelog

Downloads

  • jQuery.ScrollTo 1.4 Zip(all files and docs)
  • jQuery.ScrollTo 1.4 Source(to learn or test)
  • jQuery.ScrollTo 1.4 Minified(recommended)

A visual example of each setting, is shown in the demo.
I really advice using the minified versions. The code is optimized for those releases. Source versions should only be used to learn.

Enjoy animated scrolling with jQuery.

26
Dec

A Markup And BBCode Editor By Corpocrat

Corpocrat is presenting 2 simple & handy editors:

  • Markup editor
  • BBCode editor

They both convert a textarea into an editor & they are lightweight (<5kb).

Links & images are inserted with an alert window rather than a HTML popup.

And, they are free to be used in both personal & commercial projects.

Compatibility: All Major Browsers
Website: http://corpocrat.com/2008/12/18/free-wysiwyg-textare…
Website 2: http://corpocrat.com/2008/08/15/free-wysiwyg-bbcode-…
Demo: http://php-login-script.com/taeditor/demo.htm

24
Dec

How To Detect Mobile Browsers With PHP?

DetectMobileBrowsers.mobi is a website providing a function & information on how to detect mobile browsers.

It can detect:

  • iPhone
  • Opera Mini
  • Android
  • Blackberry

It has an online function generator that guides you to create a personalized function according to “how you want to treat every browser”.

P.S. The code is free to be used on non-profit websites.

Website: http://detectmobilebrowsers.mobi/
Download: http://detectmobilebrowsers.mobi/#download

24
Dec

swffit: Smart Flash Resize Script

As every user has different screen resolutions & browsers can be resized to custom sizes, the browser won’t generate scrollbars at Flash movies with 100% sizes and possibly a part of the content may not be shown to the user.

swffit is a script that that resizes your flash movie automatically if your browser window size is smaller or greater than your flash minimum desired size to keep it accessible.

How to use it?

  • Include swffit.js to your webpage
  • Call the function: swffit.fit("my_flash", 1000, 590);
  • That’s all

swffit can also be controlled with an API including enabling/disabling it or adding functions when it is activated & more.

Website: http://swffit.millermedeiros.com/
Demo: http://swffit.millermedeiros.com/example.html

23
Dec

Free And Ajaxed IMAP Client: Xuheki

Xuheki is an open source IMAP client with an Ajaxed interface.

It looks-feels like a desktop application & supports multiple IMAP servers/identities.

It uses the Net::IMAP::Client Perl module as the IMAP engine & built with DynarchLIB Ajax Toolkit.

Some features of Xuheki:

  • Supports multiple folders with drag’n drop
  • It can stay connected to an IMAP server
  • Interface allows you to do multiple things once
  • Multiple user support
  • Contact list & more..

It requires Perl & MySQL 5 to run.

Requirements: Perl 5.8+, Apache 2+,mod_perl 2+,MySQL 5+
Compatibility: IE can have problems (not well tested)
Website: http://www.xuheki.com/
Download: http://www.xuheki.com/download/

22
Dec

Seo Enabled Urls In Flash And Ajax

Macromedia Flash & ajax, by default, has lacking seo features as there is, normally, only 1 url address for all the contents within these web applications.

A seo & deep linking solution for flash and ajax is SWFAddress that is developed by Asual.

SWFAddress is a small, but powerful library that provides deep linking for Flash and Ajax. It’s a developer tool, allowing creation of unique virtual URLs that can point to a website section or an application state. SWFAddress enables a number of important capabilities which are missing in today’s rich web technologies including:

- Bookmarking in a browser or social website
- Sending links via email or instant messenger
- Finding specific content with the major search engines
- Utilizing browser history and reload buttons

Seo & deep linking for Silverlight is on the way. There is already an example for Silverlight.

Website: http://www.asual.com/swfaddress
Demo: http://www.asual.com/swfaddress/samples/

Categories:

Tags:

comments
22
Dec

Ajaxify: Instantly Ajax Static Websites

Ajaxify is a jQuery plugin that converts all links in a web page into Ajax load-submit requests.

So, with a single line, you can turn a static website into an Ajaxed one.

It has support for:

  • History & bookmarking
  • Partial load from the output
  • Four events
  • Forms
  • Animations

In the demos page of Ajaxify, there are lots of examples presented to get you going with it.

Requirements: jQuery
Compatibility: All Major Browsers
Website: http://max.jsrhost.com/ajaxify/

Demo: http://max.jsrhost.com/ajaxify/demo.php

Categories:

Tags:

comments
21
Dec

sIFR Lite: Much Smaller (Maybe Better) sIFR

sIFR is one of the most popular solutions for using any font on websites.

There is now another similar solution named sIFR Lite which has some new features but specially much lighter (3.7kb rather than 22kb).

Here are the other differences:

  • It auto-detects the text color of the elements (they are entered manually in sIFR).
  • It is completely object-oriented.
  • It no longer uses CSS selectors. Elements are targeted by tag name and class (a slight loss in ease of use, but faster, lighter, and more maintainable).

The original sIFR is well-tested & widely used but sIFR-Lite is not. So, it would be great to hear your experiences about sIFR-Lite.

Compatibility: All Major Browsers
Website: http://www.allcrunchy.com/Web_Stuff/sIFR_lite/

Creative Resume Template
Open source icons