ホームページ php教程 php手册 コンパクトなPHPドキュメント生成クラス

コンパクトなPHPドキュメント生成クラス

Jun 21, 2016 am 09:15 AM
content function gt path quot

プロジェクトの開発中に、他の人が php ドキュメントの管理が不足していることに気付きました。しかし、そのドキュメントには多くの機能がありませんでした

/**
* クラス名: doc
* 説明: ドキュメント生成クラス
* その他: ソースディレクトリを設定した後、生成されるディレクトリを絶対パスで指定することができます。 モード
* 1 は調整可能です。通常のタイプ、つまりスラッシュ ** で始まり * スラッシュで終わる
* 2 は、スラッシュ * で始まり * スラッシュで終わるものはすべて、ドキュメントの一部になります
。*/
class doc
{
var $docdirname;
var $docdir;

/**
* 関数名: doc()
* 関数関数: 構築
* 入力パラメータ: なし
* 関数戻り値: 戻り値の説明
* その他の命令: 2004-10-13
*/
function doc()
{
$this->docdirname = "doc/";
}

/**
* 関数名: createDoc($root,$newdir,$mode="1",$filter=null)
* 関数: ドキュメントの作成
* 入力パラメータ: $root ----------- - -- ソースディレクトリ
$newdir ----------- ターゲットディレクトリ
$mode ------------- モード、1 は通常、2 は拡張
$filter - - ---------- フィルターディレクトリ
* 関数の戻り値: 戻り値の説明
* その他の説明: 2004-10-13
*/
function createDoc($root,$ newdir,$mode="1",$filter=null)
{
$getarr = $this->loopDir($root,$filter);
$i = 0;
$this->createFrame($newdir );
foreach($getarr as $key=>$val)
{
if($this->getPhpFiles($val))
{
$content = $this ->getContent($val);
$content = $this->getDoc($content,$mode);
$filepath = $this->setFilepath($val,$root,$newdir);
$ filedir = $this->getFileDir($ filepath);
$this->mkdirs($filedir);
$this->setDoc($filepath,$content);
$data[$i]['url '] = "$filepath";
$ data[$i]['name'] = "$val";
$i++;
}
}
if(!empty($data))
{
$this- >createMenu($newdir,$data) ;
$this->redirect($this->docdir);
}
}

/**
* 関数名: redirect($path)
* 関数関数: redirect
* 入力パラメータ: $path ---------------- リダイレクトパス
* 関数の戻り値: 戻り値の説明
*その他の指示: 2004-10-13
*/
function redirect($path)
{
echo "ドキュメントは正常に生成されました。ここをクリックして表示します";
}

/**
* 関数名:loopDir($root,$filter=null)
* 関数: ディレクトリのトラバース
* 入力パラメータ: $root ------------------- ソースディレクトリ
$filter ----------------- Filter
* 関数の戻り値: array
* その他の命令: 2004-10-13
*/
functionloopDir($root,$filter=null)
{
static $getarr=array();
$d = dir($root);
while (false !== ($entry = $d->read( )))
{
if ($entry = = "." || $entry == "..")
{
continue;
}
if($this->filter($entry,$filter))
{
if(is_dir($root.$entry))
{
$this->loopDir($d->gt;path.$entry."/");
}
else
{
$getarr[] = $d->path.$entry
}
}
}
$d->close();
Return $getarr;
}

/**
* 関数名: getPhpFiles($path)
* 関数関数: PHP ドキュメントの抽出
* 入力パラメータ: $path ---------------- ドキュメントパス
* 関数の戻り値: bool
*その他の指示: 2004-10-13
*/
function getPhpFiles($path )
{
$type = preg_replace('/ .*.(.*[^.].*)/i','\1',$path);
$type = strto lower($type);
if( $type=="php")
{
Return true;
}
else
{
Return false;
}
}

/**
* 関数名: getContent($path)
* 関数機能: ファイルの内容を読み取る
* 入力パラメータ: $path ------------------- ファイルパス
* 関数の戻り値値: 文字列
* その他の指示: 2004-10-13
*/
function getContent($path)
{
$fp = ファイル($パス);
$content = implode('',$fp);
Return $content;
}

/**
* 関数名: getDoc($content,$mode="1")
* 関数機能: php ファイル内のコメントを取得します
* 入力パラメータ: $content ------------ ドキュメントのコンテンツ
$mode --------------- モード、1は通常、2は拡張
* 関数の戻り値: string
* その他の命令: 2004-10-13
*/
function getDoc($content,$mode="1")
{
switch($mode )
{
case '1':
$pattern = '//(*)[rn].**//isU';
ブレーク;
case '2':
$pattern = '//*.** //isU';
break;
}

preg_match_all($pattern,$content,$carr);
$getarr = array();
foreach($carr[0] as $key=>$val)
{
$getarr[] = トリム($val);
}
$str = implode("

",$getarr);
$str = preg_replace('/[r]/i' ,'
',$str);
$style = $this->getStyle();
$str = $this->getTable($str);
$str = $style.$str;
Return $str;
}

/**
* 関数名: etFilepath($filepath,$oldroot,$newroot)
* 関数: 生成されたファイルへのパスを設定します
* 入力パラメータ: $filepath -------------- ソースファイルパス
$oldroot -------------- ソース ディレクトリ パス
$newroot -------------- ターゲット ディレクトリ パス
* 関数の戻り値: 文字列
*その他の説明: 2004-10-13
*/
function setFilepath($filepath,$oldroot,$newroot)
{
$oldroot = str_replace('/',"\/",$oldroot) ;
$pattern = "/".$oldroot."(.*)/iU";
$filepath = preg_replace($pattern,'\1',$filepath);
$newpath = $newroot.$this-> ;docdirname.$filepath;//echo "$newpath
";
$newpath = preg_replace('/(.*.)(.*[^.].*)/i','\1htm',$ newpath);
Return $newpath;
}

/**
* 関数名: getFileDir($path)
* 関数関数: ドキュメントディレクトリを取得
* 入力パラメータ: $path ------------- ドキュメントパス
* 関数戻り値: string
*その他の説明: 2004-10-13
*/
function getFileDir($path)
{
$getpath = preg_replace('/(.*)(/.*[^.]. *)/i','\1',$path);
Return $getpath;
}

/**
* 関数名: setDoc
* 関数の機能: 指定されたディレクトリにコメントを書き込み、ページを生成します
* 入力パラメータ: $filepath --------------- ディレクトリパス
$content -- - ------------- 記述内容
* 関数の戻り値: 戻り値の説明
* その他の説明: 説明
*/
function setDoc($filepath,$content)
{
$fp = fopen( $filepath,"w+");
flock($fp,LOCK_EX);
fwrite($fp,$content);
flock($fp, LOCK_UN);
}

/**
* 関数名: mkdirs($path)
* 関数関数: ディレクトリの作成
* 入力パラメータ: $path ------------------- パス
* 関数の戻り値:なし
*その他の説明: 2004-10-13
*/
関数mkdirs($path)
{
$adir =explode('/',$path);
$dirlist = '';
$rootdir = $adir[0];
array_shift ($adir);
foreach($adir as $key=>$val)
{
if($val!='.'&&$val!='..')
{
$dirlist .= "/".$val;
$dirpath = $ rootdir.$dirlist;
if(!file_exists($dirpath)&&!is_file($dirpath))
{
mkdir($dirpath);
chmod($dirpath,0777);
}
}
}
}

/**
* 関数名: filter($item,$arr=null)
* 関数: filter
* 入力パラメータ: $item -------------- Content
$arr ---- - ---------- Filter item
* 関数の戻り値: bool
* その他の命令: 2004-10-13
*/
関数 filter($item,$arr=null)
{
$item = strto lower($item);
$filter =explode(',',$arr);
if($ arr==null||!in_array($item,$filter))
{
Return true;
}
else
{
Return false;
}
}

/**
* 関数名: createFrame($root)
* 関数関数: フレームページ生成
* 入力パラメータ: $root --------------- ホームページ格納ディレクトリ
* 関数戻り値: str
* その他の指示: 2004-10-13
*/
function createFrame($root)
{
$str = '



無标题文档






<body><br> </body>< ;/noframes><br/> </html>';<br/> $this->docdir = $root."index.htm";<br/> $this->setDoc($this->docdir,$str);<br/> } <br/><br/> /**<br/> * 関数名: createMenu($root,$data)<br/> * 関数: メニューの生成<br/> * 入力パラメーター: $root ------------------- ページをディレクトリ<br/> $data ------------------ Content<br/> * 関数の戻り値: string<br/> * その他の命令: 2004-10-13<br/>*/<br/> function createMenu($root,$data)<br/> {<br/> $path = $root."menu.htm";<br/> $str = $this->getStyle();<br/> $ str.= "<table>";<br> foreach($data as $key=>$val)<br> {<br> $str.= "<tr><td><a href='".$val ['url']."' target='mainFrame'>".$val['name']."</a></td></tr>";<br> }<br> $str.= "</table>";<br> $this->setDoc($path,$str);<br> }<br><br> /**<br> * 関数名: getStyle()<br> * 関数 function: style<br> * 入力パラメータ: none<br> * 関数の戻り値: string<br> * その他の命令: 2004-10-13<br>*/<br> function getStyle()<br> {<br> $str = '<br> < style><br> table {<br> font-family: "Courier New","宋体";<br> border-collapse: Collapse;<br> word-break:break-all;<br> }<br> td {<br> font-family: "Courier New", "宋体";<br> font-size: 12px;<br> line-height: 22px;<br> }<br> </style>';<br> Return $str;<br> }<br><br> /**<br> * 関数名: getTable($content)<br> * 関数関数: コンテンツをテーブルに入れる<br> * 入力パラメータ: $content ------------ コンテンツ<br> * 関数の戻り値: string<br> * その他指示: 2004-10-13<br>*/<br> function getTable($ content)<br> {<br> $str = "<table width="100%" border="1" bordercolor="#dbdbdb" cellpadding="5" cellpadding="0"><br> <tr><br> <td bgcolor="#f5f5f5">".$content."</td><br> </tr><br> </table>";<br> Return $str;<br> }<br>}<br><br>// <br>$d を使用= 新しいドキュメント;<br>$filter = "adodb,smarty,cvs,templates,templates_c";<br>$d->createDoc("e:/www/kpub20/class/","e:/www/test/aaa/ ",1,$filter);<br>?><br><br> </p> <center> </center> <p style="width:100%;text-align:center;margin:10px 0"> <br> <br> </p> <p style="width:100%;text-align:center;margin:10px 0"> </p> <p class="clear"></p> </div> </div> <div class="wzconShengming_sp"> <div class="bzsmdiv_sp">このウェブサイトの声明</div> <div>この記事の内容はネチズンが自主的に寄稿したものであり、著作権は原著者に帰属します。このサイトは、それに相当する法的責任を負いません。盗作または侵害の疑いのあるコンテンツを見つけた場合は、admin@php.cn までご連絡ください。</div> </div> </div> <ins class="adsbygoogle" style="display:block" data-ad-format="autorelaxed" data-ad-client="ca-pub-5902227090019525" data-ad-slot="2507867629"></ins> <script> (adsbygoogle = window.adsbygoogle || []).push({}); </script> <div class="AI_ToolDetails_main4sR"> <ins class="adsbygoogle" style="display:block" data-ad-client="ca-pub-5902227090019525" data-ad-slot="3653428331" data-ad-format="auto" data-full-width-responsive="true"></ins> <script> (adsbygoogle = window.adsbygoogle || []).push({}); </script> <!-- <div class="phpgenera_Details_mainR4"> <div class="phpmain1_4R_readrank"> <div class="phpmain1_4R_readrank_top"> <img onerror="this.onerror=''; this.src='/static/imghw/default1.png'" onerror="this.onerror=''; this.src='/static/imghw/default1.png'" src="/static/imghw/hotarticle2.png" alt="" /> <h2>人気の記事</h2> </div> <div class="phpgenera_Details_mainR4_bottom"> <div class="phpgenera_Details_mainR4_bottoms"> <a href="https://www.php.cn/ja/faq/1796780570.html" title="R.E.P.O.説明されたエネルギー結晶と彼らが何をするか(黄色のクリスタル)" class="phpgenera_Details_mainR4_bottom_title">R.E.P.O.説明されたエネルギー結晶と彼らが何をするか(黄色のクリスタル)</a> <div class="phpgenera_Details_mainR4_bottoms_info"> <span>3週間前</span> <span>By 尊渡假赌尊渡假赌尊渡假赌</span> </div> </div> <div class="phpgenera_Details_mainR4_bottoms"> <a href="https://www.php.cn/ja/faq/1796780641.html" title="R.E.P.O.最高のグラフィック設定" class="phpgenera_Details_mainR4_bottom_title">R.E.P.O.最高のグラフィック設定</a> <div class="phpgenera_Details_mainR4_bottoms_info"> <span>3週間前</span> <span>By 尊渡假赌尊渡假赌尊渡假赌</span> </div> </div> <div class="phpgenera_Details_mainR4_bottoms"> <a href="https://www.php.cn/ja/faq/1796785841.html" title="アサシンのクリードシャドウズ:シーシェルリドルソリューション" class="phpgenera_Details_mainR4_bottom_title">アサシンのクリードシャドウズ:シーシェルリドルソリューション</a> <div class="phpgenera_Details_mainR4_bottoms_info"> <span>2週間前</span> <span>By DDD</span> </div> </div> <div class="phpgenera_Details_mainR4_bottoms"> <a href="https://www.php.cn/ja/faq/1796780520.html" title="R.E.P.O.誰も聞こえない場合はオーディオを修正する方法" class="phpgenera_Details_mainR4_bottom_title">R.E.P.O.誰も聞こえない場合はオーディオを修正する方法</a> <div class="phpgenera_Details_mainR4_bottoms_info"> <span>3週間前</span> <span>By 尊渡假赌尊渡假赌尊渡假赌</span> </div> </div> <div class="phpgenera_Details_mainR4_bottoms"> <a href="https://www.php.cn/ja/faq/1796779766.html" title="WWE 2K25:Myriseのすべてのロックを解除する方法" class="phpgenera_Details_mainR4_bottom_title">WWE 2K25:Myriseのすべてのロックを解除する方法</a> <div class="phpgenera_Details_mainR4_bottoms_info"> <span>4週間前</span> <span>By 尊渡假赌尊渡假赌尊渡假赌</span> </div> </div> </div> <div class="phpgenera_Details_mainR3_more"> <a href="https://www.php.cn/ja/article.html">もっと見る</a> </div> </div> </div> --> <div class="phpgenera_Details_mainR3"> <div class="phpmain1_4R_readrank"> <div class="phpmain1_4R_readrank_top"> <img onerror="this.onerror=''; this.src='/static/imghw/default1.png'" onerror="this.onerror=''; this.src='/static/imghw/default1.png'" src="/static/imghw/hottools2.png" alt="" /> <h2>ホットAIツール</h2> </div> <div class="phpgenera_Details_mainR3_bottom"> <div class="phpmain_tab2_mids_top"> <a href="https://www.php.cn/ja/ai/undresserai-undress" title="Undresser.AI Undress" class="phpmain_tab2_mids_top_img"> <img onerror="this.onerror=''; this.src='/static/imghw/default1.png'" onerror="this.onerror=''; this.src='/static/imghw/default1.png'" class="lazy" data-src="https://img.php.cn/upload/ai_manual/001/246/273/173411540686492.jpg?x-oss-process=image/resize,m_fill,h_50,w_50" src="/static/imghw/default1.png" alt="Undresser.AI Undress" /> </a> <div class="phpmain_tab2_mids_info"> <a href="https://www.php.cn/ja/ai/undresserai-undress" title="Undresser.AI Undress" class="phpmain_tab2_mids_title"> <h3>Undresser.AI Undress</h3> </a> <p>リアルなヌード写真を作成する AI 搭載アプリ</p> </div> </div> <div class="phpmain_tab2_mids_top"> <a href="https://www.php.cn/ja/ai/ai-clothes-remover" title="AI Clothes Remover" class="phpmain_tab2_mids_top_img"> <img onerror="this.onerror=''; this.src='/static/imghw/default1.png'" onerror="this.onerror=''; this.src='/static/imghw/default1.png'" class="lazy" data-src="https://img.php.cn/upload/ai_manual/001/246/273/173411552797167.jpg?x-oss-process=image/resize,m_fill,h_50,w_50" src="/static/imghw/default1.png" alt="AI Clothes Remover" /> </a> <div class="phpmain_tab2_mids_info"> <a href="https://www.php.cn/ja/ai/ai-clothes-remover" title="AI Clothes Remover" class="phpmain_tab2_mids_title"> <h3>AI Clothes Remover</h3> </a> <p>写真から衣服を削除するオンライン AI ツール。</p> </div> </div> <div class="phpmain_tab2_mids_top"> <a href="https://www.php.cn/ja/ai/undress-ai-tool" title="Undress AI Tool" class="phpmain_tab2_mids_top_img"> <img onerror="this.onerror=''; this.src='/static/imghw/default1.png'" onerror="this.onerror=''; this.src='/static/imghw/default1.png'" class="lazy" data-src="https://img.php.cn/upload/ai_manual/001/246/273/173410641626608.jpg?x-oss-process=image/resize,m_fill,h_50,w_50" src="/static/imghw/default1.png" alt="Undress AI Tool" /> </a> <div class="phpmain_tab2_mids_info"> <a href="https://www.php.cn/ja/ai/undress-ai-tool" title="Undress AI Tool" class="phpmain_tab2_mids_title"> <h3>Undress AI Tool</h3> </a> <p>脱衣画像を無料で</p> </div> </div> <div class="phpmain_tab2_mids_top"> <a href="https://www.php.cn/ja/ai/clothoffio" title="Clothoff.io" class="phpmain_tab2_mids_top_img"> <img onerror="this.onerror=''; this.src='/static/imghw/default1.png'" onerror="this.onerror=''; this.src='/static/imghw/default1.png'" class="lazy" data-src="https://img.php.cn/upload/ai_manual/001/246/273/173411529149311.jpg?x-oss-process=image/resize,m_fill,h_50,w_50" src="/static/imghw/default1.png" alt="Clothoff.io" /> </a> <div class="phpmain_tab2_mids_info"> <a href="https://www.php.cn/ja/ai/clothoffio" title="Clothoff.io" class="phpmain_tab2_mids_title"> <h3>Clothoff.io</h3> </a> <p>AI衣類リムーバー</p> </div> </div> <div class="phpmain_tab2_mids_top"> <a href="https://www.php.cn/ja/ai/ai-hentai-generator" title="AI Hentai Generator" class="phpmain_tab2_mids_top_img"> <img onerror="this.onerror=''; this.src='/static/imghw/default1.png'" onerror="this.onerror=''; this.src='/static/imghw/default1.png'" class="lazy" data-src="https://img.php.cn/upload/ai_manual/001/246/273/173405034393877.jpg?x-oss-process=image/resize,m_fill,h_50,w_50" src="/static/imghw/default1.png" alt="AI Hentai Generator" /> </a> <div class="phpmain_tab2_mids_info"> <a href="https://www.php.cn/ja/ai/ai-hentai-generator" title="AI Hentai Generator" class="phpmain_tab2_mids_title"> <h3>AI Hentai Generator</h3> </a> <p>AIヘンタイを無料で生成します。</p> </div> </div> </div> <div class="phpgenera_Details_mainR3_more"> <a href="https://www.php.cn/ja/ai">もっと見る</a> </div> </div> </div> <script src="https://sw.php.cn/hezuo/cac1399ab368127f9b113b14eb3316d0.js" type="text/javascript"></script> <div class="phpgenera_Details_mainR4"> <div class="phpmain1_4R_readrank"> <div class="phpmain1_4R_readrank_top"> <img onerror="this.onerror=''; this.src='/static/imghw/default1.png'" onerror="this.onerror=''; this.src='/static/imghw/default1.png'" src="/static/imghw/hotarticle2.png" alt="" /> <h2>人気の記事</h2> </div> <div class="phpgenera_Details_mainR4_bottom"> <div class="phpgenera_Details_mainR4_bottoms"> <a href="https://www.php.cn/ja/faq/1796780570.html" title="R.E.P.O.説明されたエネルギー結晶と彼らが何をするか(黄色のクリスタル)" class="phpgenera_Details_mainR4_bottom_title">R.E.P.O.説明されたエネルギー結晶と彼らが何をするか(黄色のクリスタル)</a> <div class="phpgenera_Details_mainR4_bottoms_info"> <span>3週間前</span> <span>By 尊渡假赌尊渡假赌尊渡假赌</span> </div> </div> <div class="phpgenera_Details_mainR4_bottoms"> <a href="https://www.php.cn/ja/faq/1796780641.html" title="R.E.P.O.最高のグラフィック設定" class="phpgenera_Details_mainR4_bottom_title">R.E.P.O.最高のグラフィック設定</a> <div class="phpgenera_Details_mainR4_bottoms_info"> <span>3週間前</span> <span>By 尊渡假赌尊渡假赌尊渡假赌</span> </div> </div> <div class="phpgenera_Details_mainR4_bottoms"> <a href="https://www.php.cn/ja/faq/1796785841.html" title="アサシンのクリードシャドウズ:シーシェルリドルソリューション" class="phpgenera_Details_mainR4_bottom_title">アサシンのクリードシャドウズ:シーシェルリドルソリューション</a> <div class="phpgenera_Details_mainR4_bottoms_info"> <span>2週間前</span> <span>By DDD</span> </div> </div> <div class="phpgenera_Details_mainR4_bottoms"> <a href="https://www.php.cn/ja/faq/1796780520.html" title="R.E.P.O.誰も聞こえない場合はオーディオを修正する方法" class="phpgenera_Details_mainR4_bottom_title">R.E.P.O.誰も聞こえない場合はオーディオを修正する方法</a> <div class="phpgenera_Details_mainR4_bottoms_info"> <span>3週間前</span> <span>By 尊渡假赌尊渡假赌尊渡假赌</span> </div> </div> <div class="phpgenera_Details_mainR4_bottoms"> <a href="https://www.php.cn/ja/faq/1796779766.html" title="WWE 2K25:Myriseのすべてのロックを解除する方法" class="phpgenera_Details_mainR4_bottom_title">WWE 2K25:Myriseのすべてのロックを解除する方法</a> <div class="phpgenera_Details_mainR4_bottoms_info"> <span>4週間前</span> <span>By 尊渡假赌尊渡假赌尊渡假赌</span> </div> </div> </div> <div class="phpgenera_Details_mainR3_more"> <a href="https://www.php.cn/ja/article.html">もっと見る</a> </div> </div> </div> <div class="phpgenera_Details_mainR3"> <div class="phpmain1_4R_readrank"> <div class="phpmain1_4R_readrank_top"> <img onerror="this.onerror=''; this.src='/static/imghw/default1.png'" onerror="this.onerror=''; this.src='/static/imghw/default1.png'" src="/static/imghw/hottools2.png" alt="" /> <h2>ホットツール</h2> </div> <div class="phpgenera_Details_mainR3_bottom"> <div class="phpmain_tab2_mids_top"> <a href="https://www.php.cn/ja/toolset/development-tools/92" title="メモ帳++7.3.1" class="phpmain_tab2_mids_top_img"> <img onerror="this.onerror=''; this.src='/static/imghw/default1.png'" onerror="this.onerror=''; this.src='/static/imghw/default1.png'" class="lazy" data-src="https://img.php.cn/upload/manual/000/000/001/58ab96f0f39f7357.jpg?x-oss-process=image/resize,m_fill,h_50,w_72" src="/static/imghw/default1.png" alt="メモ帳++7.3.1" /> </a> <div class="phpmain_tab2_mids_info"> <a href="https://www.php.cn/ja/toolset/development-tools/92" title="メモ帳++7.3.1" class="phpmain_tab2_mids_title"> <h3>メモ帳++7.3.1</h3> </a> <p>使いやすく無料のコードエディター</p> </div> </div> <div class="phpmain_tab2_mids_top"> <a href="https://www.php.cn/ja/toolset/development-tools/93" title="SublimeText3 中国語版" class="phpmain_tab2_mids_top_img"> <img onerror="this.onerror=''; this.src='/static/imghw/default1.png'" onerror="this.onerror=''; this.src='/static/imghw/default1.png'" class="lazy" data-src="https://img.php.cn/upload/manual/000/000/001/58ab97a3baad9677.jpg?x-oss-process=image/resize,m_fill,h_50,w_72" src="/static/imghw/default1.png" alt="SublimeText3 中国語版" /> </a> <div class="phpmain_tab2_mids_info"> <a href="https://www.php.cn/ja/toolset/development-tools/93" title="SublimeText3 中国語版" class="phpmain_tab2_mids_title"> <h3>SublimeText3 中国語版</h3> </a> <p>中国語版、とても使いやすい</p> </div> </div> <div class="phpmain_tab2_mids_top"> <a href="https://www.php.cn/ja/toolset/development-tools/121" title="ゼンドスタジオ 13.0.1" class="phpmain_tab2_mids_top_img"> <img onerror="this.onerror=''; this.src='/static/imghw/default1.png'" onerror="this.onerror=''; this.src='/static/imghw/default1.png'" class="lazy" data-src="https://img.php.cn/upload/manual/000/000/001/58ab97ecd1ab2670.jpg?x-oss-process=image/resize,m_fill,h_50,w_72" src="/static/imghw/default1.png" alt="ゼンドスタジオ 13.0.1" /> </a> <div class="phpmain_tab2_mids_info"> <a href="https://www.php.cn/ja/toolset/development-tools/121" title="ゼンドスタジオ 13.0.1" class="phpmain_tab2_mids_title"> <h3>ゼンドスタジオ 13.0.1</h3> </a> <p>強力な PHP 統合開発環境</p> </div> </div> <div class="phpmain_tab2_mids_top"> <a href="https://www.php.cn/ja/toolset/development-tools/469" title="ドリームウィーバー CS6" class="phpmain_tab2_mids_top_img"> <img onerror="this.onerror=''; this.src='/static/imghw/default1.png'" onerror="this.onerror=''; this.src='/static/imghw/default1.png'" class="lazy" data-src="https://img.php.cn/upload/manual/000/000/001/58d0e0fc74683535.jpg?x-oss-process=image/resize,m_fill,h_50,w_72" src="/static/imghw/default1.png" alt="ドリームウィーバー CS6" /> </a> <div class="phpmain_tab2_mids_info"> <a href="https://www.php.cn/ja/toolset/development-tools/469" title="ドリームウィーバー CS6" class="phpmain_tab2_mids_title"> <h3>ドリームウィーバー CS6</h3> </a> <p>ビジュアル Web 開発ツール</p> </div> </div> <div class="phpmain_tab2_mids_top"> <a href="https://www.php.cn/ja/toolset/development-tools/500" title="SublimeText3 Mac版" class="phpmain_tab2_mids_top_img"> <img onerror="this.onerror=''; this.src='/static/imghw/default1.png'" onerror="this.onerror=''; this.src='/static/imghw/default1.png'" class="lazy" data-src="https://img.php.cn/upload/manual/000/000/001/58d34035e2757995.png?x-oss-process=image/resize,m_fill,h_50,w_72" src="/static/imghw/default1.png" alt="SublimeText3 Mac版" /> </a> <div class="phpmain_tab2_mids_info"> <a href="https://www.php.cn/ja/toolset/development-tools/500" title="SublimeText3 Mac版" class="phpmain_tab2_mids_title"> <h3>SublimeText3 Mac版</h3> </a> <p>神レベルのコード編集ソフト(SublimeText3)</p> </div> </div> </div> <div class="phpgenera_Details_mainR3_more"> <a href="https://www.php.cn/ja/ai">もっと見る</a> </div> </div> </div> <div class="phpgenera_Details_mainR4"> <div class="phpmain1_4R_readrank"> <div class="phpmain1_4R_readrank_top"> <img onerror="this.onerror=''; this.src='/static/imghw/default1.png'" onerror="this.onerror=''; this.src='/static/imghw/default1.png'" src="/static/imghw/hotarticle2.png" alt="" /> <h2>ホットトピック</h2> </div> <div class="phpgenera_Details_mainR4_bottom"> <div class="phpgenera_Details_mainR4_bottoms"> <a href="https://www.php.cn/ja/faq/gmailyxdlrkzn" title="Gmailメールのログイン入り口はどこですか?" class="phpgenera_Details_mainR4_bottom_title">Gmailメールのログイン入り口はどこですか?</a> <div class="phpgenera_Details_mainR4_bottoms_info"> <div class="phpgenera_Details_mainR4_bottoms_infos"> <img src="/static/imghw/eyess.png" alt="" /> <span>7478</span> </div> <div class="phpgenera_Details_mainR4_bottoms_infos"> <img src="/static/imghw/tiezi.png" alt="" /> <span>15</span> </div> </div> </div> <div class="phpgenera_Details_mainR4_bottoms"> <a href="https://www.php.cn/ja/faq/cakephp-tutor" title="CakePHP チュートリアル" class="phpgenera_Details_mainR4_bottom_title">CakePHP チュートリアル</a> <div class="phpgenera_Details_mainR4_bottoms_info"> <div class="phpgenera_Details_mainR4_bottoms_infos"> <img src="/static/imghw/eyess.png" alt="" /> <span>1377</span> </div> <div class="phpgenera_Details_mainR4_bottoms_infos"> <img src="/static/imghw/tiezi.png" alt="" /> <span>52</span> </div> </div> </div> <div class="phpgenera_Details_mainR4_bottoms"> <a href="https://www.php.cn/ja/faq/steamdzhmcssmgs" title="Steamのアカウント名の形式は何ですか" class="phpgenera_Details_mainR4_bottom_title">Steamのアカウント名の形式は何ですか</a> <div class="phpgenera_Details_mainR4_bottoms_info"> <div class="phpgenera_Details_mainR4_bottoms_infos"> <img src="/static/imghw/eyess.png" alt="" /> <span>77</span> </div> <div class="phpgenera_Details_mainR4_bottoms_infos"> <img src="/static/imghw/tiezi.png" alt="" /> <span>11</span> </div> </div> </div> <div class="phpgenera_Details_mainR4_bottoms"> <a href="https://www.php.cn/ja/faq/winactivationkeyper" title="Win11 Activation Key Permanent" class="phpgenera_Details_mainR4_bottom_title">Win11 Activation Key Permanent</a> <div class="phpgenera_Details_mainR4_bottoms_info"> <div class="phpgenera_Details_mainR4_bottoms_infos"> <img src="/static/imghw/eyess.png" alt="" /> <span>50</span> </div> <div class="phpgenera_Details_mainR4_bottoms_infos"> <img src="/static/imghw/tiezi.png" alt="" /> <span>19</span> </div> </div> </div> <div class="phpgenera_Details_mainR4_bottoms"> <a href="https://www.php.cn/ja/faq/newyorktimesdailybrief" title="NYTの接続はヒントと回答です" class="phpgenera_Details_mainR4_bottom_title">NYTの接続はヒントと回答です</a> <div class="phpgenera_Details_mainR4_bottoms_info"> <div class="phpgenera_Details_mainR4_bottoms_infos"> <img src="/static/imghw/eyess.png" alt="" /> <span>19</span> </div> <div class="phpgenera_Details_mainR4_bottoms_infos"> <img src="/static/imghw/tiezi.png" alt="" /> <span>33</span> </div> </div> </div> </div> <div class="phpgenera_Details_mainR3_more"> <a href="https://www.php.cn/ja/faq/zt">もっと見る</a> </div> </div> </div> </div> </div> <div class="Article_Details_main2"> <div class="phpgenera_Details_mainL4"> <div class="phpmain1_2_top"> <a href="javascript:void(0);" class="phpmain1_2_top_title">Related knowledge<img src="/static/imghw/index2_title2.png" alt="" /></a> </div> <div class="phpgenera_Details_mainL4_info"> <div class="phphistorical_Version2_mids"> <a href="https://www.php.cn/ja/faq/637582.html" title="Huawei GT3 ProとGT4の違いは何ですか?" class="phphistorical_Version2_mids_img"> <img onerror="this.onerror=''; this.src='/static/imghw/default1.png'" src="/static/imghw/default1.png" class="lazy" data-src="https://img.php.cn/upload/article/000/465/014/170383126488259.png?x-oss-process=image/resize,m_fill,h_207,w_330" alt="Huawei GT3 ProとGT4の違いは何ですか?" /> </a> <a href="https://www.php.cn/ja/faq/637582.html" title="Huawei GT3 ProとGT4の違いは何ですか?" class="phphistorical_Version2_mids_title">Huawei GT3 ProとGT4の違いは何ですか?</a> <span class="Articlelist_txts_time">Dec 29, 2023 pm 02:27 PM</span> <p class="Articlelist_txts_p">多くのユーザーはスマートウォッチを選ぶときにファーウェイブランドを選択しますが、その中でもファーウェイ GT3pro と GT4 は非常に人気のある選択肢であり、多くのユーザーはファーウェイ GT3pro と GT4 の違いに興味を持っています。 Huawei GT3pro と GT4 の違いは何ですか? 1. 外観 GT4: 46mm と 41mm、材質はガラスミラー + ステンレススチールボディ + 高解像度ファイバーバックシェルです。 GT3pro: 46.6mm および 42.9mm、材質はサファイアガラス + チタンボディ/セラミックボディ + セラミックバックシェルです。 2. 健全な GT4: 最新の Huawei Truseen5.5+ アルゴリズムを使用すると、結果はより正確になります。 GT3pro: ECG 心電図と血管と安全性を追加</p> </div> <div class="phphistorical_Version2_mids"> <a href="https://www.php.cn/ja/faq/680434.html" title="Linux システムの PATH 環境変数を設定する手順" class="phphistorical_Version2_mids_img"> <img onerror="this.onerror=''; this.src='/static/imghw/default1.png'" src="/static/imghw/default1.png" class="lazy" data-src="https://img.php.cn/upload/article/000/465/014/170824922557544.jpg?x-oss-process=image/resize,m_fill,h_207,w_330" alt="Linux システムの PATH 環境変数を設定する手順" /> </a> <a href="https://www.php.cn/ja/faq/680434.html" title="Linux システムの PATH 環境変数を設定する手順" class="phphistorical_Version2_mids_title">Linux システムの PATH 環境変数を設定する手順</a> <span class="Articlelist_txts_time">Feb 18, 2024 pm 05:40 PM</span> <p class="Articlelist_txts_p">Linux システムで PATH 環境変数を設定する方法 Linux システムでは、PATH 環境変数を使用して、システムがコマンド ラインで実行可能ファイルを検索するパスを指定します。 PATH 環境変数を正しく設定すると、任意の場所でシステム コマンドやカスタム コマンドを実行できるようになります。この記事では、Linux システムで PATH 環境変数を設定する方法と詳細なコード例を紹介します。現在の PATH 環境変数を表示する ターミナルで次のコマンドを実行して、現在の PATH 環境変数を表示します: echo$P</p> </div> <div class="phphistorical_Version2_mids"> <a href="https://www.php.cn/ja/faq/587704.html" title="機能とはどういう意味ですか?" class="phphistorical_Version2_mids_img"> <img onerror="this.onerror=''; this.src='/static/imghw/default1.png'" src="/static/imghw/default1.png" class="lazy" data-src="https://img.php.cn/upload/article/202308/04/2023080410293353750.jpg?x-oss-process=image/resize,m_fill,h_207,w_330" alt="機能とはどういう意味ですか?" /> </a> <a href="https://www.php.cn/ja/faq/587704.html" title="機能とはどういう意味ですか?" class="phphistorical_Version2_mids_title">機能とはどういう意味ですか?</a> <span class="Articlelist_txts_time">Aug 04, 2023 am 10:33 AM</span> <p class="Articlelist_txts_p">ファンクションとは、関数を意味します。これは、特定の関数を備えた再利用可能なコード ブロックです。プログラムの基本コンポーネントの 1 つです。入力パラメータを受け取り、特定の操作を実行し、結果を返すことができます。その目的は、再利用可能なコード ブロックをカプセル化することです。コードの再利用性と保守性を向上させるコード。</p> </div> <div class="phphistorical_Version2_mids"> <a href="https://www.php.cn/ja/faq/595687.html" title="修正: Windows 11 で Snipping ツールが機能しない" class="phphistorical_Version2_mids_img"> <img onerror="this.onerror=''; this.src='/static/imghw/default1.png'" src="/static/imghw/default1.png" class="lazy" data-src="https://img.php.cn/upload/article/000/887/227/169284169836669.jpg?x-oss-process=image/resize,m_fill,h_207,w_330" alt="修正: Windows 11 で Snipping ツールが機能しない" /> </a> <a href="https://www.php.cn/ja/faq/595687.html" title="修正: Windows 11 で Snipping ツールが機能しない" class="phphistorical_Version2_mids_title">修正: Windows 11 で Snipping ツールが機能しない</a> <span class="Articlelist_txts_time">Aug 24, 2023 am 09:48 AM</span> <p class="Articlelist_txts_p">Windows 11 で Snipping Tool が機能しない理由 問題の根本原因を理解すると、適切な解決策を見つけるのに役立ちます。 Snipping Tool が正しく動作しない主な理由は次のとおりです。 フォーカス アシスタントがオンになっている: これにより、Snipping Tool が開かなくなります。破損したアプリケーション: 起動時にスニッピング ツールがクラッシュする場合は、破損している可能性があります。古いグラフィック ドライバー: 互換性のないドライバーは、スニッピング ツールに干渉する可能性があります。他のアプリケーションからの干渉: 実行中の他のアプリケーションが Snipping Tool と競合する可能性があります。証明書の有効期限が切れています: アップグレード プロセス中のエラーにより、この問題が発生する可能性があります。これらの簡単な解決策は、ほとんどのユーザーに適しており、特別な技術知識は必要ありません。 1. Windows および Microsoft Store アプリを更新する</p> </div> <div class="phphistorical_Version2_mids"> <a href="https://www.php.cn/ja/faq/601740.html" title="パス環境変数を設定する方法" class="phphistorical_Version2_mids_img"> <img onerror="this.onerror=''; this.src='/static/imghw/default1.png'" src="/static/imghw/default1.png" class="lazy" data-src="https://img.php.cn/upload/article/202309/04/2023090411532084533.jpg?x-oss-process=image/resize,m_fill,h_207,w_330" alt="パス環境変数を設定する方法" /> </a> <a href="https://www.php.cn/ja/faq/601740.html" title="パス環境変数を設定する方法" class="phphistorical_Version2_mids_title">パス環境変数を設定する方法</a> <span class="Articlelist_txts_time">Sep 04, 2023 am 11:53 AM</span> <p class="Articlelist_txts_p">パス環境変数を設定する方法: 1. Windows システムでは、[システムのプロパティ] を開き、[プロパティ] オプションをクリックし、[システムの詳細設定] をクリックし、[システムのプロパティ] ウィンドウで [詳細] タブを選択します。 「環境変数」ボタンをクリックし、「パス」を見つけてクリックして編集し、保存します。 2. Linux システムの場合は、ターミナルを開き、bash 構成ファイルを開き、ファイルの最後に「export PATH=$PATH: file path」を追加します。ファイルを保存して保存します; 3. MacOS システムの場合、操作は上記と同じです。</p> </div> <div class="phphistorical_Version2_mids"> <a href="https://www.php.cn/ja/faq/584743.html" title="iPhoneでApp Storeに接続できないエラーを修正する方法" class="phphistorical_Version2_mids_img"> <img onerror="this.onerror=''; this.src='/static/imghw/default1.png'" src="/static/imghw/default1.png" class="lazy" data-src="https://img.php.cn/upload/article/000/887/227/169059012999730.jpg?x-oss-process=image/resize,m_fill,h_207,w_330" alt="iPhoneでApp Storeに接続できないエラーを修正する方法" /> </a> <a href="https://www.php.cn/ja/faq/584743.html" title="iPhoneでApp Storeに接続できないエラーを修正する方法" class="phphistorical_Version2_mids_title">iPhoneでApp Storeに接続できないエラーを修正する方法</a> <span class="Articlelist_txts_time">Jul 29, 2023 am 08:22 AM</span> <p class="Articlelist_txts_p">パート 1: 最初のトラブルシューティング手順 Apple のシステムステータスを確認する: 複雑な解決策を掘り下げる前に、基本から始めましょう。問題はデバイスにあるのではなく、Apple のサーバーがダウンしている可能性があります。 Apple のシステム ステータス ページにアクセスして、AppStore が適切に動作しているかどうかを確認してください。問題があれば、Apple が修正してくれるのを待つしかありません。インターネット接続を確認します。「AppStore に接続できません」問題は接続不良が原因である場合があるため、安定したインターネット接続があることを確認してください。 Wi-Fi とモバイル データを切り替えるか、ネットワーク設定をリセットしてみてください ([一般] &gt; [リセット] &gt; [ネットワーク設定のリセット] &gt; [設定])。 iOS バージョンを更新します。</p> </div> <div class="phphistorical_Version2_mids"> <a href="https://www.php.cn/ja/faq/180076.html" title="php提交表单通过后,弹出的对话框怎样在当前页弹出,该如何解决" class="phphistorical_Version2_mids_img"> <img onerror="this.onerror=''; this.src='/static/imghw/default1.png'" src="/static/imghw/default1.png" class="lazy" data-src="https://img.php.cn/upload/article/202311/29/2023112910200043559.jpg?x-oss-process=image/resize,m_fill,h_207,w_330" alt="php提交表单通过后,弹出的对话框怎样在当前页弹出,该如何解决" /> </a> <a href="https://www.php.cn/ja/faq/180076.html" title="php提交表单通过后,弹出的对话框怎样在当前页弹出,该如何解决" class="phphistorical_Version2_mids_title">php提交表单通过后,弹出的对话框怎样在当前页弹出,该如何解决</a> <span class="Articlelist_txts_time">Jun 13, 2016 am 10:23 AM</span> <p class="Articlelist_txts_p">php提交表单通过后,弹出的对话框怎样在当前页弹出php提交表单通过后,弹出的对话框怎样在当前页弹出而不是在空白页弹出?想实现这样的效果:而不是空白页弹出:------解决方案--------------------如果你的验证用PHP在后端,那么就用Ajax;仅供参考:HTML code</p> </div> <div class="phphistorical_Version2_mids"> <a href="https://www.php.cn/ja/faq/600668.html" title="Python の「enumerate()」関数の目的は何ですか?" class="phphistorical_Version2_mids_img"> <img onerror="this.onerror=''; this.src='/static/imghw/default1.png'" src="/static/imghw/default1.png" class="lazy" data-src="https://img.php.cn/upload/article/000/887/227/169353894788159.jpg?x-oss-process=image/resize,m_fill,h_207,w_330" alt="Python の「enumerate()」関数の目的は何ですか?" /> </a> <a href="https://www.php.cn/ja/faq/600668.html" title="Python の「enumerate()」関数の目的は何ですか?" class="phphistorical_Version2_mids_title">Python の「enumerate()」関数の目的は何ですか?</a> <span class="Articlelist_txts_time">Sep 01, 2023 am 11:29 AM</span> <p class="Articlelist_txts_p">この記事では、Python の enumerate() 関数と「enumerate()」関数の目的について学びます。 enumerate() 関数とは何ですか? Python の enumerate() 関数は、データ コレクションをパラメータとして受け取り、列挙オブジェクトを返します。列挙オブジェクトはキーと値のペアとして返されます。キーは各項目に対応するインデックス、値は項目です。構文 enumerate(iterable,start) パラメータ iterable - 渡されたデータ コレクションは、iterablestart と呼ばれる列挙オブジェクトとして返すことができます。 - 名前が示すように、列挙オブジェクトの開始インデックスは start によって定義されます。無視したら</p> </div> </div> <a href="https://www.php.cn/ja/php-tutorials.html" class="phpgenera_Details_mainL4_botton"> <span>See all articles</span> <img src="/static/imghw/down_right.png" alt="" /> </a> </div> </div> </div> </main> <footer> <div class="footer"> <div class="footertop"> <img src="/static/imghw/logo.png" alt=""> <p>福祉オンライン PHP トレーニング,PHP 学習者の迅速な成長を支援します!</p> </div> <div class="footermid"> <a href="https://www.php.cn/ja/about/us.html">私たちについて</a> <a href="https://www.php.cn/ja/about/disclaimer.html">免責事項</a> <a href="https://www.php.cn/ja/update/article_0_1.html">Sitemap</a> </div> <div class="footerbottom"> <p> © php.cn All rights reserved </p> </div> </div> </footer> <input type="hidden" id="verifycode" value="/captcha.html"> <script>layui.use(['element', 'carousel'], function () {var element = layui.element;$ = layui.jquery;var carousel = layui.carousel;carousel.render({elem: '#test1', width: '100%', height: '330px', arrow: 'always'});$.getScript('/static/js/jquery.lazyload.min.js', function () {$("img").lazyload({placeholder: "/static/images/load.jpg", effect: "fadeIn", threshold: 200, skip_invisible: false});});});</script> <script src="/static/js/common_new.js"></script> <script type="text/javascript" src="/static/js/jquery.cookie.js?1744495877"></script> <script src="https://vdse.bdstatic.com//search-video.v1.min.js"></script> <link rel='stylesheet' id='_main-css' href='/static/css/viewer.min.css?2' type='text/css' media='all' /> <script type='text/javascript' src='/static/js/viewer.min.js?1'></script> <script type='text/javascript' src='/static/js/jquery-viewer.min.js'></script> <script type="text/javascript" src="/static/js/global.min.js?5.5.53"></script> <script> var _paq = window._paq = window._paq || []; /* tracker methods like "setCustomDimension" should be called before "trackPageView" */ _paq.push(['trackPageView']); _paq.push(['enableLinkTracking']); (function () { var u = "https://tongji.php.cn/"; _paq.push(['setTrackerUrl', u + 'matomo.php']); _paq.push(['setSiteId', '9']); var d = document, g = d.createElement('script'), s = d.getElementsByTagName('script')[0]; g.async = true; g.src = u + 'matomo.js'; s.parentNode.insertBefore(g, s); })(); </script> <script> // top layui.use(function () { var util = layui.util; util.fixbar({ on: { mouseenter: function (type) { layer.tips(type, this, { tips: 4, fixed: true, }); }, mouseleave: function (type) { layer.closeAll("tips"); }, }, }); }); document.addEventListener("DOMContentLoaded", (event) => { // 定义一个函数来处理滚动链接的点击事件 function setupScrollLink(scrollLinkId, targetElementId) { const scrollLink = document.getElementById(scrollLinkId); const targetElement = document.getElementById(targetElementId); if (scrollLink && targetElement) { scrollLink.addEventListener("click", (e) => { e.preventDefault(); // 阻止默认链接行为 targetElement.scrollIntoView({ behavior: "smooth" }); // 平滑滚动到目标元素 }); } else { console.warn( `Either scroll link with ID '${scrollLinkId}' or target element with ID '${targetElementId}' not found.` ); } } // 使用该函数设置多个滚动链接 setupScrollLink("Article_Details_main1L2s_1", "article_main_title1"); setupScrollLink("Article_Details_main1L2s_2", "article_main_title2"); setupScrollLink("Article_Details_main1L2s_3", "article_main_title3"); setupScrollLink("Article_Details_main1L2s_4", "article_main_title4"); setupScrollLink("Article_Details_main1L2s_5", "article_main_title5"); setupScrollLink("Article_Details_main1L2s_6", "article_main_title6"); // 可以继续添加更多的滚动链接设置 }); window.addEventListener("scroll", function () { var fixedElement = document.getElementById("Article_Details_main1Lmain"); var scrollTop = window.scrollY || document.documentElement.scrollTop; // 兼容不同浏览器 var clientHeight = window.innerHeight || document.documentElement.clientHeight; // 视口高度 var scrollHeight = document.documentElement.scrollHeight; // 页面总高度 // 计算距离底部的距离 var distanceToBottom = scrollHeight - scrollTop - clientHeight; // 当距离底部小于或等于300px时,取消固定定位 if (distanceToBottom <= 980) { fixedElement.classList.remove("Article_Details_main1Lmain"); fixedElement.classList.add("Article_Details_main1Lmain_relative"); } else { // 否则,保持固定定位 fixedElement.classList.remove("Article_Details_main1Lmain_relative"); fixedElement.classList.add("Article_Details_main1Lmain"); } }); </script> </body> </html>