- 1
- 2
- 3
- 4
- 5
- 6
function nyak_nyak(el) {
if (confirm("Вы уверены в своих действиях?")) {
document.location = el.href;
}
return false;
}
Нашли или выдавили из себя код, который нельзя назвать нормальным, на который без улыбки не взглянешь? Не торопитесь его удалять или рефакторить, — запостите его на говнокод.ру, посмеёмся вместе!
+147
function nyak_nyak(el) {
if (confirm("Вы уверены в своих действиях?")) {
document.location = el.href;
}
return false;
}
+147
var yagooduser = sustr('Мой',1);
Чел прислал в асю и удивляется, почему не работает
+78
if (searchFB.getOrderNo()!=null && searchFB.getOrderNo().length()==6){
int drawingStatus = searchFB.getDrawingStatus();
int criticalStatus = searchFB.getCriticalStatus();
int blockingStatus = searchFB.getBlockingStatus();
int suspensionStatus = searchFB.getSuspensionStatus();
searchFB.setDrawingStatus(drawingStatus);
searchFB.setCriticalStatus(criticalStatus);
searchFB.setBlockingStatus(blockingStatus);
searchFB.setSuspensionStatus(suspensionStatus);
}
И это мне поддерживать...
+163
// Checks if the passed input's value is nothing.
function isEmptyText(theField)
{
// Copy the value so changes can be made..
var theValue = theField.value;
// Strip whitespace off the left side.
while (theValue.length > 0 && (theValue.charAt(0) == ' ' || theValue.charAt(0) == '\t'))
theValue = theValue.substring(1, theValue.length);
// Strip whitespace off the right side.
while (theValue.length > 0 && (theValue.charAt(theValue.length - 1) == ' ' || theValue.charAt(theValue.length - 1) == '\t'))
theValue = theValue.substring(0, theValue.length - 1);
if (theValue == '')
return true;
else
return false;
}
...
function in_array(variable, theArray)
{
for (var i in theArray)
if (theArray == variable)
return true;
return false;
}
+160
function message($mess,$font,$border,$backgr){
$bsize = '2';
if ($font == "" || $border == "" || $backgr == "" ){
$font = '#ffffff';
$border = 'none';
$backgr = 'none';
$backgr = 'none';
$bsize = '0';
}
//exit();
echo $top_pan.'<br>
<div align="center">
<div align="center"
style="width: 60%; border-width: '.$bsize.'; border-style: solid;color: '.$font.'; border-color: '.$border.'; background-color: '.$backgr.';">'
.$mess.'</div></div>'.$bottom_pan;
}
Оттуда же.
А вообще там все можно выкладывать.
+127
<table>
<tr valign="bottom">
<td<? if($page=='home') {?> id="tec"<? }?>>
<dl>
<dt>01.</dt>
<dd><? if($page!='home') {?><a href="index.php">О компании</a><? } else{?>О компании<? }?></dd>
</dl>
</td>
<td<? if($page=='products') {?> id="tec"<? }?>>
<dl>
<dt>02.</dt>
<dd><? if($page!='products') {?><a href="index.php?page=products">Продукция</a><? } else{?>Продукция<? }?></dd>
</dl>
</td>
<td<? if($page=='contacts') {?> id="tec"<? }?>>
<dl>
<dt>03.</dt>
<dd><? if($page!='contacts') {?><a href="index.php?page=contacts">Контакты</a><? } else{?>Контакты<? }?></dd>
</dl>
</td>
<td<? if($page=='news') {?> id="tec"<? }?>>
<dl>
<dt>04.</dt>
<dd><? if($page!='news') {?><a href="index.php?page=news">Новости</a><? } else{?>Новости<? }?></dd>
</dl>
</td>
</tr>
</table>
Меню
+167
<a title="Главная" href="http://<?php echo $_SERVER['HTTP_HOST'].str_replace('\\', '', dirname($_SERVER['PHP_SELF'])); ?>">Главная</a>
нашел в одном проекте, я бы и не смог до такого додуматься
+158
{|if $message=="ok"|}
<div style="text-align: center; padding:10px; margin:10px; color: white; font-weight: bold; background-color: green;">Your message has successfully been added.</div>
{|/if|}
{|if $message=="error"|}
<div style="text-align: center; padding:10px; margin:10px; color: white; font-weight: bold; background-color: red;">Mistake. You filled out the wrong form.</div>
{|/if|}
Красивое использование CSS.
+147
GOVNOREGER© для govnokod.ru
http://slil.ru/31180342
+165
return $result_rows;
mysql_close($external_db);