Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> Problem z kodem, Cannot redeclare fputcsv() in /serwis/lib/common.php on line 926
adioband
post
Post #1





Grupa: Zarejestrowani
Postów: 8
Pomógł: 0
Dołączył: 14.03.2010
Skąd: Lublin

Ostrzeżenie: (0%)
-----


  1. }#end foreach
  2. # strip the last deliminator
  3. $line = substr($line, 0, (strlen($deliminator) * -1));
  4. # add the newline
  5. $line .= "\n";
  6. # we don't care if the file pointer is invalid,
  7. # let fputs take care of it
  8. return $line;
  9. }#end fputcsv()
  10.  
  11. function fputcsv ($fp, $array, $deliminator=",") {
  12. return fputs($fp, putcsv($array,$delimitator));
  13. }#end fputcsv()
Powód edycji: [Kshyhoo]: bb-code
Go to the top of the page
+Quote Post
 
Start new topic
Odpowiedzi
adioband
post
Post #2





Grupa: Zarejestrowani
Postów: 8
Pomógł: 0
Dołączył: 14.03.2010
Skąd: Lublin

Ostrzeżenie: (0%)
-----


  1. class CSQLAdmin extends CLibrary {
  2.  
  3. /**
  4. * description
  5. *
  6. * @var type
  7. *
  8. * @access type
  9. */
  10. var $form;
  11.  
  12. /**
  13. * description
  14. *
  15. * @var type
  16. *
  17. * @access type
  18. */
  19. var $functions;
  20.  
  21.  
  22. /**
  23. * description functions list which will be executed in variouse points of sqladmin
  24. *
  25. * @var type
  26. *
  27. * @access type
  28. */
  29. var $functions;
  30.  
  31.  
  32. function CSQLAdmin($section , $templates , $db , $tables , $extra = "") {
  33. global $_CONF;
  34.  
  35. if (!$_GET["page"])
  36. $_GET["page"] = 1;
  37.  
  38.  
  39. parent::CLibrary("SQLAdmin");
  40.  
  41. //checking if the templates are orblects or path to a template file
  42. if (!is_array($templates))
  43. //if path the load the tempmate form that file
  44. $this->templates = array("generic_form" => new CTemplate($templates));
  45. else
  46. $this->templates = $templates;
  47.  
  48. $this->db = $db;
  49. $this->tables = $tables;
  50. //extra variables to be passed to cform
  51. $this->extra = $extra;
  52.  
  53. //loading the forms , changed the varialbes locations, but still keeping the compatibility
  54. $path = ($_CONF["forms"]["adminpath"] ? $_CONF["forms"]["adminpath"] : $_CONF["formspath"] );
  55. if (dirname($section)) {
  56.  
  57. $path .= dirname($section) . "/" ;
  58. $section = basename($section);
  59. }
  60.  
  61. //debuging part
  62. if (defined("PB_DEBUG") && (PB_DEBUG == "1"))
  63. echo "<br>FILE:SQLADMIN:MAIN:{$path}{$section}.xml";
  64.  
  65. $conf = new CConfig( $path . $section . ".xml");
  66.  
  67. $this->forms = $conf->vars["form"];
Go to the top of the page
+Quote Post

Posty w temacie


Reply to this topicStart new topic
2 Użytkowników czyta ten temat (2 Gości i 0 Anonimowych użytkowników)
0 Zarejestrowanych:

 



RSS Aktualny czas: 5.10.2025 - 07:51