[PHP-users 31296] \記号のエスケープについて
Mihashi
pml_384 @ yahoo.co.jp
2007年 1月 22日 (月) 15:59:03 JST
$B$O$8$a$^$7$F!#;066$H?=$7$^$9!#(B
$B0J2<$N%5%s%W%k$r<B9T$7$?:]$KM=4|$;$L%(%9%1!<%W$,9T$o$l$F!"(BJavaScript$B$N9=J8%(%i!<$H$J$C$F$7$^$$$^$9!#(B
$B4D6- @ _Dj$NLdBj$@$H;W$&$N$G$9$,!"8+Ev$,$D$+$J$$$?$a!"$465<x59$7$/$*4j$$CW$7$^$9!#(B
// $B%5%s%W%k(B
<?php
Session_Start();
$rtnStr = <<< RTN_STR
<HTML>
<HEAD>
<META http-equiv="Content-Type" content="text/html; charset=EUC-JP">
<TITLE></TITLE>
<SCRIPT language="JavaScript">
<!--
function chg(typ){
if( typ == 1 ){
lineStr = "<INPUT type='text' name='In_Text' value='tst'>"
+ "<A href='javascript:chg(2)'>CLEAR</A>";
}else if( typ == 2 ){
lineStr = "<INPUT type=\"text\" name=\"In_Text\" value=\"\">"
+ "<A href=\"javascript:chg(1)\">SET</A>";
}
document.getElementById( 'TEST' ).innerHTML = lineStr;
}
//-->
</SCRIPT>
</HEAD>
<BODY>
<FORM name="MainForm" method="post">
<INPUT type="hidden" name="ChrSetChkStr" value="$B?}$N1}Mh(B">
<TABLE width="505" border="0" cellpadding="0" cellspacing="0">
<TR>
<TD ID="TEST">
<INPUT type="text" name="In_Text" value="">
<A href="javascript:chg(1)">SET</A>
</TD>
</TR>
</TABLE>
</FORM>
</BODY>
</HTML>
RTN_STR;
echo( $rtnStr );
?>
//
$B%(%9%1!<%WFbMF(B(JavaScript$B$N(Btyp=2$B$N5-=RItJ,$G5/$3$j$^$9!#(B)
$B-!(B \ $B"M(B "\" // $BN>%5%$%I$K!X(B"$B!Y$,IU2C$5$l$^$9(B
$B-"(B \ $B"M(B "\?PHPSESSID=c4c8$B!&!&!&(B" // $B:8B&$K!X(B"$B!Y!"1&B&$K!X(B?PHPSESSID=$BCM(B"$B!Y$,IU2C$5$l$^$9(B
$B-!$O(B<INPUT>$B%?%0Fb$G!":G=i$K5-=R$5$l$F$$$k(B\$B5-9f$KBP$7$F!"%(%9%1!<%W$5$l$^$9!#(B
$BNc!K(B lineStr = "<INPUT type="\""text\" name=\"In_Text\" value=\"\">"
~ ~
$B",$3$NItJ,(B
$B-"$O(B<A>$B%?%0Fb$N!X(Bhref=$B!Y$NCf$N(B\$B5-9f$r%(%9%1!<%W$7$F$$$^$9!#(B
$BNc!K(B + "<A href="\?PHPSESSID=$BCM(B""javascript:chg(1)\">SET</A>";
~ ~~~~~~~~~~~~~~
$B",$3$NItJ,(B
$B0J2<$N=hM}$r9T$&$H!"%(%9%1!<%W$O9T$o$l$^$;$s(B
$B"((Btyp==1$B$N5-:\J}K!$@$H!"%(%i!<$r2sHr$9$k$3$H$O2DG=$G$9!#(B
$B"((BJavaScript$B%(%i!<$,I=<($5$l$F$$$k;~$K!"%V%i%&%6$N99?7%\%?%s$r2!$9$H%(%9%1!<%W$O$5$l$^$;$s!#(B
$B"(0lEY%5%s%W%k$rI=<($7$?2hLL$G!":FEYI=<($r$9$k$H!"%(%9%1!<%W$O$5$l$^$;$s!#(B
$B"((BSession_Start()$B$r9T$o$J$$(B
$B<B9T4D6--!(B
PHP Version 4.2.3
Apache Version Apache/1.3.33
$B0J>e!"59$7$/$*4j$$CW$7$^$9!#(B
--------------------------------------
Start Yahoo! Auction now! Check out the cool campaign
http://pr.mail.yahoo.co.jp/auction/
PHP-users メーリングリストの案内