1.
Notice: Use of undefined constant ddsg_language – assumed ‘ddsg_language’ in /home/squib/yuuryou-syouhinn.jp/public_html/wp-content/plugins/sitemap-generator/sitemap-generator.php on line 45
http://wordpress.org/support/topic/notice-use-of-undefined-constant-ddsg_language
2.
>Notice: Undefined variable: control_ops in /home/squib/yuuryou-syouhinn.jp/public_html/wp-content/themes/wp/widget.php on line 841
ウィジェットの中身のエラーですので、どのような設定をしてるかを提示すると解決策が得られるかもしれません。
また、ウィジェットの使用を止めても出てきますか?
3.
>Notice: Undefined variable: request_type in /home/squib/yuuryou-syouhinn.jp/public_html/wp-content/themes/wp/index.php on line 12
使用しているテーマのindex.phpの12行目に何が書いてありますか?
4.
Notice: Use of undefined constant user_level – assumed ‘user_level’ in /home/squib/yuuryou-syouhinn.jp/public_html/wp-content/plugins/ultimate-google-analytics/ultimate_ga.php on line 524
http://ja.forums.wordpress.org/topic/2033
infra様へ(メンバー 7 hours前の投稿 # )
早速の、ご対応、有難うございます。
ご提示頂いた方法にて、対処を始めてみます。
追伸、infra様へ
非常に失礼な質問かもしれませんが、
infra様へのお考えとしては、wordpressに取り組む姿勢としては、動作に支障なくとも、Noticeはつぶしておくべきだというご判断と考えてもよろしいのでしょうか。
現在、wordpressをMultiインストールで使用しておりますが、問題なく使えております。
しかし、
define(‘WP_DEBUG’, false);
を
define(‘WP_DEBUG’, true);
にすると、いくつかのNoticeが表示されます。
表示されるNOTICE
Notice: Undefined variable: control_ops in /home/squib/liaise.jp/public_html/wp-content/themes/wp-3-main/widget.php on line 841
Notice: Undefined variable: request_type in /home/squib/liaise.jp/public_html/wp-content/themes/wp-3-main/index.php on line 12
それぞれのエラーに対応するPHPの中身は以下です。
———————————————————————————–
/home/squib/liaise.jp/public_html/wp-content/themes/wp-3-main/widget.php on line 841
———————————————————————————–
widget.php
———————————————————————————–
829 /**
830 * WP_Widget_Contact_keni
831 *
832 * 問い合わせページへのリンク
833 * ページをドロップダウンで選択
834 * scandir 使用、要 PHP5
835 */
836 class WP_Widget_Contact_keni extends WP_Widget {
837 const CONTACT_IMG_DIR = “/images/common”;
838
839 function WP_Widget_Contact_keni() {
840 $widget_ops = array(‘classname’ => ‘widget-contact-keni’, ‘description’ => __( ‘Contact’,’keni’) ); ct’,’keni’) );
841 $this->WP_Widget(‘contact’, __(‘Contact’,’keni’), $widget_ops, $control_ops);
842 }
843
844 function widget( $args, $instance ) {
845 extract($args, EXTR_SKIP);
846 $title = apply_filters(‘widget-title’, empty($instance[‘title’]) ? __(‘Contact’,’keni’) : $instance[‘title’]);
847 $urlid = (int) $instance[‘urlid’];
848 $description = esc_attr($instance[‘description’]);
849 if ( file_exists(TEMPLATEPATH.self::CONTACT_IMG_DIR.”/”.$instance[‘imgfile’]) ) {
850 $imgfile = $instance[‘imgfile’];
851 } else {
852 $imgfile = “dummy-prof.jpg”;
853 }
854 $imgdata = getimagesize(TEMPLATEPATH.self::CONTACT_IMG_DIR.”/”.$instance[‘imgfile’]);
855 if ( $title ) echo $before_title . $title . $after_title;
856 echo ‘<div class=”contents”>’;
857 ?>
858 <p class=”contact”>“><img src=”<?php bloginfo(‘template_url’); ?><?php echo self::CONTACT_IMG_DIR; ?>/<?php echo $imgfile; ?>” <?php echo $imgdata[3] ;?> alt=”<?php _e(‘Contact’,’keni’); ?>” /><?php if ( $description ) esc_html_e($description) ;
859 echo ‘</p>’;
860 echo ‘</div>’;
861 }
862
863 function update( $new_instance, $old_instance ) {
864 $instance = $old_instance;
865 $instance[‘title’] = esc_attr($new_instance[‘title’]);
866 $instance[‘urlid’] = (int) $new_instance[‘urlid’];
867 $instance[‘description’] = esc_attr($new_instance[‘description’]);
868 $instance[‘imgfile’] = esc_attr($new_instance[‘imgfile’]);
869
870 return $instance;
871 }
872
———————————————————————————–
/home/squib/liaise.jp/public_html/wp-content/themes/wp-3-main/index.php on line 12
———————————————————————————–
index.php
———————————————————————————–
1 <?php
2 if ( SITEMAP_KENI ) {
3
4 include ( TEMPLATEPATH . “/conf.php” );
5 foreach( $_REQUEST as $request_key => $request_value ){
6 foreach( $REQUEST_PAGE_CONF_LIST as $confkey => $confvalue ){
7 if( $confkey == $request_key ){ $request_type = $confvalue; break; }
8 }
9 }
10 }
11
12 if( SITEMAP_KENI && $request_type != null ) {
13 include (TEMPLATEPATH . “/”. $request_type );
14 } else {
15 get_header(); ?>
16
17 <body <?php body_class(); ?>>
18 <!– container Start –>
19 <div id=”container”>
20 <!– /container Start –>
21
動作条件は、以下です。
wordpress-3.2.1
phpは、5.3.3
MySQL5は、5.0.77
です。
何卒、ご指導をお願いいたします。
>ikechanさん
上記内容でのマルチポストが確認されましたので、新規スレッドを削除させていただきました。
同一エラー同一内容でしたので、本スレッドでの解決をお願いします。
賢威さんのところのテーマでしょうか。
そちらで聞いたほうが確実な回答が得られると思います
> infra様へのお考えとしては、wordpressに取り組む姿勢としては、動作に支障なくとも、Noticeはつぶしておくべきだというご判断と考えてもよろしいのでしょうか。
noticeに気づかなければしょうがないけど、debugをonにして気づいてしまったからにはなんとか対処する。っていうのが精神的にいいんじゃないでしょうか
infra様へ
ご指摘、もっともです、
★まずは、infra様へ、度々のご対応有難うございます。
非常に感謝いたしております。
「noticeに気づかなければしょうがないけど、debugをonにして気づいてしまったからにはなんとか対処する。っていうのが精神的にいいんじゃないでしょうか」
・・・その通りです。必ず解消してから前に進みたいと思います。
しかし、「賢威さん」方にも、問は投げかけていますが、「致命的」でないため、対応してくれないかもしれません。
あてにもできないので現在のwpのthemeフォルダ内の、全ファイルのコードを読み込んで、全部をつなぎ合わげ、8,000行近いtxtにして先日よりPHPを調べまくりました。
その結果
Notice: Undefined variable: request_type in /home/squib/liaise.jp/public_html/wp-content/themes/wp-3-main/index.php on line 12
については、以下で解消しました。
———————————————————————————–
/home/squib/liaise.jp/public_html/wp-content/themes/wp-3-main/index.php on line 12
———————————————————————————–
index.php
———————————————————————————–
1 <?php
$request_type =””; //この行を追加しました。
2 if ( SITEMAP_KENI ) {
3
4 include ( TEMPLATEPATH . “/conf.php” );
5 foreach( $_REQUEST as $request_key => $request_value ){
6 foreach( $REQUEST_PAGE_CONF_LIST as $confkey => $confvalue ){
7 if( $confkey == $request_key ){ $request_type = $confvalue; break; }
8 }
9 }
10 }
11
Notice: Undefined variable: control_ops in /home/squib/liaise.jp/public_html/wp-content/themes/wp-3-main/widget.php on line 841
についても、今、調査中です。
できる限り頑張ってみます。
有難うございました。
これからもお願いいたします。
また、
Notice: Undefined variable: control_ops in /home/squib/liaise.jp/public_html/wp-content/themes/wp-3-main/widget.php on line 841
の解消につきまして、ヒントをくださる方がいらっしゃいましたら。
是非、お願いいたします。