1. PHP / Говнокод #6139

    +167

    1. 1
    Перейти на страницу <span onmouseover="this.className='menu_over'" onmouseout="this.className='menu'" class="menu" onClick="window.location='<?echo $arItem["DETAIL_PAGE_URL"]?>'">--></span>

    тег "a" видимо был незнаком.

    Fisher, 30 Марта 2011

    Комментарии (20)
  2. Perl / Говнокод #6138

    −124

    1. 1
    grep {$a_b_props = ($a_b_props && $a_b_props.".").(($block < 1)? &dupl($tempProps{$_}) : $tempProps{$_}) if /^[ab]_/} sort keys %tempProps;

    туда же...

    abadonna, 30 Марта 2011

    Комментарии (0)
  3. ActionScript / Говнокод #6137

    −125

    1. 1
    2. 2
    3. 3
    4. 4
    5. 5
    6. 6
    <a href="javascript:void(0);"
    onclick="$('menu_main_dropdown2').style.display = ( 
    $('menu_main_dropdown2').style.display=='none' ? 'inline' : 'none' );
    $('menu_main_dropdown').style.display = 'none';this.blur(); return false;"
    class="top_menu_item">
    Account</a>

    Скрытие /показ блока меню

    Vasiliy, 30 Марта 2011

    Комментарии (6)
  4. Perl / Говнокод #6136

    −124

    1. 1
    @AoH_SUBSinFILE = map {&parseSubmodel($_, $block)} $g_file_content =~ m/\s*?(inst .+?vars  \\.+?[^\\])\n/gs;

    Говнокод4obfuscation :)

    abadonna, 30 Марта 2011

    Комментарии (2)
  5. Perl / Говнокод #6135

    −124

    1. 1
    2. 2
    3. 3
    4. 4
    5. 5
    6. 6
    7. 7
    8. 8
    sub WidthOf()
    {
      my %WIDTHES =('90','195','118','165', ...  over9000   ...'43','255');
      my $TextWidth;
    
      map {$TextWidth += $WIDTHES{ord $_} || 200} split //,@_[0];
      return $TextWidth;
    }

    abadonna, 30 Марта 2011

    Комментарии (1)
  6. Perl / Говнокод #6134

    −116

    1. 1
    2. 2
    3. 3
    4. 4
    5. 5
    sub chooseType()
    {
    	grep {return $_ if @_[0]  =~ /$_/} (keys %TYPES);
    	return "";
    }

    люблю map и grep :)

    abadonna, 30 Марта 2011

    Комментарии (0)
  7. PHP / Говнокод #6133

    +161

    1. 01
    2. 02
    3. 03
    4. 04
    5. 05
    6. 06
    7. 07
    8. 08
    9. 09
    10. 10
    11. 11
    12. 12
    13. 13
    14. 14
    15. 15
    16. 16
    17. 17
    18. 18
    19. 19
    20. 20
    21. 21
    22. 22
    23. 23
    24. 24
    25. 25
    26. 26
    27. 27
    28. 28
    29. 29
    30. 30
    31. 31
    32. 32
    33. 33
    34. 34
    function get_section(){
    		if(ifGet('section')){
    			if($this->get_file('./applications/app.'.$this->section.'.php')){
    				switch (Get('section')){
    					case ''.$this->section.'':
    						$m = new $this->section();
    					break;
    				}
    			} else {
    				
    				switch (Get('section'))
    				{
    					default:
    						include_once('./applications/sys.pages.php');
    						$m = new pages();
    					break;
    				}
    			}
    		}else{
    			switch (Get('section'))
    			{
    				default:
    					include_once('./applications/sys.home.php');
    					$m = new home();
    				break;
    			}
    		}
    		
    		if(isset($m) && is_object($m)) {
    			$this->output = $m->output;
    			$this->title = $m->title;
    			$this->crumbs = $m->crumbs;
    		}
    	}

    я сам в шоке как такое мог написать...

    Impossible, 30 Марта 2011

    Комментарии (6)
  8. JavaScript / Говнокод #6132

    +164

    1. 1
    $('#menu_block').each…

    Дальше не смотрел.

    stuffort, 30 Марта 2011

    Комментарии (7)
  9. JavaScript / Говнокод #6131

    +158

    1. 01
    2. 02
    3. 03
    4. 04
    5. 05
    6. 06
    7. 07
    8. 08
    9. 09
    10. 10
    11. 11
    12. 12
    13. 13
    14. 14
    15. 15
    16. 16
    17. 17
    18. 18
    19. 19
    20. 20
    if (location.href.split('/')[4] == '14-0-0' | location.href.split('/')[4] == '14') {
    	$('#u1').attr({
    		class: 'tabv'
    	})
    }
    else if (location.href.split('/')[4] == '14-0-1') {
    	$('#u2').attr({
    		class: 'tabv'
    	})
    }
    else if (location.href.split('/')[4] == '14-0-0-1' || $('#PMtoUser').val()) {
    	$('#bar').hide();
    	$('#mess').css({
    		backgroundColor: '#fafafa'
    	});;
    	$('#mess').html('<div style="padding-top:30px;padding-bottom:30px;"><div id="valError2"></div><div id="valSuccess2"></div><div id="bmess"><div id="bmess2"><table width="100%"><tr><td align="left" valign="top"><div class="avaogets" style="margin-top:2px;"><img src='+noavatar+'></div></td><td width="100%" style="padding-left:15px;" align="left" valign="top"><div id="hname">Получатель</div><input type="text" id="nameSend"><div style="padding-top:9px;" id="hname">Тема</div><input type="text" id="tSend"></td></tr></table><textarea style="margin-top:10px;" id="message2"></textarea><div id="idCap" style="overflow:hidden;margin-top:3px;margin-left:1px;"><div style="float:left;" id="abbbb"></div><div style="float:right;"><input id="capval" maxlength="4" type="text"></div></div><div id="new_b" class="Mbd" style="margin-top:6px;" onclick="$(\'#sbm\').click()"><div id="new_b2">Отправить</div></div><div class="spanload" style="display:inline-block;padding-left:5px;"></div></div> </div></div>');
    	$('#u4').attr({
    		class: 'tabv'
    	})
    }

    Это и многое другое на http://uweb.su/js/new_message.js!
    Смотрите в браузерах вашего компьютера!

    UnderShot, 30 Марта 2011

    Комментарии (8)
  10. C++ / Говнокод #6130

    +159

    1. 01
    2. 02
    3. 03
    4. 04
    5. 05
    6. 06
    7. 07
    8. 08
    9. 09
    10. 10
    11. 11
    12. 12
    13. 13
    14. 14
    15. 15
    16. 16
    17. 17
    18. 18
    19. 19
    20. 20
    21. 21
    22. 22
    23. 23
    24. 24
    25. 25
    26. 26
    27. 27
    28. 28
    m_hSemaphore		= CreateSemaphore( NULL, 1, 1, NULL );
    ....
    
    void CTestGUIDlg::OnBnClickedButtonStartStream()
    {
    	WaitForSingleObject(m_hSemaphore, INFINITE);
    	if(m_ThreadHandle)
    	{
    		AfxMessageBox("Stop running stream!", MB_ICONEXCLAMATION);
    		return;
    	};
    
    	m_ThreadHandle	= NULL;
    	m_StreamType	= 1;
    	m_ThreadHandle =					(HANDLE)_beginthreadex(NULL,
    										0,
    										streamProcedure,
    										static_cast<LPVOID>( this ),
    										0,
    										NULL);	
    
    	if(!m_ThreadHandle) 
    	{
    		m_StreamType	= 0;
    	}
    	UpdateButtons();
    	ReleaseSemaphore(m_hSemaphore, 1, NULL);
    }

    классика жанра

    Aleskey, 30 Марта 2011

    Комментарии (6)