Error in the functions.php file Error in the functions.php file
 

News:

CPG Release 1.6.26
Correct PHP8.2 issues with user and language managers.
Additional fixes for PHP 8.2
Correct PHP8 error with SMF 2.0 bridge.
Correct IPTC supplimental category parsing.
Download and info HERE

Main Menu

Error in the functions.php file

Started by goddesscal, July 15, 2005, 12:33:04 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

goddesscal

 I hope I have posted in the right place. I keep getting instances where I can't get onto my gallery. nothing comes up but a blank page
and this error message:

Notice: Undefined index: debug_mode in (my webspace, my username blah blah)........./coppermine/include/functions.inc.php on line 96
Fatal error :
There was an error while processing a database query. I don't know what to do.  Someone please help? It did this before then went away
and now it's doing it again.



USER:
------------------
Array
(
    [ID] => 369b4d4267d98c50d2e4ab17d0c3b426
    [am] => 1
    [liv] => Array
        (
           
  • => 2969
                [1] => 2662
                [2] => 3007
                [3] => 3051
                [4] => 2741
            )

    )

    ==========================
    USER DATA:
    ------------------
    Array
    (
        [user_id] => 1
        [user_group] => 1
        [user_active] => YES
        [user_name] => Lelia
        [user_password] => ********
        [user_lastvisit] => 2005-07-14 15:10:47
        [user_regdate] => 2005-05-17 06:16:41
        [user_group_list] =>
        [user_email] =>
        [user_website] =>
        [user_location] =>
        [user_interests] =>
        [user_occupation] =>
        [user_actkey] =>
        [disk_max] => 0
        [disk_min] => 0
        [can_rate_pictures] => 1
        [can_send_ecards] => 1
        [ufc_max] => 3
        [ufc_min] => 3
        [custom_user_upload] => 0
        [num_file_upload] => 5
        [num_URI_upload] => 3
        [can_post_comments] => 1
        [can_upload_pictures] => 1
        [can_create_albums] => 1
        [has_admin_access] => 1
        [pub_upl_need_approval] => 0
        [priv_upl_need_approval] => 0
        [group_name] => Administrators
        [upload_form_config] => 3
        [group_quota] => 0
        [can_see_all_albums] => 1
        [group_id] => 1
        [groups] => Array
            (
                [1] => 1
            )

    )

    ==========================
    Queries:
    ------------------
    Array
    (
       
  • => SELECT extension, mime, content FROM cpg133_filetypes;
        [1] => SELECT * FROM cpg133_users WHERE user_id='1'AND user_active = 'YES' AND user_password != '' AND BINARY MD5(user_password) = 'fc790920e9cc275a6f717b8278dfce03'
        [2] => SELECT MAX(group_quota) as disk_max, MIN(group_quota) as disk_min, MAX(can_rate_pictures) as can_rate_pictures, MAX(can_send_ecards) as can_send_ecards, MAX(upload_form_config) as ufc_max, MIN(upload_form_config) as ufc_min, MAX(custom_user_upload) as custom_user_upload, MAX(num_file_upload) as num_file_upload, MAX(num_URI_upload) as num_URI_upload, MAX(can_post_comments) as can_post_comments, MAX(can_upload_pictures) as can_upload_pictures, MAX(can_create_albums) as can_create_albums, MAX(has_admin_access) as has_admin_access, MIN(pub_upl_need_approval) as pub_upl_need_approval, MIN( priv_upl_need_approval) as  priv_upl_need_approval FROM cpg133_usergroups WHERE group_id in (1)
        [3] => SELECT group_name FROM  cpg133_usergroups WHERE group_id= 1
        [4] => DELETE FROM cpg133_banned WHERE expiry < '2005-07-14 15:14:12'
        [5] => SELECT * FROM cpg133_banned WHERE ip_addr='68.170.173.7' OR ip_addr='68.170.173.7' OR user_id=1
        [6] => UPDATE cpg133_config SET  value = '' WHERE name = 'gallery_name'
        [7] => UPDATE cpg133_config SET  value = '' WHERE name = 'gallery_description'
        [8] => UPDATE cpg133_config SET  value = 'you@somewhere.com' WHERE name = 'gallery_admin_email'
        [9] => UPDATE cpg133_config SET  value = 'http://www.eccentricity-online.com/coppermine/'; WHERE name = 'ecards_more_pic_target'
        [10] => UPDATE cpg133_config SET  value = '0' WHERE name = 'offline'
        [11] => UPDATE cpg133_config SET  value = '0' WHERE name = 'log_ecards'
        [12] => UPDATE cpg133_config SET  value = '1' WHERE name = 'enable_zipdownload'
        [13] => UPDATE cpg133_config SET  value = 'english' WHERE name = 'lang'
        [14] => UPDATE cpg133_config SET  value = 'water_drop' WHERE name = 'theme'
        [15] => UPDATE cpg133_config SET  value = '0' WHERE name = 'language_list'
        [16] => UPDATE cpg133_config SET  value = '0' WHERE name = 'language_flags'
        [17] => UPDATE cpg133_config SET  value = '1' WHERE name = 'language_reset'
        [18] => UPDATE cpg133_config SET  value = '0' WHERE name = 'theme_list'
        [19] => UPDATE cpg133_config SET  value = '1' WHERE name = 'theme_reset'
        [20] => UPDATE cpg133_config SET  value = '0' WHERE name = 'display_faq'
        [21] => UPDATE cpg133_config SET  value = '1' WHERE name = 'show_bbcode_help'
        [22] => UPDATE cpg133_config SET  value = 'language file' WHERE name = 'charset'
        [23] => UPDATE cpg133_config SET  value = '100%' WHERE name = 'main_table_width'
        [24] => UPDATE cpg133_config SET  value = '1' WHERE name = 'subcat_level'
        [25] => UPDATE cpg133_config SET  value = '12' WHERE name = 'albums_per_page'
        [26] => UPDATE cpg133_config SET  value = '2' WHERE name = 'album_list_cols'
        [27] => UPDATE cpg133_config SET  value = '50' WHERE name = 'alb_list_thumb_size'
        [28] => UPDATE cpg133_config SET  value = 'breadcrumb/catlist/alblist/random,2/lastup,2' WHERE name = 'main_page_layout'
        [29] => UPDATE cpg133_config SET  value = '0' WHERE name = 'first_level'
        [30] => UPDATE cpg133_config SET  value = '4' WHERE name = 'thumbcols'
        [31] => UPDATE cpg133_config SET  value = '3' WHERE name = 'thumbrows'
        [32] => UPDATE cpg133_config SET  value = '12' WHERE name = 'max_tabs'
        [33] => UPDATE cpg133_config SET  value = '1' WHERE name = 'caption_in_thumbview'
        [34] => UPDATE cpg133_config SET  value = '1' WHERE name = 'views_in_thumbview'
        [35] => UPDATE cpg133_config SET  value = '0' WHERE name = 'display_comment_count'
        [36] => UPDATE cpg133_config SET  value = '0' WHERE name = 'display_uploader'
        [37] => UPDATE cpg133_config SET  value = 'dd' WHERE name = 'default_sort_order'
        [38] => UPDATE cpg133_config SET  value = '1' WHERE name = 'min_votes_for_rating'
        [39] => UPDATE cpg133_config SET  value = '600px' WHERE name = 'picture_table_width'
        [40] => UPDATE cpg133_config SET  value = '0' WHERE name = 'display_pic_info'
        [41] => UPDATE cpg133_config SET  value = '0' WHERE name = 'filter_bad_words'
        [42] => UPDATE cpg133_config SET  value = '1' WHERE name = 'enable_smilies'
        [43] => UPDATE cpg133_config SET  value = '0' WHERE name = 'disable_comment_flood_protect'
        [44] => UPDATE cpg133_config SET  value = '512' WHERE name = 'max_img_desc_length'
        [45] => UPDATE cpg133_config SET  value = '38' WHERE name = 'max_com_wlength'
        [46] => UPDATE cpg133_config SET  value = '10' WHERE name = 'max_com_lines'
        [47] => UPDATE cpg133_config SET  value = '512' WHERE name = 'max_com_size'
        [48] => UPDATE cpg133_config SET  value = '0' WHERE name = 'display_film_strip'
        [49] => UPDATE cpg133_config SET  value = '5' WHERE name = 'max_film_strip_items'
        [50] => UPDATE cpg133_config SET  value = '0' WHERE name = 'email_comment_notification'
        [51] => UPDATE cpg133_config SET  value = '5000' WHERE name = 'slideshow_interval'
        [52] => UPDATE cpg133_config SET  value = '80' WHERE name = 'jpeg_qual'
        [53] => UPDATE cpg133_config SET  value = '100' WHERE name = 'thumb_width'
        [54] => UPDATE cpg133_config SET  value = 'any' WHERE name = 'thumb_use'
        [55] => UPDATE cpg133_config SET  value = '1' WHERE name = 'make_intermediate'
        [56] => UPDATE cpg133_config SET  value = '400' WHERE name = 'picture_width'
        [57] => UPDATE cpg133_config SET  value = '1024' WHERE name = 'max_upl_size'
        [58] => UPDATE cpg133_config SET  value = '2048' WHERE name = 'max_upl_width_height'
        [59] => UPDATE cpg133_config SET  value = '0' WHERE name = 'show_private'
        [60] => UPDATE cpg133_config SET  value = '$/\\\\:*?"\'<>|`' WHERE name = 'forbiden_fname_char'
        [61] => UPDATE cpg133_config SET  value = 'ALL' WHERE name = 'allowed_img_types'
        [62] => UPDATE cpg133_config SET  value = 'ALL' WHERE name = 'allowed_mov_types'
        [63] => UPDATE cpg133_config SET  value = 'ALL' WHERE name = 'allowed_snd_types'
        [64] => UPDATE cpg133_config SET  value = 'ALL' WHERE name = 'allowed_doc_types'
        [65] => UPDATE cpg133_config SET  value = 'gd2' WHERE name = 'thumb_method'
        [66] => UPDATE cpg133_config SET  value = '' WHERE name = 'impath'
        [67] => UPDATE cpg133_config SET  value = '-antialias' WHERE name = 'im_options'
        [68] => UPDATE cpg133_config SET  value = '0' WHERE name = 'read_exif_data'
        [69] => UPDATE cpg133_config SET  value = '0' WHERE name = 'read_iptc_data'
        [70] => UPDATE cpg133_config SET  value = 'albums/' WHERE name = 'fullpath'
        [71] => UPDATE cpg133_config SET  value = 'userpics/' WHERE name = 'userpics'
        [72] => UPDATE cpg133_config SET  value = 'normal_' WHERE name = 'normal_pfx'
        [73] => UPDATE cpg133_config SET  value = 'thumb_' WHERE name = 'thumb_pfx'
        [74] => UPDATE cpg133_config SET  value = '0755' WHERE name = 'default_dir_mode'
        [75] => UPDATE cpg133_config SET  value = '0644' WHERE name = 'default_file_mode'
        [76] => UPDATE cpg133_config SET  value = '0' WHERE name = 'allow_user_registration'
        [77] => UPDATE cpg133_config SET  value = '1' WHERE name = 'reg_requires_valid_email'
        [78] => UPDATE cpg133_config SET  value = '0' WHERE name = 'reg_notify_admin_email'
        [79] => UPDATE cpg133_config SET  value = '0' WHERE name = 'allow_duplicate_emails_addr'
        [80] => UPDATE cpg133_config SET  value = '1' WHERE name = 'allow_private_albums'
        [81] => UPDATE cpg133_config SET  value = '0' WHERE name = 'upl_notify_admin_email'
        [82] => UPDATE cpg133_config SET  value = '0' WHERE name = 'allow_memberlist'
        [83] => UPDATE cpg133_config SET  value = '' WHERE name = 'user_field1_name'
        [84] => UPDATE cpg133_config SET  value = '' WHERE name = 'user_field2_name'
        [85] => UPDATE cpg133_config SET  value = '' WHERE name = 'user_field3_name'
        [86] => UPDATE cpg133_config SET  value = '' WHERE name = 'user_field4_name'
        [87] => UPDATE cpg133_config SET  value = 'cpg133' WHERE name = 'cookie_name'
        [88] => UPDATE cpg133_config SET  value = '/' WHERE name = 'cookie_path'
        [89] => UPDATE cpg133_config SET  value = '2' WHERE name = 'debug_mode'
        [90] => UPDATE cpg133_config SET  value = '0' WHERE name = 'debug_notice'
    )

    ==========================
    GET :
    ------------------
    Array
    (
    )

    ==========================
    POST :
    ------------------
    Array
    (
        [gallery_name] =>
        [gallery_description] =>
        [gallery_admin_email] => you@somewhere.com
        [ecards_more_pic_target] => http://www.eccentricity-online.com/coppermine/
        [offline] => 0
        [log_ecards] => 0
        [enable_zipdownload] => 1
        [lang] => english
        [theme] => water_drop
        [language_list] => 0
        [language_flags] => 0
        [language_reset] => 1
        [theme_list] => 0
        [theme_reset] => 1
        [display_faq] => 0
        [show_bbcode_help] => 1
        [charset] => language file
        [main_table_width] => 100%
        [subcat_level] => 1
        [albums_per_page] => 12
        [album_list_cols] => 2
        [alb_list_thumb_size] => 50
        [main_page_layout] => breadcrumb/catlist/alblist/random,2/lastup,2
        [first_level] => 0
        [thumbcols] => 4
        [thumbrows] => 3
        [max_tabs] => 12
        [caption_in_thumbview] => 1
        [views_in_thumbview] => 1
        [display_comment_count] => 0
        [display_uploader] => 0
        [default_sort_order] => dd
        [min_votes_for_rating] => 1
        [picture_table_width] => 600px
        [display_pic_info] => 0
        [filter_bad_words] => 0
        [enable_smilies] => 1
        [disable_comment_flood_protect] => 0
        [max_img_desc_length] => 512
        [max_com_wlength] => 38
        [max_com_lines] => 10
        [max_com_size] => 512
        [display_film_strip] => 0
        [max_film_strip_items] => 5
        [email_comment_notification] => 0
        [slideshow_interval] => 5000
        [jpeg_qual] => 80
        [thumb_width] => 100
        [thumb_use] => any
        [make_intermediate] => 1
        [picture_width] => 400
        [max_upl_size] => 1024
        [max_upl_width_height] => 2048
        [show_private] => 0
        [forbiden_fname_char] => $/\\:*?"'<>|`
        [allowed_img_types] => ALL
        [allowed_mov_types] => ALL
        [allowed_snd_types] => ALL
        [allowed_doc_types] => ALL
        [thumb_method] => gd2
        [impath] =>
        [im_options] => -antialias
        [read_exif_data] => 0
        [read_iptc_data] => 0
        [fullpath] => albums/
        [userpics] => userpics/
        [normal_pfx] => normal_
        [thumb_pfx] => thumb_
        [default_dir_mode] => 0755
        [default_file_mode] => 0644
        [allow_user_registration] => 0
        [reg_requires_valid_email] => 1
        [reg_notify_admin_email] => 0
        [allow_duplicate_emails_addr] => 0
        [allow_private_albums] => 1
        [upl_notify_admin_email] => 0
        [allow_memberlist] => 0
        [user_field1_name] =>
        [user_field2_name] =>
        [user_field3_name] =>
        [user_field4_name] =>
        [cookie_name] => cpg133
        [cookie_path] => /
        [debug_mode] => 2
        [debug_notice] => 0
        [update_config] => Save new configuration
    )

    ==========================
    VERSION INFO :
    ------------------
    PHP version: 4.4.0 - OK
    ------------------
    mySQL version: 4.1.9-log
    ------------------
    Coppermine version: 1.3.3
    ==========================
    Module: gd
    ------------------
    GD Support enabled
    GD Version bundled (2.0.28 compatible)
    FreeType Support enabled
    FreeType Linkage with freetype
    GIF Read Support enabled
    GIF Create Support enabled
    JPG Support enabled
    PNG Support enabled
    WBMP Support enabled
    XBM Support enabled
    ==========================
    Module: mysql
    ------------------
    Active Persistent Links 0
    Active Links 1
    Client API version 4.1.11
    MYSQL_MODULE_TYPE external
    MYSQL_SOCKET /tmp/mysql.sock
    MYSQL_INCLUDE -I/usr/local/include/mysql
    MYSQL_LIBS -L/usr/local/lib/mysql -lmysqlclient 
    ==========================
    Module: zlib
    ------------------
    ZLib Support enabled
    Compiled Version 1.1.4
    Linked Version 1.1.4
    ==========================
    Server restrictions (safe mode)?
    ------------------
    Directive | Local Value | Master Value
    safe_mode | Off | Off
    safe_mode_exec_dir | no value | no value
    safe_mode_gid | Off | Off
    safe_mode_include_dir | no value | no value
    safe_mode_exec_dir | no value | no value
    sql.safe_mode | Off | Off
    disable_functions | no value | no value
    file_uploads | On | On
    include_path | .:/usr/local/php4/lib/php | .:/usr/local/php4/lib/php
    open_basedir | no value | no value
    ==========================
    email
    ------------------
    Directive | Local Value | Master Value
    sendmail_from | me@localhost.com | me@localhost.com
    sendmail_path | /usr/sbin/sendmail -t -i  | /usr/sbin/sendmail -t -i
    SMTP | localhost | localhost
    smtp_port | 25 | 25
    ==========================
    Size and Time
    ------------------
    Directive | Local Value | Master Value
    max_execution_time | 30 | 30
    max_input_time | 60 | 60
    upload_max_filesize | 2M | 2M
    post_max_size | 8M | 8M
    ==========================
    Page generated in 0.204 seconds - 91 queries in 0.039 seconds - Album set :

kegobeer

Please search the forum for "undefined index: debug_mode".  There are plenty of posts about it.
Do not send me a private message unless I ask for one.  Make your post public so everyone can benefit.

There are no stupid questions
But there are a LOT of inquisitive idiots

goddesscal

Kegobeer,

Ok I read what I could find on the subject and went back into my config and turned display notices in debug to 'no'
and Enable debug mode to 'off'   It's still giving me that error message. What am I missing?  and yes I have no clue what i'm doing.
apologies in advance.

Nibbler

Enable debug mode and post the SQL error message that you get when you replicate the error :)

kegobeer

Also do another search, this time click the Advanced Search llink.  Enter undefined index debug_mode in the search box, check the Show results as messages box, and change the Search order to Most recent topics first.
Do not send me a private message unless I ask for one.  Make your post public so everyone can benefit.

There are no stupid questions
But there are a LOT of inquisitive idiots

goddesscal

Ok guys,

I did what you said. Except for the posting the sql error. How do I do this? Get the real error msg is what you mean yes?  not this below..

Notice: Undefined index: debug_mode in /www/g/goddesscal/htdocs/coppermine/include/functions.inc.php on line 96
Fatal error :
There was an error while processing a database query


which is what I keep getting.  How do I get the sql error info you want?

I did run the Update.php and that didn't fix anything.

When I enable debug mode I click Admin only , should I be choosing 'yes everyone'?

As far as I know all my files were uploaded to my site when I did install. A friend had to take it from there and finished the install for me.
as I don't understand what I'm doing.

Also I don't know what a query is and I can't find where to change debug from 0 to 1 if I need too.

My site url http://www.eccentricity-online.com   
gallery url   http://www.eccentricity-online.com/coppermine/index.php   
if you need them.


goddesscal

Umm , I know people are busy but is anyone going to help me out? The problem did what it had done before and has stopped but I know it's going to happen again and  is still not resolved. Am I suppose to post another thread on it when it happens again?

Joachim Müller

unable to replicate - your site displays fine for me. Post on what page (after doing what) you get the error message.

kegobeer

If this suddenly happens then goes away, you might want to ask your host what's going on.  You should review your error logs (ask your host), too.
Do not send me a private message unless I ask for one.  Make your post public so everyone can benefit.

There are no stupid questions
But there are a LOT of inquisitive idiots