Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

 
Reply to this topicStart new topic
> [php] problem przy rejestracji, użytkownik nie może się zarejestrować
Xander
post
Post #1





Grupa: Zarejestrowani
Postów: 7
Pomógł: 0
Dołączył: 6.02.2007
Skąd: Gdańsk

Ostrzeżenie: (0%)
-----


Witam mam taki błąd:
Cytat
SQL Error : 1136 Column count doesn't match value count at row 1

INSERT INTO phpbb_users (user_id, username, user_regdate, user_password, user_email, user_icq, user_website, user_occ, user_from, user_interests, user_computer_name, user_system_enclosure, user_system_motherboard, user_processor_brand, user_processor_desc, user_memory_amt, user_memory_details, user_vid_brand, user_vid_desc, user_storage_details, user_audio_details, user_system_cooling, user_system_monitor, user_system_os, user_favorite_game, user_threedmark, user_futuremark, user_cpu_dhry, user_cpu_whet, user_cpu_integer, user_cpu_floating, user_ram_integer, user_ram_floating, user_drive_idx, user_show_specs, user_sig, user_sig_bbcode_uid, user_avatar, user_avatar_type, user_viewemail, user_aim, user_yim, user_msnm, user_attachsig, user_allowsmile, user_allowhtml, user_allowbbcode, user_allow_viewonline, user_notify, user_notify_pm, user_popup_pm, user_timezone, user_dateformat, user_lang, user_style, user_gender, user_level, user_allow_pm, user_birthday, user_next_birthday_greeting, user_active, user_actkey) VALUES (3, 'Wilczek', 1171135945, '4d6c4d6b5b6c7fd2c43727ce32a56f4e', '******@interia.pl', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', 0, '', '', '', 0, 0, '', '', '', 1, 1, 1, 1, 1, 0, 1, 1, 1, 'D M d, Y g:i a', 'polish', 1, '1', '5648', '2007', '12' , '11', '26', '35', 0, 11, '')

Line : 809
File : usercp_register.php


A oto linia 809 z pliku usercp_register.php. Nie mam pojęcia, gdzie tkwi błąd.

  1. <?php
  2. $sql = "INSERT INTO " . USERS_TABLE . " (user_id, username, user_regdate, user_password, user_email,
  3.  user_icq, user_website, user_occ, user_from, user_interests, user_computer_name
    , user_system_enclosure, 
  4. user_system_motherboard, user_processor_brand, user_processor_desc, user_memory_
    amt, user_memory_details, 
  5. user_vid_brand, user_vid_desc, user_storage_details, user_audio_details, user_sy
    stem_cooling, user_system_monitor, 
  6. user_system_os, user_favorite_game, user_threedmark, user_futuremark, user_cpu_d
    hry, user_cpu_whet, user_cpu_integer, 
  7. user_cpu_floating, user_ram_integer, user_ram_floating, user_drive_idx, user_sho
    w_specs, user_sig, user_sig_bbcode_uid, 
  8. user_avatar, user_avatar_type, user_viewemail, user_aim, user_yim, user_msnm, us
    er_attachsig, user_allowsmile, 
  9. user_allowhtml, user_allowbbcode, user_allow_viewonline, user_notify, user_notif
    y_pm, user_popup_pm, user_timezone, 
  10. user_dateformat, user_lang, user_style, user_gender, user_level, user_allow_pm, 
    user_birthday, user_next_birthday_greeting,
  11.  user_active, user_actkey)
  12. VALUES ($user_id, '" . str_replace("'", "''", $username) . "', " . time() . ", '" . 
  13. str_replace("'", "''", $new_password) . "', '" . str_replace("'", "''", $email) . "', '" . 
  14. str_replace("'", "''", $icq) . "', '" . str_replace("'", "''", $website) . "', '" . 
  15. str_replace("'", "''", $occupation) . "', '" . str_replace("'", "''", $location) . "', '" . 
  16. str_replace("'", "''", $interests) . "', '" . str_replace("'", "''", $computer_name) . "', '" . 
  17. str_replace("'", "''", $system_enclosure) . "', '" . str_replace("'", "''", $system_motherboard)
  18.  . "', '" . str_replace("'", "''", $processor_brand) . "', '" . str_replace("'", "''", $processor_desc)
  19.  . "', '" . str_replace("'", "''", $memory_amt) . "', '" . str_replace("'", "''", $memory_details) . "', '" . 
  20. str_replace("'", "''", $vid_brand) . "', '" . str_replace("'", "''", $vid_desc) . "', '" . 
  21. str_replace("'", "''", $storage_details) . "', '" . str_replace("'", "''", $audio_details) . "', '" . 
  22. str_replace("'", "''", $system_cooling) . "', '" . str_replace("'", "''", $system_os) . "', '" . 
  23. str_replace("'", "''", $system_monitor) . "', '" . str_replace("'", "''", $favorite_game) . "', '" . 
  24. str_replace("'", "''", $threedmark) . "', '" . str_replace("'", "''", $futuremark) . "', '" . 
  25. str_replace("'", "''", $cpu_dhry) . "', '" . str_replace("'", "''", $cpu_whet) . "', '" . 
  26. str_replace("'", "''", $cpu_integer) . "', '" . str_replace("'", "''", $cpu_floating) . "', '" . 
  27. str_replace("'", "''", $ram_integer) . "', '" . str_replace("'", "''", $ram_floating) . "', '" . 
  28. str_replace("'", "''", $drive_idx) . "', $user_show_specs, '" . str_replace("'", "''", $signature)
  29.  . "', '$signature_bbcode_uid', $avatar_sql, $viewemail, '" . str_replace("'", "''", str_replace(' ', '+', $aim))
  30.  . "', '" . str_replace("'", "''", $yim) . "', '" . str_replace("'", "''", $msn) . "', $attachsig, $allowsmilies,
  31.  $allowhtml, $allowbbcode, $allowviewonline, $notifyreply, $notifypm, $popup_pm,
     $user_timezone, '"
     . 
  32. str_replace("'", "''", $user_dateformat) . "', '" . str_replace("'", "''", $user_lang) . "', $user_style,
  33.  '$gender', '$birthday', '$next_birthday_greeting', '$element' , '$klass', '$race', '$alignment', 0, 1";
  34. ?>


Ten post edytował Xander 10.02.2007, 21:47:33
Go to the top of the page
+Quote Post
Cienki1980
post
Post #2





Grupa: Przyjaciele php.pl
Postów: 1 590
Pomógł: 40
Dołączył: 11.01.2007
Skąd: Centrum

Ostrzeżenie: (0%)
-----


Nie zgadza się liczba kolumn pokazana w nawiasie ( po nazwie tabeli ) z liczbą pól w values (). Musisz dokładnie posprawdzać, czy nie zabrakło Ci gdzieś przecinka apostrofa ... krok po kroku sprawdź czy do każdej kolumny jest przypisana jakaś wartość.
Go to the top of the page
+Quote Post

Reply to this topicStart new topic
2 Użytkowników czyta ten temat (2 Gości i 0 Anonimowych użytkowników)
0 Zarejestrowanych:

 



RSS Aktualny czas: 26.08.2025 - 21:43