¸Ó¸®¸»
º¥Ä¡¸¶Å©
¼³¸í¼ 1
¼³¸í¼ 2
¼³¸í¼ 3
¼³¸í¼ 4
¼³¸í¼ 5
·¹ÆÛ·±½º
´Ù¿î·Îµå
¡Þ °Ô½ÃÆÇ
±Û¾´»ç¶÷
Áø¼±
±Û¾´½Ã°£
2010³â 3¿ù 6ÀÏ ¿ÀÈÄ 3½Ã 9ºÐ 34ÃÊ
Á¦¸ñ
Áßø·çÇÁ¿¡¼ ÅÛÇø´ºÐ±âÇϴµ¥ °ªÀÌ ÀÌ»óÇÏ°Ô ³ª¿Í¿ä ¹æ¹ýÀÌ ¾øÀ»±î¿ä?
index.php¿¡¼
$ary ´Â ¾Æ·¡Ã³·³µÇÀÖ°í
Array
(
[0] => Array
(
[name] => main_hot_mamul_list
[display_type] => gallery
[sub_mamul_list] => Array
(
[0] => Array
(
[div_id] => sum_hot_1
[div_location] => margin-left:110px;
[end_icon] => n
)
)
)
[1] => Array
(
[name] => main_item_mamul_list
[display_type] => list
[sub_mamul_list] => Array
(
[0] => Array
(
[div_id] => sum_hot_1
[div_location] => margin-left:110px;
[end_icon] => n
)
)
)
)
$tpl->assign("data_list" , $ary);
$tpl->define("tpl_list" , "list.html" ); // ¸®½ºÆ®Çü
$tpl->define("tpl_gallery" , "gallery1.html" ); // °¶·¯¸®Çü
ÅÛÇø´ÈÀÏ(index.html)¿¡¼
{@ data_list}
{? .display_type == "list"}{*¸®½ºÆ®Çü*}
{#tpl_list}
{: .display_type == "gallery"}{*°¶·¯¸®Çü1*}
{#tpl_gallery}
{/}
{/}
ÀÌ·¸°Ô È£ÃâÇϴµ¥¿ä.
display_type ¿¡ µû¶ó¼ 2°³ÀÇ ÅÛÇø´ÈÀÏÀ» ºÐ±â ÇßÀ¸¸éÇϴµ¥¿ä.
tpl_list
tpl_gallery
2°¡Áö°¡ º°µµ·Î ÅÛÇø´À¸·Î Á¤ÀǵÇÀִµ¥¿ä.
Á¤»óÀûÀ¸·Î º¸¿©ÁöÁö°¡ ¾Ê³×¿ä.
tpl_list ¿¡¼´Â
<!-- ÄÁÅÙÃ÷ -->
<table width="100%" border="0" cellspacing="0" cellpadding="0">
{@ sub_mamul_list}
<tr align = center>
<td >{..div_id}</td>
<td >{..end_icon}</td>
</tr>
{/}
</table>
ÀÌ·¸°Ô È£ÃâÇÏ¸é ¿¡·¯°¡ ³ª³×¿ä.
À̺κÐÀ»
{@ data_list}
{? .display_type == "list"}{*¸®½ºÆ®Çü*}
<table width="100%" border="0" cellspacing="0" cellpadding="0">
{@ sub_mamul_list}
<tr align = center>
<td >{..div_id}</td>
<td >{..end_icon}</td>
</tr>
{/}
</table>
{: .display_type == "gallery"}{*°¶·¯¸®Çü1*}
{#tpl_gallery}
{/}
{/}
ÀÌ·¸°Ô È£ÃâÇϸé Á¤»óÀÛµ¿Çϰŵç¿ä.
Àú°Å¸¦ ´Ù¸¥ ºÎºÐ¿¡¼ ¸¹ÀÌ »ç¿ëÇØ¾ßµÇ¼
º°µµ·Î Á¤ÀÇÇØ¼ È£ÃâÇÏ°í ½ÍÀºµ¥ ¹æ¹ýÀÌ ¾øÀ»±î¿ä??
¿ïÆ®¶ó
ÅÛÇø´»ó¿¡¼ º¹ÀâÇÏ°Ô ºÐ±â°¡ ¸¹´Ù´Â °ÍÀº phpÄÚµå ºÎºÐ°ú µðÀÚÀÎ ¿µ¿ªÀ» ºÐ¸®ÇÏ·Á´Â ÅÛÇø´ÀÇ Àǵµ¿Í´Â ¾à°£ ¸ÂÁö ¾Ê´Â´Ù´Â »ý°¢ÀÌ µé¾î¿ä..°¡±ÞÀûÀÌ¸é ºÐ±âÁ¶°ÇÀº php»ó¿¡¼ ÇØ°áÇÑµÚ Ãâ·ÂÇÏ´Â ¹æ¹ýÀ» ½áº¸½Ã¸é ÀǿܷΠ¹®Á¦°¡ ½±°Ô ÇØ°áµË´Ï´Ù...Áö±ØÈ÷ °³ÀÎÀûÀÎ »ý°¢ÀÔ´Ï´Ù...^^
10-05-30 01:50
À̸§
ºñ¹Ð¹øÈ£
2003-03-03 ~