Tag: Wordpress

Last.fm RPS WordPress Plugin

I’ve completely rewritten the plugin after 8 years, because the code was targeting PHP4 platforms and now it should work with all PHP5+ versions.

Still does the same thing: Its a widget plugin which collects data from Audioscrobbler web services and gets your last listened tracks and their album images.

Download : You can get the latest release here : http://wordpress.org/extend/plugins/lastfm-rps/

Then just activate the plugin, go to Design-Widgets, add the widget where you want, write the username and widget title in the settings and save. That’s all.

Current Version : 2.0.0

Demo : You can see a working example in the right sidebar.

about costabrava hack and some fix.


Türkçe:
Hostunuzdaki bütün php dosyalarınıza eval ve base64_decode kodunu kullanan ve google’da sitenizi aratıp linkinize tıkladığınız zaman costabrava diye bir siteye yönlendiren bir enfeksiyonunuz varsa altta paylaştığım fixcosta.rar dosyasını açıp içindeki PHP dosyasını hostunuza yüklüyorsunuz ve çalıştırıyorsunuz. sitenizdeki zararlı kodlar (eğer modifikasyona uğramamamışsa) temizleniyor.

Kaynak olarak http://redleg-redleg.blogspot.com/p/simple-script-to-find-base64decode-in.html adresindeki virüs bulucu kodu kullandım ve üzerine temizleyen kodu ekledim.

Daha sonra, eğer hostunuzda wordpress kurulu ise ve temalarınız arasında TwentyTen teması varsa, ve kullanmıyorsanız, silin.

 

English: Today I had this on my server and needed to fix like a hundred files which are infected with some nasty redirection script. So I wrote this php file to remove all the injected codes from my php files and I decided to share with you.

You can check if your server is infected or not by googling your web site and then clicking the link. If it opens your site, it’s ok. But if it redirects to “costabrava.bee.pl“, your server is infected. You should do something.

Its based on http://redleg-redleg.blogspot.com/p/simple-script-to-find-base64decode-in.html which finds the infected files, and I added the code to remove the costabrava.bee.pl header.

First, download the code below here and unrar it. there’s one php file named “fixcosta.php” and upload it into your server’s root directory. then run it.

Second, if you’re not using TwentyTen theme, delete the folder from wp-content/themes.

This’ll fix it for now. Then you should search how the hacker got into your ftp and uploaded these files. And find a fix for that too.

pngfix WordPress Plugin

This plugin uses CSS technique to fix the png image transparency issue and jQuery to apply this script to all of png images shown in the page. The CSS code added by the script is :

.png {
background-image: expression(
this.runtimeStyle.filter = "progid:DXImageTransform.Microsoft.AlphaImageLoader(src=" + (this.tagName==\'IMG\' ? this[\'src\'] : this.currentStyle[\'backgroundImage\'].split(\'\"\')[1]) + ")",
this.runtimeStyle.backgroundImage = "none",
this.src = "{plugindir}/pixel.gif",
this.width = this.style.width | this.clientWidth,
this.height = this.style.height | this.clientHeight
);
}';

And the jQuery code which applies this css to all of the png images :

$(document).ready(function(){
if(($.browser.msie)&(parseInt($.browser.version)<7)){
$("img[src$='.png']").each(function(){$(this).addClass("png");});
}
});

That’s all. The jQuery library is included in the plugin so you don’t need to modify anything.

Installation is simple. Just follow these steps :

  1. Upload ‘wp-pngfix’ directory to the ‘/wp-content/plugins/’ directory
  2. Activate the plugin through the ‘Plugins’ menu in WordPress
  3. Thats all. Go to any page which contains some png images with IE and check if there’s any errors.

This should fix them all except backgrounds now.

Download: Official WordPress plugin page : http://wordpress.org/extend/plugins/wp-pngfix/

Note: This type of fixes cause slight color changes to your png images with background color, so you may have to change some css.If you use images without inner backgrounds and only need to show the background transparent, forget that note 🙂

Last.fm RPS

Follow me on Twitter

GiottoPress by Enrique Chavez