Jump to content
  • Checkout
  • Login
  • Get in touch


The e-commerce.

I have a question for Sql masters.


Recommended Posts

Recently i have install Newsdesk.v1.1 from OS contribute. I would like to know does anybody knows what does this message mean how i can fix it.


In the defualt.php catalog i have gotten : 1064 - You have an error in your SQL syntax near 'MAX_DISPLAY_newsdesk_NEWS' at line 4


select p.newsdesk_id, pd.language_id, pd.newsdesk_article_name, pd.newsdesk_article_description, pd.newsdesk_article_shorttext, pd.newsdesk_article_url, p.newsdesk_image, p.newsdesk_date_added, p.newsdesk_last_modified, p.newsdesk_date_available, p.newsdesk_status from newsdesk p, newsdesk_description pd WHERE pd.newsdesk_id = p.newsdesk_id and pd.language_id = "1" and newsdesk_status = 1 ORDER BY newsdesk_date_added DESC LIMIT MAX_DISPLAY_newsdesk_NEWS




In the admin page i see this..

///Admin page.???

1146 - Table 'catalog.newsdesk_to_categories' doesn't exist


select count(*) as total from newsdesk p, newsdesk_to_categories p2c where p.newsdesk_id = p2c.newsdesk_id and p.newsdesk_status = '1' and p2c.categories_id = '1'



Link to comment
Share on other sites

  • 8 months later...

'MAX_DISPLAY_newsdesk_NEWS' is in the configuration table of the db, not a language file :blink: - use phpmyadmin to run the newsdesk.sql file on your database

Link to comment
Share on other sites

ok, now i have installed it to but keep getting

Fatal error: Call to undefined function: get_uploaded_file() in /home/www/htdocs/pc-4-you.de/catalog/admin/newsdesk.php on line 918


before it was

Fatal error: Call to undefined function: tep_get_uploaded_file() in /home/www/htdocs/pc-4-you.de/catalog/admin/newsdesk.php on line 918


so i deleted tep_ but i still get error like above !?


there was also a problem with arry_merge that i solved, i am just sticking on thies for some reason


can anybody help ?


Kindest Regards


Link to comment
Share on other sites



  function tep_get_uploaded_file($filename) {
   if (isset($_FILES[$filename])) {
     $uploaded_file = array('name' => $_FILES[$filename]['name'],
                            'type' => $_FILES[$filename]['type'],
                            'size' => $_FILES[$filename]['size'],
                            'tmp_name' => $_FILES[$filename]['tmp_name']);
   } elseif (isset($GLOBALS['HTTP_POST_FILES'][$filename])) {
     global $HTTP_POST_FILES;

     $uploaded_file = array('name' => $HTTP_POST_FILES[$filename]['name'],
                            'type' => $HTTP_POST_FILES[$filename]['type'],
                            'size' => $HTTP_POST_FILES[$filename]['size'],
                            'tmp_name' => $HTTP_POST_FILES[$filename]['tmp_name']);
   } else {
     $uploaded_file = array('name' => $GLOBALS[$filename . '_name'],
                            'type' => $GLOBALS[$filename . '_type'],
                            'size' => $GLOBALS[$filename . '_size'],
                            'tmp_name' => $GLOBALS[$filename]);

   return $uploaded_file;

Link to comment
Share on other sites


This topic is now archived and is closed to further replies.

  • Create New...