1
xavhmn
problem with the module download3000
  • 2007/1/31 22:19

  • xavhmn

  • Just popping in

  • Posts: 23

  • Since: 2004/11/16


good evening, I discovered this small module cool, I am translating it in french, but I have three errors which

I do not manage to correct these three errors are as follows:
Notice: Undefined offset: 2 in file ....modules/download3000/index.php line 268

Notice: Undefined offset: 1 in file ....modules/download3000/index.php line 268


Notice: Undefined offset: 150 in file ....modules/download3000/index.php line 312


function ShowAll() {
   global 
$d3000_url$affiliate_id$module_name$bgcolor2;
   
$lines ReadContent("$d3000_url/rss/rss_d3000.php?op=showall");
   
// include_once(XOOPS_ROOT_PATH.'/header.php');
   
   
NavBar(_MD_DOWNLOAD3000_CATEGORIES);
   echo 
"n";
   
$oldcat "";
   
$i 0;
   
$cnt 0;
   foreach (
$lines as $line) {
      if (
substr($line,0,1) == "%") {
        
$line substr($line,1,-1);
        list(
$a[$i][1],$a[$i][3]) = explode("|",$line);
        
$a[$i][0] = "";
        
$catname $a[$i][1];
        
$a[$i][2] = "";
      } else {
           [
b][color=FF3300]list($a[$i][2],$a[$i][0],$a[$i][3]) = explode("|",$line); [/color][/b]
           
$a[$i][1] = $catname;
      }
      
$i++;
   }

   echo 
"";
   
$base round(count($a)/2);
   
$i 0;

   while (
$cnt 5) {
     if (
$oldcat != $a[$i][1]) {
       
$cnt++;
       if (
$cnt == 5) break;
       echo 
"images/back_sb.gif" width="213" height="18">";
       if (
$cnt != 1) echo "";
       echo 
".$a[$i][3]."'>Arial,verdana" size="3" color="#000000">".$a[$i][1]."";
       
$oldcat $a[$i][1];
     }
     echo 
"n";
     echo 
"index.php?op=showarticles&id=".$a[$i][0]."&from=1">".$a[$i][2]."n"
         
."";
     
$i++;
   }
   echo 
"";
   
$y count($a) - round(count($a)/2);
   
$cnt 0;
   while (
$cnt 4) {
     if (
$oldcat != $a[$i][1]) {
       
$cnt++;
       if (
$cnt == 4) break;
       echo 
"images/back_sb.gif" width="213" height="18">";
       if (
$cnt != 1) echo "";
       echo 
".$a[$i][3]."'>Arial,verdana" size="3" color="#000000">".$a[$i][1]."";
       
$oldcat $a[$i][1];
     }
     echo 
"n";
     echo 
"index.php?op=showarticles&id=".$a[$i][0]."&from=1">".$a[$i][2]."n"
         
."";
     
$i++;
   }
   
$cnt 0;
   echo 
"";
   while (
$cnt 4) {
     [
b][color=FF9900]if ($oldcat != $a[$i][1]) {[/color][/b]
       
$cnt++;
       if (
$cnt == 4) break;
       echo 
"images/back_sb.gif" width="213" height="18">";
       if (
$cnt != 1) echo "";
       echo 
".$a[$i][3]."'>Arial,verdana" size="3" color="#000000">".$a[$i][1]."";
       
$oldcat $a[$i][1];
     }
     echo 
"n";
     echo 
"index.php?op=showarticles&id=".$a[$i][0]."&from=1">".$a[$i][2]."n"
         
."";
     
$i++;
   }
   echo 
"";
   echo 
"n";
   
// DO NOT REMOVE THE FOLLOWING POWERED BY LINE. YOU'RE NOT ALLOWED TO REMOVE NOR EDIT THIS.
   // PLAY FAIR AND SUPPORT THE DEVELOPMENT, PLEASE!
   
PoweredBy();
   
   
// include_once(XOOPS_ROOT_PATH."/footer.php");
}
//#############################################################################
function showcategory($id) {
global 
$d3000_url,$affiliate_id,$module_name,$maxarticles,$bgcolor2;
   if (!isset(
$sort) || ($sort == "")) $sort "date";
   
$lines ReadContent("$d3000_url/rss/rss_d3000.php?op=showcategory&id=$id");
   
// include_once(XOOPS_ROOT_PATH.'/header.php');
   
   
NavBar(_MD_DOWNLOAD3000_CATEGORY." : ".$lines[0]);
   
//title("Category : ".$lines[0]);
   
$i 1;
   echo 
""._MD_DOWNLOAD3000_ALLCAT."...n"
;
   while(
substr($lines[$i],0,1) == "%") {
      
$lines[$i] = substr($lines[$i],1);
      list(
$catname,$cat_id) = explode("|",$lines[$i]);
      echo 
"$cat_id&from=1'>$catname";
      
$i++;
   }
   echo 
"";
   echo 
""._MD_DOWNLOAD3000_LATESTADDITIONS."
"
;
   echo 
"";
   for (
$i=$i;$i<count($lines);$i++) {
     if (
$i == 1) {
       
$subcats explode("|",$lines[$i]);
     }
     else {
       list(
$title,$pid,$release,$desc_45,$size,$license,$os,$regnow_id,$new) = explode("|",$lines[$i]);
       if (
$new == 1$new ""._MD_DOWNLOAD3000_NEW."";
                   else 
$new ""._MD_DOWNLOAD3000_UPD."";
       echo 
"$new $d3000_url/article-$pid.html'>$title$releasen";
       echo 
"$desc_45n";
       echo 
"";
         echo 
""._MD_DOWNLOAD3000_SIZE.": 
$size kb";
         if (
$license == 'fr'$license ""._MD_DOWNLOAD3000_FREEWARE."";
         if (
$license == 'ad'$license ""._MD_DOWNLOAD3000_ADWARE."";
         if (
$license == 'sh'$license ""._MD_DOWNLOAD3000_SHAREWARE."";
         if (
$license == 'co'$license ""._MD_DOWNLOAD3000_COMMERCIAL."";
         if (
$license == 'de'$license ""._MD_DOWNLOAD3000_DEMO."";
         if (
$license == 'da'$license ""._MD_DOWNLOAD3000_DATAONLY."";
         echo 
""._MD_DOWNLOAD3000_LICENSE.": 
$license";
         echo 
""._MD_DOWNLOAD3000_OS.": images/winflag.gif" title="windows software">$os";
         echo 
"";
         if (
$regnow_id != "" && $regnow_id != 0) echo $regnow_id&affiliate=$affiliate_id'> ";
         echo 
"$d3000_url/download-count-reg-$pid.html" title="Download $title">images/downloadsmall.gif" border=0>";
         echo 
"";
       echo 
"n";
       echo 
"$bgcolor2'>images/blank.gif" border=0 height=1>n";
     }
   }
   echo 
"";
   
// DO NOT REMOVE THE FOLLOWING POWERED BY LINE. YOU'RE NOT ALLOWED TO REMOVE NOR EDIT THIS.
   // PLAY FAIR AND SUPPORT THE DEVELOPMENT, PLEASE!
   
PoweredBy();
   
   
// include_once(XOOPS_ROOT_PATH."/footer.php");
}
//#############################################################################
switch ($op) {

    default:
      
showall();
    break;

    case 
"showarticles":
      
showarticles($id,$from,$sort);
    break;

    case 
"showcategory":
      
showcategory($id);
    break;

    case 
"shownews":
      
shownews();
    break;

    case 
"showtop20":
      
showtop20();
    break;

}


If somebody has an idea?

2
xavhmn
Re: problem with the module download3000 (fixed)
  • 2007/2/5 11:25

  • xavhmn

  • Just popping in

  • Posts: 23

  • Since: 2004/11/16


I have solved the problems of bearing of php-nuke towards xoops, remains me more than has to make a cleaning of the code and you will have a new module

to see the module in action Made a small turn by this address

3
carnuke
Re: problem with the module download3000 (fixed)
  • 2007/2/5 16:50

  • carnuke

  • Home away from home

  • Posts: 1955

  • Since: 2003/11/5


Are you going to make this module available for us to try out here?
hhttp://houseofstrauss.co.uk Resource for alternative health and holistic lifestyle
search xoops

4
xavhmn
Re: problem with the module download3000 (fixed)
  • 2007/2/5 17:33

  • xavhmn

  • Just popping in

  • Posts: 23

  • Since: 2004/11/16


yes, soon, I makes the de-dusting of my comments and useless lines of codes

Login

Who's Online

382 user(s) are online (326 user(s) are browsing Support Forums)


Members: 0


Guests: 382


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Nov 30
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits