1. Список говнокодов пользователя TBoolean

    Всего: 20

  2. PHP / Говнокод #11609

    +46

    1. 1
    2. 2
    3. 3
    <?php 
    echo implode(", ", array_map(create_function('$tag', 'return \'<a href="?tag=\' . hs($tag) . \'">\' . hs($tag) . \'</a>\';'), $post['tags'])); 
    ?>

    Нашел в дебрях своей древней CMS. Как говорится, экономика должна быть экономичной, а конь коническим.

    TBoolean, 19 Августа 2012

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

    +71

    1. 01
    2. 02
    3. 03
    4. 04
    5. 05
    6. 06
    7. 07
    8. 08
    9. 09
    10. 10
    11. 11
    $template_archive_footer = stripslashes(get_option('poll_template_pollarchivefooter'));
    		$template_archive_footer = str_replace("%POLL_START_DATE%", $poll_start_date, $template_archive_footer);
    		$template_archive_footer = str_replace("%POLL_END_DATE%", $poll_end_date, $template_archive_footer);
    		$template_archive_footer = str_replace("%POLL_TOTALVOTES%", number_format_i18n($polls_question['totalvotes']), $template_archive_footer);
    		$template_archive_footer = str_replace("%POLL_TOTALVOTERS%", number_format_i18n($polls_question['totalvoters']), $template_archive_footer);
    		$template_archive_footer = str_replace("%POLL_MOST_ANSWER%", $poll_most_answer, $template_archive_footer);
    		$template_archive_footer = str_replace("%POLL_MOST_VOTES%", number_format_i18n($poll_most_votes), $template_archive_footer);
    		$template_archive_footer = str_replace("%POLL_MOST_PERCENTAGE%", $poll_most_percentage, $template_archive_footer);
    		$template_archive_footer = str_replace("%POLL_LEAST_ANSWER%", $poll_least_answer, $template_archive_footer);
    		$template_archive_footer = str_replace("%POLL_LEAST_VOTES%", number_format_i18n($poll_least_votes), $template_archive_footer);
    		$template_archive_footer = str_replace("%POLL_LEAST_PERCENTAGE%", $poll_least_percentage, $template_archive_footer);

    wp-polls. пиздец.

    TBoolean, 15 Мая 2012

    Комментарии (8)
  4. PHP / Говнокод #9630

    +160

    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
    $replace = array(
                chr(0) => '',
                chr(1) => '',
                chr(2) => '',
                chr(3) => '',
                chr(4) => '',
                chr(5) => '',
                chr(6) => '',
                chr(7) => '',
                chr(8) => '',
                chr(9) => '',
                chr(11) => '',
                chr(12) => '',
                chr(13) => '',
                chr(14) => '',
                chr(15) => '',
                chr(16) => '',
                chr(17) => '',
                chr(18) => '',
                chr(19) => '',
                chr(20) => '',
                chr(21) => '',
                chr(22) => '',
                chr(23) => '',
                chr(24) => '',
                chr(25) => '',
                chr(26) => '',
                chr(27) => '',
                chr(28) => '',
                chr(29) => '',
                chr(30) => '',
                chr(31) => ''
            );

    А я так надеялся.

    TBoolean, 08 Марта 2012

    Комментарии (5)
  5. PHP / Говнокод #9629

    +169

    1. 1
    2. 2
    $str = str_replace("|", "I", $str);
    $str = str_replace("||", "I", $str);

    нет, ну, а мало ли.

    TBoolean, 08 Марта 2012

    Комментарии (2)
  6. PHP / Говнокод #9559

    +152

    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
    35. 35
    36. 36
    $login = trim($user_f[2]);
      $email = trim($user_f[3]);
      $passw = trim($user_f[4]);
      $reg_date = trim($user_f[5]);
      $last_visit = trim($user_f[6]);
      $name = trim($user_f[7]);
      $site = trim($user_f[8]);
      $icq = trim($user_f[9]);
      $pol = trim($user_f[10]);
      $otkuda = trim($user_f[11]);
      $modelphone = trim($user_f[12]);
      $operator = trim($user_f[13]);
      $show_mail = trim($user_f[14]);
      $reputacia = trim($user_f[15]);
      $status = trim($user_f[16]);
      $data_rozhd = trim($user_f[17]);
      $bantime = trim($user_f[18]);
      $bantxt = trim($user_f[19]);
      $banwho = trim($user_f[20]);
      $mes_guest = trim($user_f[21]);
      $mes_forum = trim($user_f[22]);
      $mes_komm = trim($user_f[23]);
      $new_ls = trim($user_f[24]);
      $activ_account = trim($user_f[25]);
      $izm_repu = trim($user_f[26]);
      $plusov = trim($user_f[27]);
      $minusov = trim($user_f[28]);
      $o_sebe = trim($user_f[29]);
      $rating = trim($user_f[30]);
      $time_in_site = trim($user_f[31]);
      $vhodov = trim($user_f[32]);
      $all_temes = trim($user_f[33]);
      $statey = trim($user_f[34]);
      $mes_chat = trim($user_f[35]);
      $status_name = trim($user_f[36]);
      $nick_name = trim($user_f[37]);

    Еще теплое...

    TBoolean, 28 Февраля 2012

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

    +164

    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
    35. 35
    36. 36
    37. 37
    38. 38
    39. 39
    40. 40
    41. 41
    42. 42
    43. 43
    44. 44
    45. 45
    46. 46
    47. 47
    48. 48
    49. 49
    50. 50
    51. 51
    /////////////Название ссылок (меню и тд) ////////////////
    $file=str_replace('{text_about}',$sph_messages["text_about"],$file); // О нас
    $file=str_replace('{text_main}',$sph_messages["text_main"],$file); //
    $file=str_replace('{text_news}',$sph_messages["text_news"],$file);
    $file=str_replace('{text_web}',$sph_messages["text_web"],$file);
    $file=str_replace('{text_pog_gorod}',$sph_messages["text_pog_gorod"],$file);
    $file=str_replace('{text_catigor}',$sph_messages["text_catigor"],$file);
    $file=str_replace('{text_logo}',$sph_messages["text_logo"],$file);
    $file=str_replace('{text_searc}',$sph_messages["text_searc"],$file);
    $file=str_replace('{text_img}',$sph_messages["text_img"],$file);
    $file=str_replace('{text_add}',$sph_messages["text_add"],$file);
    $file=str_replace('{text_help}',$sph_messages["text_help"],$file);
    $file=str_replace('{text_search_all}',$sph_messages["text_search_all"],$file);
    $file=str_replace('{text_feedback}',$sph_messages["text_feedback"],$file);
    $file=str_replace('{text_send}',$sph_messages["text_send"],$file);
    $file=str_replace('{text_start}',$sph_messages["text_start"],$file);
    $file=str_replace('{text_reg_mail}',$sph_messages["text_reg_mail"],$file);
    $file=str_replace('{text_kurs}',$sph_messages["text_kurs"],$file);
    $file=str_replace('{text_mail}',$sph_messages["text_mail"],$file);
    $file=str_replace('{text_pass}',$sph_messages["text_pass"],$file);
    $file=str_replace('{text_lang}',$sph_messages["text_lang"],$file);
    $file=str_replace('{text_zapomnit}',$sph_messages["text_zapomnit"],$file);
    $file=str_replace('{text_vhod}',$sph_messages["text_vhod"],$file);
    $file=str_replace('{text_pogoda}',$sph_messages["text_pogoda"],$file);
    $file=str_replace('{text_friend}',$sph_messages["text_friend"],$file);
    $file=str_replace('{text_music}',$sph_messages["text_music"],$file);
    $file=str_replace('{text_foto}',$sph_messages["text_foto"],$file);
    $file=str_replace('{text_video}',$sph_messages["text_video"],$file);
    $file=str_replace('{text_search_ras}',$sph_messages["text_search_ras"],$file);
    $file=str_replace('{text_add_code}',$sph_messages["text_add_code"],$file);
    $file=str_replace('{text_add_des}',$sph_messages["text_add_des"],$file);
    $file=str_replace('{text_add_url}',$sph_messages["text_add_url"],$file);
    $file=str_replace('{text_add_name}',$sph_messages["text_add_name"],$file);
    $file=str_replace('{text_add_ost}',$sph_messages["text_add_ost"],$file);
    $file=str_replace('{text_add_znak}',$sph_messages["text_add_znak"],$file);
    //////////КАТЕГОРИИ////////
    $file=str_replace('{cat}',$sph_messages["cat"],$file);
    $file=str_replace('{cat_all}',$sph_messages["cat_all"],$file);
    $file=str_replace('{cat_avto}',$sph_messages["cat_avto"],$file);
    $file=str_replace('{cat_web}',$sph_messages["cat_web"],$file);
    $file=str_replace('{cat_znakom}',$sph_messages["cat_znakom"],$file);
    $file=str_replace('{cat_games}',$sph_messages["cat_games"],$file);
    $file=str_replace('{cat_komp}',$sph_messages["cat_komp"],$file);
    $file=str_replace('{cat_story}',$sph_messages["cat_story"],$file);
    $file=str_replace('{cat_soft}',$sph_messages["cat_soft"],$file);
    $file=str_replace('{cat_music}',$sph_messages["cat_music"],$file);
    $file=str_replace('{cat_sport}',$sph_messages["cat_sport"],$file);
    $file=str_replace('{cat_dom}',$sph_messages["cat_dom"],$file);
    $file=str_replace('{cat_business}',$sph_messages["cat_business"],$file);
    $file=str_replace('{cat_zarabotok}',$sph_messages["cat_zarabotok"],$file);
    и так еще over9000 cтрок

    мои глаза...

    TBoolean, 10 Февраля 2012

    Комментарии (13)
  8. PHP / Говнокод #9378

    +171

    1. 1
    2. 2
    3. 3
    4. 4
    //получаем ip-аддрес
    ob_start();
    $ip=$_SERVER['REMOTE_ADDR']; echo "$ip ";
    $ipusers = ob_get_clean();

    http://alltheragefaces.com/img/faces/large/misc-jackie-chan-l.png

    TBoolean, 10 Февраля 2012

    Комментарии (31)
  9. SQL / Говнокод #9102

    −129

    1. 1
    SELECT COUNT(*)  FROM passwords WHERE program=program AND website=website AND login=login AND password=password

    Okay :(

    TBoolean, 12 Января 2012

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

    +166

    1. 1
    2. 2
    3. 3
    4. 4
    5. 5
    6. 6
    7. 7
    8. 8
    9. 9
    <?php
    @fwrite($fp, "<?php
    \$config['dbhost'] = \"".str_replace("\"","\\\\\"",stripslashes(trim($_POST['dbhost'])))."\";
    \$config['dbuser'] = \"".str_replace("\"","\\\\\"",stripslashes(trim($_POST['dbuser'])))."\";
    \$config['dbpass'] = \"".str_replace("\"","\\\\\"",stripslashes(trim($_POST['dbpass'])))."\";
    \$config['dbname'] = \"".str_replace("\"","\\\\\"",stripslashes(trim($_POST['dbname'])))."\";
    \$config['dbpref'] = \"".str_replace("\"","\\\\\"",stripslashes(trim($_POST['dbprefix'])))."\";
    ?>");
    ?>

    avecms нах.

    TBoolean, 19 Декабря 2011

    Комментарии (4)
  11. PHP / Говнокод #8844

    +168

    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
    $mes_for_mail=str_replace("[code]","",$mes_for_mail);
    $mes_for_mail=str_replace("[/code]","",$mes_for_mail);
    
    $mes_for_mail=str_replace("[b]","",$mes_for_mail);
    $mes_for_mail=str_replace("[/b]","",$mes_for_mail);
    
    $mes_for_mail=str_replace("[i]","",$mes_for_mail);
    $mes_for_mail=str_replace("[/i]","",$mes_for_mail);
    
    $mes_for_mail=str_replace("[u]","",$mes_for_mail);
    $mes_for_mail=str_replace("[/u]","",$mes_for_mail);
    
    $mes_for_mail=str_replace("[s]","",$mes_for_mail);
    $mes_for_mail=str_replace("[/s]","",$mes_for_mail);
    
    $mes_for_mail=str_replace("[tt]","",$mes_for_mail);
    $mes_for_mail=str_replace("[/tt]","",$mes_for_mail);
    
    $mes_for_mail=str_replace("[sup]","",$mes_for_mail);
    $mes_for_mail=str_replace("[/sup]","",$mes_for_mail);
    
    $mes_for_mail=str_replace("[sub]","",$mes_for_mail);
    $mes_for_mail=str_replace("[/sub]","",$mes_for_mail);
    
    $mes_for_mail=str_replace("[code]","",$mes_for_mail);
    $mes_for_mail=str_replace("[/code]","",$mes_for_mail);
    
    $mes_for_mail=str_replace("[font color=FF0000]","",$mes_for_mail);
    $mes_for_mail=str_replace("[font color=0000FF]","",$mes_for_mail);
    $mes_for_mail=str_replace("[font color=008080]","",$mes_for_mail);
    $mes_for_mail=str_replace("[/font]","",$mes_for_mail);

    я плакол)

    TBoolean, 15 Декабря 2011

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