форум фотошопа и поддержки пользователей

Объявление

Информация о пользователе

Привет, Гость! Войдите или зарегистрируйтесь.


Вы здесь » форум фотошопа и поддержки пользователей » Скрипты » Скрипты сделанные для вас


Скрипты сделанные для вас

Сообщений 1 страница 11 из 11

1

Предупредитель Почты:

Код:
<script language="JavaScript">
var str = new String(document.getElementById("navpm").innerHTML)
var str2 = new String(document.location)

if( (str.indexOf("(") != -1) && (str2.indexOf("messages.php") == -1) )
{
alert("Текст")

}
</script>

Всё работает!Проверенно

0

2

Вставка видео на форум

Код:
<script>
function addSpoiler(str,from,internal){
var pos=0,pos2=0,newpos=0
if((pos=str.indexOf("[youtube]",from))==-1) return str;
if((pos2=str.indexOf("[/youtube]"),pos+9)==-1) return str;
newpos=str.indexOf("[youtube]",pos+9)
if(newpos<pos2 && newpos!=-1) str=addSpoiler(str,pos+9,true)
if((pos2=str.indexOf("[/youtube]",pos+9))==-1) return str;
str=str.substring(0,pos)+makeSpoiler(str.substring(pos+9,pos2))+str.substring(pos2+10,str.length)
if( str.indexOf("[youtube]")!=-1 && internal==false) str=addSpoiler(str,0,false)
return str}

function makeSpoiler(txt){
txt="<br><embed src=\"http://www.youtube.com/v/"+txt+"\" type=\"application/x-shockwave-flash\" wmode=\"transparent\" width=\"425\" height=\"350\"></embed><br>"
return txt}

0

3

выделение на 6 групп

Код:
<script type="text/javascript">
        var arr=document.links
        var arr1=new Array ("", "")
        var arr2=new Array ("", "", "", "")
        var arr3=new Array ("", "", "", "")
        var arr4=new Array ("", "", "", "", "")
        var arr5=new Array ("", "", "", "", "")
        var arr6=new Array ("", "", "", "", "")
        for (x in arr)
        {for (y in arr1)
        {if (arr[x].innerHTML==arr1[y])
        {
        arr[x].innerHTML="<font color='red'>"+arr[x].innerHTML+"</font>"}
        }}

        for (x in arr)
        {for (j in arr2)
        {if (arr[x].innerHTML==arr2[j])
        {
        arr[x].innerHTML="<font color='blue'>"+arr[x].innerHTML+"</font>"}}}

        for (x in arr)
        {for (l in arr3)
        {if (arr[x].innerHTML==arr3[l])
        {
        arr[x].innerHTML="<font color='orange'>"+arr[x].innerHTML+"</font>"}}}

        for (x in arr)
        {for (j in arr4)
        {if (arr[x].innerHTML==arr4[j])
        {
        arr[x].innerHTML="<font color='green'>"+arr[x].innerHTML+"</font>"}}}

        for (x in arr)
        {for (p in arr5)
        {if (arr[x].innerHTML==arr5[p])
        {
        arr[x].innerHTML="<font color='yellow'>"+arr[x].innerHTML+"</font>"}}}

        for (x in arr)
        {for (s in arr6)
        {if (arr[x].innerHTML==arr6[s])
        {
        arr[x].innerHTML="<font color='pink'>"+arr[x].innerHTML+"</font>"}}}

        </script>

0

4

Задний фон

Код:
<style type="text/css">
HTML, BODY {
background: url(' картинка ') repeat;
}
</style>

0

5

Дополнительные смайлы

Код:
<a title="Цветы" href="javascript:void(0); return false;" 

onclick="bbcode('[img]' + this.firstChild.src + '[/img]', ''); return false;"><img border="0" 

src="http://casa-latina.ru/s/s/icon_megablumen.gif"/></a>
<a title="Воздушый поцелуй" href="javascript:void(0); return false;" 

onclick="bbcode('[img]' + this.firstChild.src + '[/img]', ''); return false;"><img border="0" 

src="http://casa-latina.ru/s/s/icon_megakusshand.gif"/></a>
<a title="Согласен" href="javascript:void(0); return false;" 

onclick="bbcode('[img]' + this.firstChild.src + '[/img]', ''); return false;"><img border="0" 

src="http://casa-latina.ru/s/s/icon_daumenhoch.gif"/></a>
<a title="Укол" href="javascript:void(0); return false;" 

onclick="bbcode('[img]' + this.firstChild.src + '[/img]', ''); return false;"><img border="0" 

src="http://casa-latina.ru/s/s/icon_megaschwester.gif"/></a>
<a title="Нюня" href="javascript:void(0); return false;" 

onclick="bbcode('[img]' + this.firstChild.src + '[/img]', ''); return false;"><img border="0" 

src="http://casa-latina.ru/s/s/icon_megaheul.gif"/></a>
<a title="Ж..." href="javascript:void(0); return false;" 

onclick="bbcode('[img]' + this.firstChild.src + '[/img]', ''); return false;"><img border="0" 

src="http://casa-latina.ru/s/s/icon_mega_arsch.gif"/></a>
<a title="Злость [смайлики от 0pk.ru]" href="javascript:void(0); return false;" 

onclick="bbcode('[img]' + this.firstChild.src + '[/img]', ''); return false;"><img border="0" 

src="http://casa-latina.ru/s/s/icon_neinnein.gif"/></a>
<a title="Удвление" href="javascript:void(0); return false;" 

onclick="bbcode('[img]' + this.firstChild.src + '[/img]', ''); return false;"><img border="0" 

src="http://casa-latina.ru/s/s/icon_EM08_T.gif"/></a>
<a title="Ээээ" href="javascript:void(0); return false;" 

onclick="bbcode('[img]' + this.firstChild.src + '[/img]', ''); return false;"><img border="0" 

src="http://casa-latina.ru/s/s/icon_megafliege.gif"/></a>
<a title="ROFL" href="javascript:void(0); return false;" 

onclick="bbcode('[img]' + this.firstChild.src + '[/img]', ''); return false;"><img border="0" 

src="http://casa-latina.ru/s/s/icon_auslachen.gif"/></a>
<a title="Смешной" href="javascript:void(0); return false;" 

onclick="bbcode('[img]' + this.firstChild.src + '[/img]', ''); return false;"><img border="0" 

src="http://casa-latina.ru/s/s/icon_megahuepf.gif"/></a>
<a title="Люблю" href="javascript:void(0); return false;" 

onclick="bbcode('[img]' + this.firstChild.src + '[/img]', ''); return false;"><img border="0" 

src="http://casa-latina.ru/s/s/icon_loveheart.gif"/></a>
<a title="Ангелочек" href="javascript:void(0); return false;" 

onclick="bbcode('[img]' + this.firstChild.src + '[/img]', ''); return false;"><img border="0" 

src="http://casa-latina.ru/s/s/icon_megaengel.gif"/></a>
<a title="Засыпаю" href="javascript:void(0); return false;" 

onclick="bbcode('[img]' + this.firstChild.src + '[/img]', ''); return false;"><img border="0" 

src="http://casa-latina.ru/s/s/icon_megaschlafen.gif"/></a>
<a title="Фигу тебе" href="javascript:void(0); return false;" 

onclick="bbcode('[img]' + this.firstChild.src + '[/img]', ''); return false;"><img border="0" 

src="http://casa-latina.ru/s/s/icon_megaschlabber.gif"/></a>
<a title="Утомлен" href="javascript:void(0); return false;" 

onclick="bbcode('[img]' + this.firstChild.src + '[/img]', ''); return false;"><img border="0" 

src="http://casa-latina.ru/s/s/icon_megaschwitzen.gif"/></a>

<a title="Прикольно" href="javascript:void(0); return false;" 

onclick="bbcode('[img]' + this.firstChild.src + '[/img]', ''); return false;"><img border="0" 

src="http://i013.radikal.ru/0803/5a/63d3908653b9.gif"/></a>


<a title="Ой я не могу" href="javascript:void(0); return false;" 

onclick="bbcode('[img]' + this.firstChild.src + '[/img]', ''); return false;"><img border="0" 

src="http://i033.radikal.ru/0803/2e/d2db4726f00f.gif"/></a>


<a title="Подарочек" href="javascript:void(0); return false;" 

onclick="bbcode('[img]' + this.firstChild.src + '[/img]', ''); return false;"><img border="0" 

src="http://i012.radikal.ru/0803/82/b4322276be6a.gif"/></a>


<a title="Я тебя люблю" href="javascript:void(0); return false;" 

onclick="bbcode('[img]' + this.firstChild.src + '[/img]', ''); return false;"><img border="0" 

src="http://i016.radikal.ru/0803/82/f16715024151.gif"/></a>


<a title="Хны - Хны" href="javascript:void(0); return false;" 

onclick="bbcode('[img]' + this.firstChild.src + '[/img]', ''); return false;"><img border="0" 

src="http://i032.radikal.ru/0803/0a/4276f19ba896.gif"/></a>


<a title="Серьезен" href="javascript:void(0); return false;" 

onclick="bbcode('[img]' + this.firstChild.src + '[/img]', ''); return false;"><img border="0" 

src="http://i030.radikal.ru/0803/ef/627fc0a488d1.gif"/></a>



<a title="Будем" href="javascript:void(0); return false;" 

onclick="bbcode('[img]' + this.firstChild.src + '[/img]', ''); return false;"><img border="0" 

src="http://i021.radikal.ru/0803/cf/b83d06a36d74.gif"/></a>



<a title="Грозный" href="javascript:void(0); return false;" 

onclick="bbcode('[img]' + this.firstChild.src + '[/img]', ''); return false;"><img border="0" 

src="http://i038.radikal.ru/0803/8f/6b2860cb8be8.gif"/></a>



<a title="Ля-ля-ля" href="javascript:void(0); return false;" 

onclick="bbcode('[img]' + this.firstChild.src + '[/img]', ''); return false;"><img border="0" 

src="http://i036.radikal.ru/0803/ee/d7846edb83d2.gif"/></a>


<a title="Не-а" href="javascript:void(0); return false;" 

onclick="bbcode('[img]' + this.firstChild.src + '[/img]', ''); return false;"><img border="0" 

src="http://i024.radikal.ru/0803/0f/8ee4b478fd2a.gif"/></a>


<a title="Салют" href="javascript:void(0); return false;" 

onclick="bbcode('[img]' + this.firstChild.src + '[/img]', ''); return false;"><img border="0" 

src="http://i014.radikal.ru/0803/20/7edc0c89e803.gif"/></a>


<a title="Куп-купаюсь" href="javascript:void(0); return false;" 

onclick="bbcode('[img]' + this.firstChild.src + '[/img]', ''); return false;"><img border="0" 

src="http://i013.radikal.ru/0803/05/096181c7da66.gif"/></a>

0

6

Дополнительные цвета

Код:
<table><tr>
<td onclick="return changeVisibility('mycolor', this)"><img src="http://forum.mybb.ru/i/color_swatch.png" alt="Мои цвета" /></td></tr></table>
<div class="container" id="mycolor" style="display:none; width:200px">
	<table cellspacing="0">
<tr>
<td style="background-color:#00FF00" height="15px" width="15px" onclick="bbcode('[color=#00FF00]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#00FF66" height="15px" width="15px" onclick="bbcode('[color=#00FF66]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#00FFFF" height="15px" width="15px" onclick="bbcode('[color=#00FFFF]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#66FF66" height="15px" width="15px" onclick="bbcode('[color=#66FF66]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#99FF99" height="15px" width="15px" onclick="bbcode('[color=#99FF99]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#CCFF00" height="15px" width="15px" onclick="bbcode('[color=#CCFF00]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#CCFF66" height="15px" width="15px" onclick="bbcode('[color=#CCFF66]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#CCFFCC" height="15px" width="15px" onclick="bbcode('[color=#CCFFCC]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#FFFF00" height="15px" width="15px" onclick="bbcode('[color=#FFFF00]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#FFFF99" height="15px" width="15px" onclick="bbcode('[color=#FFFF99]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#00CC66" height="15px" width="15px" onclick="bbcode('[color=#00CC66]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#339966" height="15px" width="15px" onclick="bbcode('[color=#339966]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#6699CC" height="15px" width="15px" onclick="bbcode('[color=#6699CC]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#CCCC66" height="15px" width="15px" onclick="bbcode('[color=#CCCC66]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#009966" height="15px" width="15px" onclick="bbcode('[color=#009966]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#9999FF" height="15px" width="15px" onclick="bbcode('[color=#9999FF]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#CC9933" height="15px" width="15px" onclick="bbcode('[color=#CC9933]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#CC66CC" height="15px" width="15px" onclick="bbcode('[color=#CC66CC]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#FF6600" height="15px" width="15px" onclick="bbcode('[color=#FF6600]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#FF6666" height="15px" width="15px" onclick="bbcode('[color=#FF6666]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#003333" height="15px" width="15px" onclick="bbcode('[color=#003333]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#003366" height="15px" width="15px" onclick="bbcode('[color=#003366]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#0033FF" height="15px" width="15px" onclick="bbcode('[color=#0033FF]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#333300" height="15px" width="15px" onclick="bbcode('[color=#333300]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#663399" height="15px" width="15px" onclick="bbcode('[color=#663399]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#993300" height="15px" width="15px" onclick="bbcode('[color=#993300]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#CC3333" height="15px" width="15px" onclick="bbcode('[color=#CC3333]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#FF3300" height="15px" width="15px" onclick="bbcode('[color=#FF3300]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#FF66FF" height="15px" width="15px" onclick="bbcode('[color=#FF66FF]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#003366" height="15px" width="15px" onclick="bbcode('[color=#003366]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#FF3366" height="15px" width="15px" onclick="bbcode('[color=#FF3366]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#0000FF" height="15px" width="15px" onclick="bbcode('[color=#0000FF]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#660033" height="15px" width="15px" onclick="bbcode('[color=#660033]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#990000" height="15px" width="15px" onclick="bbcode('[color=#990000]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#FF0000" height="15px" width="15px" onclick="bbcode('[color=#FF0000]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#FF0066" height="15px" width="15px" onclick="bbcode('[color=#FF0066]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#FFCCCC" height="15px" width="15px" onclick="bbcode('[color=#FFCCCC]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#ffcc66" height="15px" width="15px" onclick="bbcode('[color=#ffcc66]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#666633" height="15px" width="15px" onclick="bbcode('[color=#666633]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#cc6633" height="15px" width="15px" onclick="bbcode('[color=#cc6633]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#993300" height="15px" width="15px" onclick="bbcode('[color=#993300]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#99ff00" height="15px" width="15px" onclick="bbcode('[color=#99ff00]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#cccccc" height="15px" width="15px" onclick="bbcode('[color=#cccccc]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#ffcccc" height="15px" width="15px" onclick="bbcode('[color=#ffcccc]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#336666" height="15px" width="15px" onclick="bbcode('[color=#336666]', '[/color]'); return changeVisibility('mycolor', this)"></td>
	<td style="background-color:#ff9999" height="15px" width="15px" onclick="bbcode('[color=#ff9999]', '[/color]'); return changeVisibility('mycolor', this)"></td>
</tr>
	</table>
	</div>

0

7

Замена мужской ,женский пол

Код:
<script type="text/javascript">
var sex=document.getElementById('pun-main').getElementsByTagName("li")
var sx=0
for (sx=0; sx<=(sex.length-1); sx++)
{if (sex[sx].className=="pa-sex")
{if (sex[sx].innerHTML.indexOf("Мужской")!=-1)
{sex[sx].innerHTML="Пол: "+"<img src='мужская картинка' />"}
else if (sex[sx].innerHTML.indexOf("Женский")!=-1)
{sex[sx].innerHTML="Пол: "+"<img src='женская картинка' />"}
}}
</script>

0

8

Замена слова Зарегестрирован под аватаром

Код:
<script type="text/javascript">
if (document.URL.indexOf("viewtopic.php") != -1){
li=document.getElementsByTagName("li")
f=0
while(li[++f]){
s=li[f].innerHTML
if((p=s.indexOf("Зарегистрирован")) != -1) li[f].innerHTML=s.substring(0,p)+"СВОЁ СЛОВО"+s.substring(p+15)
}
}
</script>

Замена слова откуда

Код:
<script type="text/javascript">
if (document.URL.indexOf("viewtopic.php") != -1){
li=document.getElementsByTagName("li")
f=0
while(li[++f]){
s=li[f].innerHTML
if((p=s.indexOf("Откуда")) != -1) li[f].innerHTML=s.substring(0,p)+"СВОЁ СЛОВО"+s.substring(p+6)
}
}
</script>

Замена слова сообщения

Код:
<script type="text/javascript">
if (document.URL.indexOf("viewtopic.php") != -1){
li=document.getElementsByTagName("li")
f=0
while(li[++f]){
s=li[f].innerHTML
if((p=s.indexOf("Сообщений")) != -1) li[f].innerHTML=s.substring(0,p)+"СВОЁ СЛОВО"+s.substring(p+9)
}
}
</script>

0

9

Есть нет новые сообщения

Код:
<style>Div.icon {
background-image: url(Картинка Off);
background-repeat: no-repeat; }
Tr.inew Div.icon {
background-image: url(Картинка ON);
background-repeat: no-repeat; }</style>

Еще один вид

Код:
<style type="text/css"> Div.icon {
background-image : url(ссылка на вашу картинку для "нет новых сообщений");
background-repeat: no-repeat;
}
</style>

<style type="text/css">TR.inew Div.icon {
background-image : url(ссылка на вашу картинку для "есть новые сообщения");
background-repeat: no-repeat;
}
</style>

0

10

Коллекция аватаров

Код:
<script type="text/javascript">
var arr=document.getElementsByTagName("p")
i=0
while(arr[i] ){
if(arr[i].className=="inputfield"){
name=arr[i].innerHTML
name=name.substring(0)
arr[i].innerHTML="<a target=\"_blank\" href=\"http://www.avata.ru\">Коллекция аватаров</a><br><br>"+name+""
}
i++
}
</script>

0

11

Отражение аватара

Код:
В Верх 
type="text/javascript">
document.getElementsByClassName = function(className) {
	var children = document.getElementsByTagName('*') || document.all;
	var elements = new Array();
  
	for (var i = 0; i < children.length; i++) {
var child = children[i];
var classNames = child.className.split(' ');
for (var j = 0; j < classNames.length; j++) {
	if (classNames[j] == className) {
elements.push(child);
break;
	}
}
	}
	return elements;
}

var Reflection = {
	defaultHeight : 0.5,
	defaultOpacity: 0.5,
	
	add: function(image, options) {
Reflection.remove(image);

doptions = { "height" : Reflection.defaultHeight, "opacity" : Reflection.defaultOpacity }
if (options) {
	for (var i in doptions) {
if (!options[i]) {
	options[i] = doptions[i];
}
	}
} else {
	options = doptions;
}
	
try {
	var d = document.createElement('div');
	var p = image;
	
	var classes = p.className.split(' ');
	var newClasses = '';
	for (j=0;j<classes.length;j++) {
if (classes[j] != "reflect") {
	if (newClasses) {
newClasses += ' '
	}
	
	newClasses += classes[j];
}
	}

	var reflectionHeight = Math.floor(p.height*options['height']);
	var divHeight = Math.floor(p.height*(1+options['height']));
	
	var reflectionWidth = p.width;
	
	if (document.all && !window.opera) {
/* Fix hyperlinks */
                if(p.parentElement.tagName == 'A') {
	                var d = document.createElement('a');
	                d.href = p.parentElement.href;
                }  
                    
/* Copy original image's classes & styles to div */
d.className = newClasses;
p.className = 'reflected';

d.style.cssText = p.style.cssText;
p.style.cssText = 'vertical-align: bottom';
	
var reflection = document.createElement('img');
reflection.src = p.src;
reflection.style.width = reflectionWidth+'px';

reflection.style.marginBottom = "-"+(p.height-reflectionHeight)+'px';
reflection.style.filter = 'flipv progid:DXImageTransform.Microsoft.Alpha(opacity='+(options['opacity']*100)+', style=1, finishOpacity=0, startx=0, starty=0, finishx=0, finishy='+(options['height']*100)+')';

d.style.width = reflectionWidth+'px';
d.style.height = divHeight+'px';
p.parentNode.replaceChild(d, p);

d.appendChild(p);
d.appendChild(reflection);
	} else {
var canvas = document.createElement('canvas');
if (canvas.getContext) {
	/* Copy original image's classes & styles to div */
	d.className = newClasses;
	p.className = 'reflected';
	
	d.style.cssText = p.style.cssText;
	p.style.cssText = 'vertical-align: bottom';
	
	var context = canvas.getContext("2d");

	canvas.style.height = reflectionHeight+'px';
	canvas.style.width = reflectionWidth+'px';
	canvas.height = reflectionHeight;
	canvas.width = reflectionWidth;
	
	d.style.width = reflectionWidth+'px';
	d.style.height = divHeight+'px';
	p.parentNode.replaceChild(d, p);
	
	d.appendChild(p);
	d.appendChild(canvas);
	
	context.save();
	
	context.translate(0,image.height-1);
	context.scale(1,-1);
	
	context.drawImage(image, 0, 0, reflectionWidth, image.height);
	
	context.restore();
	
	context.globalCompositeOperation = "destination-out";
	var gradient = context.createLinearGradient(0, 0, 0, reflectionHeight);
	
	gradient.addColorStop(1, "rgba(255, 255, 255, 1.0)");
	gradient.addColorStop(0, "rgba(255, 255, 255, "+(1-options['opacity'])+")");

	context.fillStyle = gradient;
	if (navigator.appVersion.indexOf('WebKit') != -1) {
context.fill();
	} else {
context.fillRect(0, 0, reflectionWidth, reflectionHeight*2);
	}
}
	}
} catch (e) {
	    }
	},
	
	remove : function(image) {
if (image.className == "reflected") {
	image.className = image.parentNode.className;
	image.parentNode.parentNode.replaceChild(image, image.parentNode);
}
	}
}

function addReflections() {
	var rimages = document.getElementsByClassName('reflect');
	for (i=0;i<rimages.length;i++) {
var rheight = null;
var ropacity = null;

var classes = rimages[i].className.split(' ');
for (j=0;j<classes.length;j++) {
	if (classes[j].indexOf("rheight") == 0) {
var rheight = classes[j].substring(7)/100;
	} else if (classes[j].indexOf("ropacity") == 0) {
var ropacity = classes[j].substring(8)/100;
	}
}

Reflection.add(rimages[i], { height: rheight, opacity : ropacity});
	}
}

var previousOnload = window.onload;
window.onload = function () { if(previousOnload) previousOnload(); addReflections(); }
Код:
В низ
<script type="text/javascript">
var arr=document.getElementsByTagName("li")
i=0
while(arr[i] ){
if(arr[i].className=="pa-avatar item2"){
name=arr[i].innerHTML
name=name.substring(4)
arr[i].innerHTML="<img class=reflect "+name+" "
}
i++
}
</script>

0


Вы здесь » форум фотошопа и поддержки пользователей » Скрипты » Скрипты сделанные для вас