niceUpload

NiceUpload is a jQuery plug ins that replace the normal file input and makes it much more prettier.  You can adjust and tweak it with CSS if you want.

See the demo here: http://lab.swape.net/niceUpload.1.0/

niceUpload.1.0.zip

Multitag

Multitag is a jQuery plug ins for making nice tag boxes.
Click on the box and start writing a tag names and then press the “,” (comma) or enter button to make a tag

See the demo here: http://lab.swape.net/multitag.1.0/

 

You can download the source from here https://github.com/swape/multitag

Swape Gallery Light

SGL is a php5 script to list pictures. A fat way of making a galery and showing your pictures.

This script finds all the pictures in a directory under ./test_pic/ and makes menus based on directories.

All you have to do is putt your pictures in ./test_pic/ directory. Or edit $strPathToFiles = ‘./test_pic’; in sgl4.class.php file.

You can organize your pictures by category, by putting it under sub-directories.

The thumbs/ directory must be writable (CHMOD 755) to generate thumbnails automatically first time you visit the site. It will help loading your images faster.

HOW TO INSTALL

All you have to do is unzip the file.
Unpack the sgl4.php and configure the paths.

Putt your pictures under ./test_pic/ directory.
And don’t forget to chmod 755 thumbs directory.

SYSTEM REQUIRED.

Server with PHP5.

sgl4.zip

favicon2png

Here is a script to download the favicon.ico files from a website and save it as a png file.

You must have imagemagick installed on your server to convert the ico file to png.

  1.  
  2. <!— html code —->
  3. <form action="?" method="post">
  4.   <input id="site" name="site" type="text"
  5. value="<?php echo $_POST['site']; ?/>" />
  6.   <input type="submit" />
  7. </form>
  8.  
  9. < ?php
  10. //— favicon2png by Alireza Balouch @ swape.net 2008
  11.  
  12. if($_POST[‘site’] != ){
  13.  
  14. //finding the hostname
  15. $host = parse_url($_POST[‘site’]);
  16. $host = $host[‘host’];
  17. $host = explode(‘.’ , $host);
  18. $host = $host[count($host) -2];
  19. $filename = ‘img/’ . $host . ‘.png’;
  20.  
  21. if (!is_file($filename)){
  22. // getting the favicon
  23. $handle = fopen( $_POST[‘site’] . ‘/favicon.ico’, "rb");
  24. $contents = stream_get_contents($handle);
  25. fclose($handle);
  26.  
  27. file_put_contents(‘fav.ico’ , $contents );
  28. // converting to png
  29. $StrExec = ‘/usr/local/bin/convert fav.ico -resize 24×24\> . $filename ;
  30. $ret = exec($StrExec);
  31. }
  32. echo ‘<img src="’ . $filename . ‘" />’ . $_POST[‘site’];
  33. }
  34. ?>

All rights reserved. © Copyright 2012.
Powered by WordPress   Design by swape.net