|
PHP FAQ
PHP Articles
PHP Help
Bulletin Board
PHP Manual (NEW!)
First Time PHP'ers
Help with programming
Sql assignment help
PHP Homework Help
|
|
using array to define problem |
Author: (67.71.135.---)
Date: 02-26-04 15:17
Hello everybody:
I'm learning PHP now.
Here are two loop, I don't know what's wrong here.
Please help.
script 1:
for($tempi=1;$tempi<=60; $tempi++){
define('_MI_HIWEEDBLOCKS_BNAME'.$tempi,'group'.$tempi);};
define('_MI_HIWEEDBLOCKS_BNAME61','otherthings');
script 2:
for($tempi=1;$tempi<=60;$tempi++){
$modversion['blocks'][$tempi]['file'] = "latest_of_topic.php";
$modversion['blocks'][$tempi]['name'] = '_MI_HIWEEDBLOCKS_BNAME$tempi';
$modversion['blocks'][$tempi]['description'] = "Shows the last x articles of a topic";
$modversion['blocks'][$tempi]['show_func'] = "latest_of_topic_show";
$modversion['blocks'][$tempi]['edit_func'] = "latest_of_topic_edit";
$modversion['blocks'][$tempi]['options'] = "News|10|1";
}
$modversion['blocks'][61]['file'] = "random_partner.php";
$modversion['blocks'][61]['name'] = _MI_HIWEEDBLOCKS_BNAME61;
$modversion['blocks'][61]['description'] = "Shows a block with 1 random partner banner";
$modversion['blocks'][61]['show_func'] = "random_partners_show";
Thanks a lot.
Best regards
David
|
|
Topics |
Author |
Date |
  |
using array to define problem new |
|
David |
02-26-04 15:17 |
|
bastien |
02-26-04 15:59 |
|
David |
02-26-04 16:12 |
|
john |
04-12-04 19:37 |
|