Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

NewsDesk v1.48 Support


241

Recommended Posts

Regarding my earlier question on the subject of categories, I am guessing Newsdesk doesn't have the facility to put news items into osCommerce's default product category pages "out of the box" (index.php?cpath=x) - however, I'd be really keen to get such a system working, so if I had a category called "DVD" for example set up in both osC and Newsdesk, then news items would be displayed on the osC product category pages.

 

Does anyone know of a way to achieve this - I'd have a crack myself, but am a real nOOb when it comes to PHP/MySQL stuff!

Link to comment
Share on other sites

  • Replies 548
  • Created
  • Last Reply

Top Posters In This Topic

Hi..

And the next Problem.

 

Warning: sprintf(): Too few arguments in /www/htdocs/v150429/newsdesk_info.php on line 259

 

The link is without http://. only www.

 

Thx for help.

 

bill

My English is unfortunately bad. Excused ask.

Link to comment
Share on other sites

And still another problem. The box faqdesk.php does not indicate categories to me. Can unfortunately no error find.

 

cu

billi

My English is unfortunately bad. Excused ask.

Link to comment
Share on other sites

Sorry, here goes it around newsdesk and not around faqdesk. But have still another another problem.

Under

Menu is completely above an entry too see.(NEWS_BOX_CATE in the Pulldown?????) Unfortunately I cannot assign a language. If I select, then an empty side comes and column_right slips into the center. There somehow tunes which not. Does someone have an idea?

 

billi

My English is unfortunately bad. Excused ask.

Link to comment
Share on other sites

  • 3 weeks later...

Hi

 

Thanks for a very nice contribution.

 

I have a strange problem, and I guess it's related to number of languages. In an early post in this thread I read that it supports up to nine languages. I only have two but the language ID is 1 (english) and 11 (norwegian).

 

Evrything seem to work fine in both admin and on my site, but when I try to add articles it will not save the content of language 11. I have tried to enter the text directly into the database with phpmyadmin, and then the text shows up, but when I try to change it form admin and presses preview - the text is gone.

 

Does anybody see a solution for this?

 

I use the latest contribution (1.48.4) on Oscommerce 2.2-MS2

 

/Mr.T

Link to comment
Share on other sites

Hi

 

Thanks for a very nice contribution.

 

I have a strange problem, and I guess it's related to number of languages. In an early post in this thread I read that it supports up to nine languages. I only have two but the language ID is 1 (english) and 11 (norwegian).

 

Evrything seem to work fine in both admin and on my site, but when I try to add articles it will not save the content of language 11. I have tried to enter the text directly into the database with phpmyadmin, and then the text shows up, but when I try to change it form admin and presses preview - the text is gone.

 

Does anybody see a solution for this?

 

I use the latest contribution (1.48.4) on Oscommerce 2.2-MS2

 

/Mr.T

 

Yes it supports 9 languages with id=1 to id=9 you could change the instances of language id=11 in the database to a number between 1 and 9 or add to the code to bring support up to the language level of 11 languages.

No longer giving free advice. Please place deposit in meter slot provided.  Individual: [=] SME: [==] Corporation: [===]
If deposit does not fit one of the slots provided then you are asking too much! :P

Is your Osc dated try Phoenix  raising oscommerce from the ashes.

Link to comment
Share on other sites

Yes it supports 9 languages with id=1 to id=9 you could change the instances of? language id=11 in the database to a number between 1 and 9 or add to the code to bring support up to the language level of 11 languages.

What is easiest?

 

If I change the number 11 to a number between 1 and 9 I have to find all other references to 11 and update those as well. Could easily forget something - and then it?s messed up...

 

How do I add to the code to bring support up to language level of 11 (I think this is the best solution).

 

Thanks

 

/MR.T

 

 

Edit: spelling

Edited by MR.T
Link to comment
Share on other sites

I solved it myself...

 

It was very easy..... :blush: :blush: :blush: :blush:

 

Just added 2 lines to the code starting from line 905 in newsdesk.php:

 

$newsdesk_article_shorttext[1] = nl2br($HTTP_POST_VARS['newsdesk_article_shorttext_1']);
$newsdesk_article_shorttext[2] = nl2br($HTTP_POST_VARS['newsdesk_article_shorttext_2']);
$newsdesk_article_shorttext[3] = nl2br($HTTP_POST_VARS['newsdesk_article_shorttext_3']);
$newsdesk_article_shorttext[4] = nl2br($HTTP_POST_VARS['newsdesk_article_shorttext_4']);
$newsdesk_article_shorttext[5] = nl2br($HTTP_POST_VARS['newsdesk_article_shorttext_5']);
$newsdesk_article_shorttext[6] = nl2br($HTTP_POST_VARS['newsdesk_article_shorttext_6']);
$newsdesk_article_shorttext[7] = nl2br($HTTP_POST_VARS['newsdesk_article_shorttext_7']);
$newsdesk_article_shorttext[8] = nl2br($HTTP_POST_VARS['newsdesk_article_shorttext_8']);
$newsdesk_article_shorttext[9] = nl2br($HTTP_POST_VARS['newsdesk_article_shorttext_9']);
$newsdesk_article_shorttext[10] = nl2br($HTTP_POST_VARS['newsdesk_article_shorttext_10']);
$newsdesk_article_shorttext[11] = nl2br($HTTP_POST_VARS['newsdesk_article_shorttext_11']);


$newsdesk_article_description[1] = nl2br($HTTP_POST_VARS['newsdesk_article_description_1']);
$newsdesk_article_description[2] = nl2br($HTTP_POST_VARS['newsdesk_article_description_2']);
$newsdesk_article_description[3] = nl2br($HTTP_POST_VARS['newsdesk_article_description_3']);
$newsdesk_article_description[4] = nl2br($HTTP_POST_VARS['newsdesk_article_description_4']);
$newsdesk_article_description[5] = nl2br($HTTP_POST_VARS['newsdesk_article_description_5']);
$newsdesk_article_description[6] = nl2br($HTTP_POST_VARS['newsdesk_article_description_6']);
$newsdesk_article_description[7] = nl2br($HTTP_POST_VARS['newsdesk_article_description_7']);
$newsdesk_article_description[8] = nl2br($HTTP_POST_VARS['newsdesk_article_description_8']);
$newsdesk_article_description[10] = nl2br($HTTP_POST_VARS['newsdesk_article_description_10']);
$newsdesk_article_description[11] = nl2br($HTTP_POST_VARS['newsdesk_article_description_11']);

 

Thanks for a great script :thumbsup:

 

/MR.T

Link to comment
Share on other sites

I solved it myself...

 

/MR.T

 

Since you are one of the few whom actually tries to solve things themself I will give you the rest.

 

You also need to add this code in admin/includes/modules/newsdesk/jsfunc.js

 

after:

 

function setsmiley_9_s(text) {
if (document.new_product.newsdesk_article_shorttext_9.createTextRange && document.new_product.newsdesk_article_shorttext_9.caretPos) {
 var caretPos = document.new_product.newsdesk_article_shorttext_9.caretPos;
 caretPos.text = caretPos.text.charAt(caretPos.text.length - 1) == ' ' ?
 text + ' ' : text;
}
else document.new_product.newsdesk_article_shorttext_9.value += text;
document.new_product.newsdesk_article_shorttext_9.focus(caretPos)
}

 

ADD this:

 

function setsmiley_10_s(text) {
if (document.new_product.newsdesk_article_shorttext_10.createTextRange && document.new_product.newsdesk_article_shorttext_10.caretPos) {
 var caretPos = document.new_product.newsdesk_article_shorttext_10.caretPos;
 caretPos.text = caretPos.text.charAt(caretPos.text.length - 1) == ' ' ?
 text + ' ' : text;
}
else document.new_product.newsdesk_article_shorttext_10.value += text;
document.new_product.newsdesk_article_shorttext_10.focus(caretPos)
}

function setsmiley_11_s(text) {
if (document.new_product.newsdesk_article_shorttext_11.createTextRange && document.new_product.newsdesk_article_shorttext_11.caretPos) {
 var caretPos = document.new_product.newsdesk_article_shorttext_11.caretPos;
 caretPos.text = caretPos.text.charAt(caretPos.text.length - 1) == ' ' ?
 text + ' ' : text;
}
else document.new_product.newsdesk_article_shorttext_11.value += text;
document.new_product.newsdesk_article_shorttext_11.focus(caretPos)
}

 

and then after:

 

function setsmiley_9_c(text) {
if (document.new_product.newsdesk_article_description_9.createTextRange && document.new_product.newsdesk_article_description_9.caretPos) {
 var caretPos = document.new_product.newsdesk_article_description_9.caretPos;
 caretPos.text = caretPos.text.charAt(caretPos.text.length - 1) == ' ' ?
 text + ' ' : text;
}
else document.new_product.newsdesk_article_description_9.value += text;
document.new_product.newsdesk_article_description_9.focus(caretPos)
}

 

ADD this:

 

function setsmiley_10_c(text) {
if (document.new_product.newsdesk_article_description_10.createTextRange && document.new_product.newsdesk_article_description_10.caretPos) {
 var caretPos = document.new_product.newsdesk_article_description_10.caretPos;
 caretPos.text = caretPos.text.charAt(caretPos.text.length - 1) == ' ' ?
 text + ' ' : text;
}
else document.new_product.newsdesk_article_description_10.value += text;
document.new_product.newsdesk_article_description_10.focus(caretPos)
}

function setsmiley_11_c(text) {
if (document.new_product.newsdesk_article_description_11.createTextRange && document.new_product.newsdesk_article_description_11.caretPos) {
 var caretPos = document.new_product.newsdesk_article_description_11.caretPos;
 caretPos.text = caretPos.text.charAt(caretPos.text.length - 1) == ' ' ?
 text + ' ' : text;
}
else document.new_product.newsdesk_article_description_11.value += text;
document.new_product.newsdesk_article_description_11.focus(caretPos)
}

:thumbsup:

No longer giving free advice. Please place deposit in meter slot provided.  Individual: [=] SME: [==] Corporation: [===]
If deposit does not fit one of the slots provided then you are asking too much! :P

Is your Osc dated try Phoenix  raising oscommerce from the ashes.

Link to comment
Share on other sites

I do not have any images for my news categories (no artist available) and the categories list had broken images in the header. So, after some quick browsing here is the fix if you have this problem:

 

In newsdesk_index.php (newsdesk_index.tpl.php if you have BTS installed) locate this code:

if ($category['categories_image'] == 'null') {
echo '';
} else {
echo tep_image(DIR_WS_IMAGES . $image, HEADING_TITLE, HEADING_IMAGE_WIDTH, HEADING_IMAGE_HEIGHT);
echo tep_image(DIR_WS_IMAGES . $image_two, HEADING_TITLE, HEADING_IMAGE_WIDTH, HEADING_IMAGE_HEIGHT);
echo tep_image(DIR_WS_IMAGES . $image_three, HEADING_TITLE, HEADING_IMAGE_WIDTH, HEADING_IMAGE_HEIGHT);
}

and replace it with this code:

if ($category['categories_image'] == 'null' || $category['categories_image'] == '' ) {
echo '';
} else {
echo tep_image(DIR_WS_IMAGES . $image, HEADING_TITLE, HEADING_IMAGE_WIDTH, HEADING_IMAGE_HEIGHT);
echo tep_image(DIR_WS_IMAGES . $image_two, HEADING_TITLE, HEADING_IMAGE_WIDTH, HEADING_IMAGE_HEIGHT);
echo tep_image(DIR_WS_IMAGES . $image_three, HEADING_TITLE, HEADING_IMAGE_WIDTH, HEADING_IMAGE_HEIGHT);
}

The change is adding the || == '' to the if statement.

 

I also found another area in the file (above the previous, about 1/3 the way in) that seems to have a problem as well. Find this code:

if (($categories['categories_image'] == 'NULL') || categories) {
} else {
$print_echo = tep_image(DIR_WS_IMAGES . $categories['categories_image'], $categories['categories_name'], SUBCATEGORY_IMAGE_WIDTH, SUBCATEGORY_IMAGE_HEIGHT);
}

and replace it with this code:

if (($categories['categories_image'] == 'NULL') || $categories['categories_image'] == '') {
} else {
$print_echo = tep_image(DIR_WS_IMAGES . $categories['categories_image'], $categories['categories_name'], SUBCATEGORY_IMAGE_WIDTH, SUBCATEGORY_IMAGE_HEIGHT);
}

Doesn't seem like any comparison to "categories" would be possible (at least not in my limited understanding of php).

Link to comment
Share on other sites

Hi!

 

I only have 2 languages. I tried to modify the sql file to avoid any unnecessary insertion. But it give me an sql error. So I ask you to help me modify the sql file which will match my needings.

 

- I need only 2 languages

- all default language_id references should be "2" not "1" or "0" because it is my default language

- I do not need any "test news" insertion the best thing would be a "blank" sql file I will add the news myself via admin (the original sql is good for testing locally and discover newsdesk features but for a live shop a blank would be better)

 

Here is my modified sql file (I'm sure I missed something but I dont know what it is):

 

My default language is hungarian (2) so I duplicated all english insertion and I leave them in english to avoid any disturbing content. I will translate them later.

 

-- 
-- Table structure for table `newsdesk`
-- 

DROP TABLE IF EXISTS newsdesk;
CREATE TABLE newsdesk (
 newsdesk_id int(11) NOT NULL auto_increment,
 newsdesk_image varchar(64) default NULL,
 newsdesk_image_two varchar(64) default NULL,
 newsdesk_image_three varchar(64) default NULL,
 newsdesk_date_added datetime NOT NULL default '0000-00-00 00:00:00',
 newsdesk_last_modified datetime default NULL,
 newsdesk_date_available datetime default NULL,
 newsdesk_status tinyint(1) NOT NULL default '0',
 newsdesk_sticky tinyint(1) NOT NULL default '1',
 PRIMARY KEY  (newsdesk_id),
 KEY idx_newsdesk_date_added (newsdesk_date_added)
) TYPE=MyISAM AUTO_INCREMENT=4;

-- 
-- Dumping data for table `newsdesk`
-- 

INSERT INTO newsdesk (newsdesk_id, newsdesk_image, newsdesk_image_two, newsdesk_image_three, newsdesk_date_added, newsdesk_last_modified, newsdesk_date_available, newsdesk_status, newsdesk_sticky) VALUES (1, 'newsdesk_test_osc_sticky.gif', '', '', '2003-03-10 02:32:00', '2004-05-12 14:09:14', NULL, 1, 1),
(2, 'newsdesk_test_osc_thanks.gif', '', '', '2003-03-10 02:40:20', '2004-05-26 18:38:18', NULL, 1, 0),
(3, 'newsdesk_test_osc_action.gif', 'newsdesk_test_osc_cartoons.gif', 'newsdesk_test_osc_graphic.gif', '2003-03-10 23:40:39', '2004-05-19 18:46:08', NULL, 1, 0);

-- --------------------------------------------------------

-- 
-- Table structure for table `newsdesk_categories`
-- 

DROP TABLE IF EXISTS newsdesk_categories;
CREATE TABLE newsdesk_categories (
 categories_id int(11) NOT NULL auto_increment,
 categories_image varchar(64) default NULL,
 parent_id int(11) NOT NULL default '0',
 sort_order int(3) default NULL,
 date_added datetime default NULL,
 last_modified datetime default NULL,
 catagory_status tinyint(1) NOT NULL default '1',
 PRIMARY KEY  (categories_id),
 KEY idx_categories_parent_id (parent_id)
) TYPE=MyISAM AUTO_INCREMENT=10;

-- 
-- Dumping data for table `newsdesk_categories`
-- 

INSERT INTO newsdesk_categories (categories_id, categories_image, parent_id, sort_order, date_added, last_modified, catagory_status) VALUES (1, NULL, 0, 1, '2003-03-10 02:27:32', '2004-05-12 11:29:55', 1),
(2, NULL, 0, 2, '2003-03-10 02:28:09', '2004-05-12 14:42:55', 1),
(3, NULL, 0, 4, '2003-03-10 02:28:34', '2004-05-12 14:44:12', 0),
(4, NULL, 0, 5, '2003-03-10 02:28:58', '2004-05-12 14:43:59', 1),
(5, NULL, 0, 6, '2003-03-10 12:02:57', '2004-05-12 14:43:39', 1),
(6, NULL, 5, 1, '2003-03-10 12:03:28', '2004-05-12 12:22:14', 1),
(7, NULL, 5, 2, '2003-03-10 23:20:06', '2004-05-12 12:23:41', 1),
(8, NULL, 5, 3, '2003-03-10 23:36:12', '2004-05-12 12:25:20', 1),
(9, NULL, 0, 3, '2004-05-12 14:42:03', '2004-05-12 14:44:30', 1);

-- --------------------------------------------------------

-- 
-- Table structure for table `newsdesk_categories_description`
-- 

DROP TABLE IF EXISTS newsdesk_categories_description;
CREATE TABLE newsdesk_categories_description (
 categories_id int(11) NOT NULL default '0',
 language_id int(11) NOT NULL default '1',
 categories_name varchar(32) NOT NULL default '',
 PRIMARY KEY  (categories_id,language_id),
 KEY idx_categories_name (categories_name)
) TYPE=MyISAM;

-- 
-- Dumping data for table `newsdesk_categories_description`
-- 

INSERT INTO newsdesk_categories_description (categories_id, language_id, categories_name) VALUES (1, 1, 'image'),
(1, 2, 'image'),
(2, 1, 'one image'),
(2, 2, 'one image'),
(3, 1, 'off'),
(3, 2, 'off'),
(4, 1, 'sticky'),
(4, 2, 'sticky'),
(5, 1, 'nested top'),
(5, 2, 'nested top'),
(6, 1, 'nested down one'),
(6, 2, 'nested down one'),
(7, 1, 'nested down two'),
(7, 2, 'nested down two'),
(8, 1, 'nested down three'),
(8, 2, 'nested down three'),
(9, 1, 'no image'),
(9, 2, 'no image'),

-- --------------------------------------------------------

-- 
-- Table structure for table `newsdesk_configuration`
-- 

DROP TABLE IF EXISTS newsdesk_configuration;
CREATE TABLE newsdesk_configuration (
 configuration_id int(11) NOT NULL auto_increment,
 configuration_title varchar(64) NOT NULL default '',
 configuration_key varchar(64) NOT NULL default '',
 configuration_value varchar(255) NOT NULL default '',
 configuration_description varchar(255) NOT NULL default '',
 configuration_group_id int(11) NOT NULL default '0',
 sort_order int(5) default NULL,
 last_modified datetime default NULL,
 date_added datetime NOT NULL default '0000-00-00 00:00:00',
 use_function varchar(255) default NULL,
 set_function varchar(255) default NULL,
 PRIMARY KEY  (configuration_id)
) TYPE=MyISAM AUTO_INCREMENT=40;

-- 
-- Dumping data for table `newsdesk_configuration`
-- 

INSERT INTO newsdesk_configuration (configuration_id, configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, last_modified, date_added, use_function, set_function) VALUES (1, 'Search Results', 'MAX_DISPLAY_NEWSDESK_SEARCH_RESULTS', '20', 'How many articles do you want to list?', 1, 1, NULL, '2003-02-16 02:08:36', NULL, NULL),
(2, 'Page Links', 'MAX_DISPLAY_NEWSDESK_PAGE_LINKS', '5', 'Number of links to use for page-sets', 1, 2, NULL, '2003-02-16 02:08:36', NULL, NULL),
(3, 'Display Headline', 'NEWSDESK_ARTICLE_NAME', '2', 'Do you want to display the headline? (0=disable; 1=enable)', 1, 3, '2004-05-10 13:28:31', '2003-02-16 02:08:36', NULL, NULL),
(4, 'Display Summary', 'NEWSDESK_ARTICLE_SHORTTEXT', '0', 'Do you want to display the summary? (0=disable; \r\n\r\n1=enable)', 1, 4, '2004-05-10 13:28:38', '2003-02-16 02:08:36', NULL, NULL),
(5, 'Display Content', 'NEWSDESK_ARTICLE_DESCRIPTION', '0', 'Do you want to display the content? (0=disable; \r\n\r\n1=enable)', 1, 5, '2004-05-10 13:28:43', '2003-02-16 02:08:36', NULL, NULL),
(6, 'Display Date', 'NEWSDESK_DATE_AVAILABLE', '1', 'Do you want to display the date? (0=disable; 1=enable)', 1, 6, NULL, '2003-02-16 02:08:36', NULL, NULL),
(7, 'Display URL', 'NEWSDESK_ARTICLE_URL', '4', 'Do you want to display the outside resource URL? (0=disable; \r\n\r\n1=enable)', 1, 7, '2004-05-26 18:50:41', '2003-02-16 02:08:36', NULL, NULL),
(8, 'Display URL Name', 'NEWSDESK_ARTICLE_URL_NAME', '3', 'Do you want to display the outside resource URL Name (0=disable; 1=enable)', 1, 8, '2004-05-26 17:08:00', '2004-05-26 17:07:00', NULL, NULL),
(9, 'Display Status', 'NEWSDESK_STATUS', '0', 'Do you want to display the status for the article? (0=disable; 1=enable)', 1, 9, '2004-05-10 13:28:52', '2003-02-16 02:08:36', NULL, NULL),
(10, 'Display Image 1', 'NEWSDESK_IMAGE', '0', 'Do you want to display image "1" for the article? (0=disable; 1=enable)', 1, 10, '2004-05-10 13:28:57', '2003-02-16 02:08:36', NULL, NULL),
(11, 'Display Image 2', 'NEWSDESK_IMAGE_TWO', '0', 'Do you want to display image "2" for the article? (0=disable; 1=enable)', 1, 11, '2004-05-10 13:29:01', '2003-02-16 02:08:36', NULL, NULL),
(12, 'Display Image 3', 'NEWSDESK_IMAGE_THREE', '0', 'Do you want to display image "3" for the article? (0=disable; 1=enable)', 1, 12, '2004-05-10 13:29:06', '2003-02-16 02:08:36', NULL, NULL),
(14, 'Location of Prev/Next Navigation Bar', 'NEWSDESK_PREV_NEXT_BAR_LOCATION', '3', 'Sets the location of the Prev/Next Navigation Bar (1-top, 2-bottom, 3-both)', 1, 14, NULL, '2003-02-16 02:08:36', NULL, NULL),
(15, 'Display Main News Items', 'MAX_DISPLAY_NEWSDESK_NEWS', '3', 'How many articles do you want to display on the top page?', 2, 1, NULL, '2003-02-16 02:08:36', NULL, NULL),
(16, 'Latest News Box Counts', 'LATEST_DISPLAY_NEWSDESK_NEWS', '5', 'How many articles do you want to display in the Latest News Box?', 2, 2, NULL, '2003-02-16 02:08:36', NULL, NULL),
(17, 'Display Latest News Box', 'DISPLAY_LATEST_NEWS_BOX', '1', 'Do you want to display the Latest News Box? (0=disable; 1=enable)', 2, 3, NULL, '2003-02-16 02:08:36', NULL, NULL),
(18, 'Display News Catagory Box', 'DISPLAY_NEWS_CATAGORY_BOX', '1', 'Do you want to display the News Catagory Box? (0=disable; 1=enable)', 2, 4, NULL, '2003-02-16 02:08:36', NULL, NULL),
(19, 'Display View Counts', 'DISPLAY_NEWSDESK_VIEWCOUNT', '1', 'Do you want to display View Counts? (0=disable; 1=enable)', 2, 5, NULL, '2003-02-16 02:08:36', NULL, NULL),
(20, 'Display Read More', 'DISPLAY_NEWSDESK_READMORE', '1', 'Do you want to display Read More? (0=disable; 1=enable)', 2, 6, NULL, '2003-02-16 02:08:36', NULL, NULL),
(21, 'Display Summary', 'DISPLAY_NEWSDESK_SUMMARY', '1', 'Do you want to display the News Summary? (0=disable; 1=enable)', 2, 7, NULL, '2003-02-16 02:08:36', NULL, NULL),
(22, 'Display Headline', 'DISPLAY_NEWSDESK_HEADLINE', '1', 'Do you want to display the News Headline? (0=disable; 1=enable)', 2, 8, NULL, '2003-02-16 02:08:36', NULL, NULL),
(23, 'Display Date', 'DISPLAY_NEWSDESK_DATE', '1', 'Do you want to display the News Date? (0=disable; 1=enable)', 2, 9, NULL, '2003-02-16 02:08:36', NULL, NULL),
(24, 'Display Image 1', 'DISPLAY_NEWSDESK_IMAGE', '1', 'Do you want to display image "1" for the article? (0=disable; 1=enable)', 2, 10, NULL, '2003-03-03 11:59:47', NULL, NULL),
(25, 'Display Image 2', 'DISPLAY_NEWSDESK_IMAGE_TWO', '1', 'Do you want to display image "2" for the article? (0=disable; 1=enable)', 2, 11, '2003-03-03 12:08:55', '2003-03-03 11:59:47', NULL, NULL),
(26, 'Display Image 3', 'DISPLAY_NEWSDESK_IMAGE_THREE', '1', 'Do you want to display image "3" for the article? (0=disable; 1=enable)', 2, 12, '2003-03-03 12:09:16', '2003-03-03 11:59:47', NULL, NULL),
(27, 'Display Reviews', 'DISPLAY_NEWSDESK_REVIEWS', '1', 'Do you want to display News Reviews? (0=disable; 1=enable)', 3, 1, '2004-05-18 15:39:09', '2003-02-16 02:08:36', NULL, NULL),
(28, 'New Reviews', 'MAX_DISPLAY_NEW_REVIEWS', '10', 'Maximum number of new reviews to display', 3, 2, NULL, '2003-02-16 02:08:36', NULL, NULL),
(29, 'Display Headline', 'STICKY_ARTICLE_NAME', '1', 'Do you want to display the headline? (0=disable; 1=enable)', 4, 1, NULL, '2003-03-02 00:47:21', NULL, NULL),
(30, 'Display Summary', 'STICKY_ARTICLE_SHORTTEXT', '1', 'Do you want to display the summary? (0=disable; 1=enable)', 4, 2, NULL, '2003-03-02 00:47:21', NULL, NULL),
(31, 'Display Content', 'STICKY_ARTICLE_DESCRIPTION', '1', 'Do you want to display the content? (0=disable; 1=enable)', 4, 3, '2003-03-02 00:49:34', '2003-03-02 00:47:21', NULL, NULL),
(32, 'Display View Counts', 'STICKY_NEWSDESK_VIEWCOUNT', '1', 'Do you want to display View Counts? (0=disable; 1=enable)', 4, 4, NULL, '2003-03-02 00:47:21', NULL, NULL),
(33, 'Display Read More', 'STICKY_NEWSDESK_READMORE', '1', 'Do you want to display Read More? (0=disable; 1=enable)', 4, 5, NULL, '2003-03-02 00:47:21', NULL, NULL),
(34, 'Display Date', 'STICKY_DATE_ADDED', '1', 'Do you want to display the date? (0=disable; 1=enable)', 4, 6, '2003-03-02 00:49:54', '2003-03-02 00:47:21', NULL, NULL),
(35, 'Display URL', 'STICKY_ARTICLE_URL', '0', 'Do you want to display the outside resource URL? (0=disable; 1=enable)', 4, 7, '2004-05-26 17:13:50', '2003-03-02 00:47:21', NULL, NULL),
(36, 'Display URL Name', 'STICKY_ARTICLE_URL_NAME', '1', 'Do you want to display the outside resource URL Name (0=disable; 1=enable)', 4, 8, '2003-03-02 00:51:00', '2003-03-02 00:50:00', NULL, NULL),
(37, 'Display Image', 'STICKY_IMAGE', '1', 'Do you want to display image "1" for the article? (0=disable; 1=enable)', 4, 9, '2003-03-02 00:50:14', '2003-03-02 00:47:21', NULL, NULL),
(38, 'Display Image 2', 'STICKY_IMAGE_TWO', '1', 'Do you want to display image "2"for the article? (0=disable; 1=enable)', 4, 10, NULL, '2003-03-03 23:10:34', NULL, NULL),
(39, 'Display Image 3', 'STICKY_IMAGE_THREE', '1', 'Do you want to display image "3" for the article? (0=disable; 1=enable)', 4, 11, NULL, '2003-03-03 23:10:34', NULL, NULL);

-- --------------------------------------------------------

-- 
-- Table structure for table `newsdesk_configuration_group`
-- 

DROP TABLE IF EXISTS newsdesk_configuration_group;
CREATE TABLE newsdesk_configuration_group (
 configuration_group_id int(11) NOT NULL auto_increment,
 configuration_group_title varchar(64) NOT NULL default '',
 configuration_group_description varchar(255) NOT NULL default '',
 sort_order int(5) default NULL,
 visible int(1) default '1',
 PRIMARY KEY  (configuration_group_id)
) TYPE=MyISAM AUTO_INCREMENT=5;

-- 
-- Dumping data for table `newsdesk_configuration_group`
-- 

INSERT INTO newsdesk_configuration_group (configuration_group_id, configuration_group_title, configuration_group_description, sort_order, visible) VALUES (1, 'Listing Settings', 'Listing Page configuration options', 1, 1),
(2, 'Frontpage Settings', 'Front Page configuration options', 1, 1),
(3, 'Reviews Settings', 'Reviews configuration options', 1, 1),
(4, 'Sticky Settings', 'Reviews configuration options', 1, 1);

-- --------------------------------------------------------

-- 
-- Table structure for table `newsdesk_description`
-- 

DROP TABLE IF EXISTS newsdesk_description;
CREATE TABLE newsdesk_description (
 newsdesk_id int(11) NOT NULL auto_increment,
 language_id int(11) NOT NULL default '1',
 newsdesk_article_name varchar(64) NOT NULL default '',
 newsdesk_article_description text,
 newsdesk_article_shorttext text,
 newsdesk_article_url varchar(255) default NULL,
 newsdesk_article_url_name varchar(255) default NULL,
 newsdesk_article_viewed int(5) default '0',
 newsdesk_image_text text,
 newsdesk_image_text_two text,
 newsdesk_image_text_three text,
 PRIMARY KEY  (newsdesk_id,language_id),
 KEY newsdesk_article_name (newsdesk_article_name)
) TYPE=MyISAM AUTO_INCREMENT=4;

-- 
-- Dumping data for table `newsdesk_description`
-- 

INSERT INTO newsdesk_description (newsdesk_id, language_id, newsdesk_article_name, newsdesk_article_description, newsdesk_article_shorttext, newsdesk_article_url, newsdesk_article_url_name, newsdesk_article_viewed, newsdesk_image_text, newsdesk_image_text_two, newsdesk_image_text_three) VALUES (1, 1, 'Stickies are here!', 'Stickies have been implemented in v1.48.2<br />\r\n<br />\r\nIs this not a nifty feature?', '<b>Welcome to the Sticky area</b>', '', '', 0, '', '', ''),
(1, 2, 'Stickies are here!', 'Stickies have been implemented in v1.48.2<br />\r\n<br />\r\nIs this not a nifty feature?', '<b>Welcome to the Sticky area</b>', '', '', 0, '', '', ''),
(2, 1, 'NewsDesk version 1.48.2', '<b>NewsDesk version 1.48.2 RELEASED!</b><br />\r\n<br />\r\nWith the great help of a few brave souls we can all now enjoy a newer and more powerful, flexible, function rich (<i>too rich?</i>) NewsDesk <ul><li>Mulitple images</li><li>Review Approvals</li><li>RSS</li><li>HTML Bar Editing</li><li>Remove Images</li><li>Subtitles for Images</li><li>And of course Stickies</li></ul>I hope that you will enjoy your NewsDesk!', '<b>Welcome to NewsDesk version 1.48.2</b><i>Special thanks to those who helped with Beta Testing!</i>', 'www.wolfen.uklinux.net/product_info.php?cPath=1&products_id=1', 'Newsdesk', 0, '', '', ''),
(2, 2, 'NewsDesk version 1.48.2', '<b>NewsDesk version 1.48.2 RELEASED!</b><br />\r\n<br />\r\nWith the great help of a few brave souls we can all now enjoy a newer and more powerful, flexible, function rich (<i>too rich?</i>) NewsDesk <ul><li>Mulitple images</li><li>Review Approvals</li><li>RSS</li><li>HTML Bar Editing</li><li>Remove Images</li><li>Subtitles for Images</li><li>And of course Stickies</li></ul>I hope that you will enjoy your NewsDesk!', '<b>Welcome to NewsDesk version 1.48.2</b><i>Special thanks to those who helped with Beta Testing!</i>', 'www.wolfen.uklinux.net/product_info.php?cPath=1&products_id=1', 'Newsdesk', 0, '', '', ''),
(3, 1, '3 images !!!', '<s>3 images</s> !!!<u>NewsDesk version 1.48.2</u> now has the capability to use 3 images <br />\r\n<br />\r\nplus <sub>subtitles</sub>.<sup>Yippe</sup> Is life not grand?', '<b>NOW up to 3 images can be used!!!</b>', '', '', 0, 'action', 'cartoons', 'graphic'),
(3, 2, '3 images !!!', '<s>3 images</s> !!!<u>NewsDesk version 1.48.2</u> now has the capability to use 3 images <br />\r\n<br />\r\nplus <sub>subtitles</sub>.<sup>Yippe</sup> Is life not grand?', '<b>NOW up to 3 images can be used!!!</b>', '', '', 0, 'action', 'cartoons', 'graphic'),

-- --------------------------------------------------------

-- 
-- Table structure for table `newsdesk_reviews`
-- 

DROP TABLE IF EXISTS newsdesk_reviews;
CREATE TABLE newsdesk_reviews (
 reviews_id int(11) NOT NULL auto_increment,
 newsdesk_id int(11) NOT NULL default '0',
 customers_id int(11) default NULL,
 customers_name varchar(64) NOT NULL default '',
 reviews_rating int(1) default NULL,
 date_added datetime default NULL,
 last_modified datetime default NULL,
 reviews_read int(5) NOT NULL default '0',
 approved tinyint(3) unsigned default '0',
 PRIMARY KEY  (reviews_id)
) TYPE=MyISAM AUTO_INCREMENT=11;

-- 
-- Dumping data for table `newsdesk_reviews`
-- 

INSERT INTO newsdesk_reviews (reviews_id, newsdesk_id, customers_id, customers_name, reviews_rating, date_added, last_modified, reviews_read, approved) VALUES (1, 1, 2, 'test test', 5, '2003-03-11 01:26:31', NULL, 4, 1),
(2, 3, 2, 'Carsten aka Moyashi', 4, '2003-03-11 01:29:02', NULL, 2, 1),
(3, 2, 2, 'Carsten aka Moyashi', 5, '2003-03-11 01:29:53', NULL, 1, 1),
(4, 2, 2, 'steve 241', 1, '2004-05-18 18:01:20', NULL, 1, 1),
(5, 1, 2, 'steve 241', 2, '2004-05-18 16:25:15', '2004-05-18 16:49:55', 3, 1),
(6, 1, 2, 'steve 241', 4, '2004-05-18 16:06:46', NULL, 2, 1),
(7, 1, 2, 'steve 241', 3, '2004-05-18 16:09:34', NULL, 0, 1),
(8, 2, 2, 'steve 241', 5, '2004-05-18 18:25:13', NULL, 1, 1),
(9, 2, 2, 'steve 241', 3, '2004-05-18 18:37:50', NULL, 2, 1),
(10, 3, 2, 'steve 241', 4, '2004-05-19 10:10:41', NULL, 1, 0);

-- --------------------------------------------------------

-- 
-- Table structure for table `newsdesk_reviews_description`
-- 

DROP TABLE IF EXISTS newsdesk_reviews_description;
CREATE TABLE newsdesk_reviews_description (
 reviews_id int(11) NOT NULL default '0',
 languages_id int(11) NOT NULL default '0',
 reviews_text text NOT NULL,
 PRIMARY KEY  (reviews_id,languages_id)
) TYPE=MyISAM;

-- 
-- Dumping data for table `newsdesk_reviews_description`
-- 

INSERT INTO newsdesk_reviews_description (reviews_id, languages_id, reviews_text) VALUES (1, 1, 'Thanks to Emiliano for his \r\n\r\nefforts in beta testing and providing ideas and code to help make NewsDesk better'),
(2, 1, 'hehe, after almost a week of effort I was able to finish this part of the mod. I hope that you all enjoy it!'),
(3, 1, 'I wonder who will approve this review just to read it '),
(4, 1, 'this is a test of the reviews section of the newsdesk'),
(5, 1, 'this is a test to check the reviews function within the admin'),
(6, 1, 'I think that more use can be made of the stickies area than is being done so far'),
(7, 1, 'this is to further test the use of the reviews section of the newsdesk'),
(8, 1, 'this is a test of the newsdesk reviews procedure and the if switch'),
(9, 1, 'this is just a quick test of the review write for the newsdesk'),
(10, 1, 'The use of and or availability of having 3 images is a useful addition to the newsdesk');

-- --------------------------------------------------------

-- 
-- Table structure for table `newsdesk_to_categories`
-- 

DROP TABLE IF EXISTS newsdesk_to_categories;
CREATE TABLE newsdesk_to_categories (
 newsdesk_id int(11) NOT NULL default '0',
 categories_id int(11) NOT NULL default '0',
 PRIMARY KEY  (newsdesk_id,categories_id)
) TYPE=MyISAM;

-- 
-- Dumping data for table `newsdesk_to_categories`
-- 

INSERT INTO newsdesk_to_categories (newsdesk_id, categories_id) VALUES (1, 4),
(2, 2),
(3, 1);

 

Any help will be appreciated.

Thx, Andrew

Link to comment
Share on other sites

This is a very easy task for a monkey

:blink:

DROP TABLE IF EXISTS newsdesk;
CREATE TABLE newsdesk (
 newsdesk_id int(11) NOT NULL auto_increment,
 newsdesk_image varchar(64) default NULL,
 newsdesk_image_two varchar(64) default NULL,
 newsdesk_image_three varchar(64) default NULL,
 newsdesk_date_added datetime NOT NULL default '0000-00-00 00:00:00',
 newsdesk_last_modified datetime default NULL,
 newsdesk_date_available datetime default NULL,
 newsdesk_status tinyint(1) NOT NULL default '0',
 newsdesk_sticky tinyint(1) NOT NULL default '1',
 PRIMARY KEY  (newsdesk_id),
 KEY idx_newsdesk_date_added (newsdesk_date_added)
) TYPE=MyISAM AUTO_INCREMENT=1;

DROP TABLE IF EXISTS newsdesk_categories;
CREATE TABLE newsdesk_categories (
 categories_id int(11) NOT NULL auto_increment,
 categories_image varchar(64) default NULL,
 parent_id int(11) NOT NULL default '0',
 sort_order int(3) default NULL,
 date_added datetime default NULL,
 last_modified datetime default NULL,
 catagory_status tinyint(1) NOT NULL default '1',
 PRIMARY KEY  (categories_id),
 KEY idx_categories_parent_id (parent_id)
) TYPE=MyISAM AUTO_INCREMENT=1;

DROP TABLE IF EXISTS newsdesk_categories_description;
CREATE TABLE newsdesk_categories_description (
 categories_id int(11) NOT NULL default '0',
 language_id int(11) NOT NULL default '1',
 categories_name varchar(32) NOT NULL default '',
 PRIMARY KEY  (categories_id,language_id),
 KEY idx_categories_name (categories_name)
) TYPE=MyISAM;

DROP TABLE IF EXISTS newsdesk_configuration;
CREATE TABLE newsdesk_configuration (
 configuration_id int(11) NOT NULL auto_increment,
 configuration_title varchar(64) NOT NULL default '',
 configuration_key varchar(64) NOT NULL default '',
 configuration_value varchar(255) NOT NULL default '',
 configuration_description varchar(255) NOT NULL default '',
 configuration_group_id int(11) NOT NULL default '0',
 sort_order int(5) default NULL,
 last_modified datetime default NULL,
 date_added datetime NOT NULL default '0000-00-00 00:00:00',
 use_function varchar(255) default NULL,
 set_function varchar(255) default NULL,
 PRIMARY KEY  (configuration_id)
) TYPE=MyISAM AUTO_INCREMENT=40;

INSERT INTO newsdesk_configuration (configuration_id, configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, last_modified, date_added, use_function, set_function) VALUES (1, 'Search Results', 'MAX_DISPLAY_NEWSDESK_SEARCH_RESULTS', '20', 'How many articles do you want to list?', 1, 1, NULL, '2003-02-16 02:08:36', NULL, NULL),
(2, 'Page Links', 'MAX_DISPLAY_NEWSDESK_PAGE_LINKS', '5', 'Number of links to use for page-sets', 1, 2, NULL, '2003-02-16 02:08:36', NULL, NULL),
(3, 'Display Headline', 'NEWSDESK_ARTICLE_NAME', '2', 'Do you want to display the headline? (0=disable; 1=enable)', 1, 3, '2004-05-10 13:28:31', '2003-02-16 02:08:36', NULL, NULL),
(4, 'Display Summary', 'NEWSDESK_ARTICLE_SHORTTEXT', '0', 'Do you want to display the summary? (0=disable; \r\n\r\n1=enable)', 1, 4, '2004-05-10 13:28:38', '2003-02-16 02:08:36', NULL, NULL),
(5, 'Display Content', 'NEWSDESK_ARTICLE_DESCRIPTION', '0', 'Do you want to display the content? (0=disable; \r\n\r\n1=enable)', 1, 5, '2004-05-10 13:28:43', '2003-02-16 02:08:36', NULL, NULL),
(6, 'Display Date', 'NEWSDESK_DATE_AVAILABLE', '1', 'Do you want to display the date? (0=disable; 1=enable)', 1, 6, NULL, '2003-02-16 02:08:36', NULL, NULL),
(7, 'Display URL', 'NEWSDESK_ARTICLE_URL', '4', 'Do you want to display the outside resource URL? (0=disable; \r\n\r\n1=enable)', 1, 7, '2004-05-26 18:50:41', '2003-02-16 02:08:36', NULL, NULL),
(8, 'Display URL Name', 'NEWSDESK_ARTICLE_URL_NAME', '3', 'Do you want to display the outside resource URL Name (0=disable; 1=enable)', 1, 8, '2004-05-26 17:08:00', '2004-05-26 17:07:00', NULL, NULL),
(9, 'Display Status', 'NEWSDESK_STATUS', '0', 'Do you want to display the status for the article? (0=disable; 1=enable)', 1, 9, '2004-05-10 13:28:52', '2003-02-16 02:08:36', NULL, NULL),
(10, 'Display Image 1', 'NEWSDESK_IMAGE', '0', 'Do you want to display image "1" for the article? (0=disable; 1=enable)', 1, 10, '2004-05-10 13:28:57', '2003-02-16 02:08:36', NULL, NULL),
(11, 'Display Image 2', 'NEWSDESK_IMAGE_TWO', '0', 'Do you want to display image "2" for the article? (0=disable; 1=enable)', 1, 11, '2004-05-10 13:29:01', '2003-02-16 02:08:36', NULL, NULL),
(12, 'Display Image 3', 'NEWSDESK_IMAGE_THREE', '0', 'Do you want to display image "3" for the article? (0=disable; 1=enable)', 1, 12, '2004-05-10 13:29:06', '2003-02-16 02:08:36', NULL, NULL),
(14, 'Location of Prev/Next Navigation Bar', 'NEWSDESK_PREV_NEXT_BAR_LOCATION', '3', 'Sets the location of the Prev/Next Navigation Bar (1-top, 2-bottom, 3-both)', 1, 14, NULL, '2003-02-16 02:08:36', NULL, NULL),
(15, 'Display Main News Items', 'MAX_DISPLAY_NEWSDESK_NEWS', '3', 'How many articles do you want to display on the top page?', 2, 1, NULL, '2003-02-16 02:08:36', NULL, NULL),
(16, 'Latest News Box Counts', 'LATEST_DISPLAY_NEWSDESK_NEWS', '5', 'How many articles do you want to display in the Latest News Box?', 2, 2, NULL, '2003-02-16 02:08:36', NULL, NULL),
(17, 'Display Latest News Box', 'DISPLAY_LATEST_NEWS_BOX', '1', 'Do you want to display the Latest News Box? (0=disable; 1=enable)', 2, 3, NULL, '2003-02-16 02:08:36', NULL, NULL),
(18, 'Display News Catagory Box', 'DISPLAY_NEWS_CATAGORY_BOX', '1', 'Do you want to display the News Catagory Box? (0=disable; 1=enable)', 2, 4, NULL, '2003-02-16 02:08:36', NULL, NULL),
(19, 'Display View Counts', 'DISPLAY_NEWSDESK_VIEWCOUNT', '1', 'Do you want to display View Counts? (0=disable; 1=enable)', 2, 5, NULL, '2003-02-16 02:08:36', NULL, NULL),
(20, 'Display Read More', 'DISPLAY_NEWSDESK_READMORE', '1', 'Do you want to display Read More? (0=disable; 1=enable)', 2, 6, NULL, '2003-02-16 02:08:36', NULL, NULL),
(21, 'Display Summary', 'DISPLAY_NEWSDESK_SUMMARY', '1', 'Do you want to display the News Summary? (0=disable; 1=enable)', 2, 7, NULL, '2003-02-16 02:08:36', NULL, NULL),
(22, 'Display Headline', 'DISPLAY_NEWSDESK_HEADLINE', '1', 'Do you want to display the News Headline? (0=disable; 1=enable)', 2, 8, NULL, '2003-02-16 02:08:36', NULL, NULL),
(23, 'Display Date', 'DISPLAY_NEWSDESK_DATE', '1', 'Do you want to display the News Date? (0=disable; 1=enable)', 2, 9, NULL, '2003-02-16 02:08:36', NULL, NULL),
(24, 'Display Image 1', 'DISPLAY_NEWSDESK_IMAGE', '1', 'Do you want to display image "1" for the article? (0=disable; 1=enable)', 2, 10, NULL, '2003-03-03 11:59:47', NULL, NULL),
(25, 'Display Image 2', 'DISPLAY_NEWSDESK_IMAGE_TWO', '1', 'Do you want to display image "2" for the article? (0=disable; 1=enable)', 2, 11, '2003-03-03 12:08:55', '2003-03-03 11:59:47', NULL, NULL),
(26, 'Display Image 3', 'DISPLAY_NEWSDESK_IMAGE_THREE', '1', 'Do you want to display image "3" for the article? (0=disable; 1=enable)', 2, 12, '2003-03-03 12:09:16', '2003-03-03 11:59:47', NULL, NULL),
(27, 'Display Reviews', 'DISPLAY_NEWSDESK_REVIEWS', '1', 'Do you want to display News Reviews? (0=disable; 1=enable)', 3, 1, '2004-05-18 15:39:09', '2003-02-16 02:08:36', NULL, NULL),
(28, 'New Reviews', 'MAX_DISPLAY_NEW_REVIEWS', '10', 'Maximum number of new reviews to display', 3, 2, NULL, '2003-02-16 02:08:36', NULL, NULL),
(29, 'Display Headline', 'STICKY_ARTICLE_NAME', '1', 'Do you want to display the headline? (0=disable; 1=enable)', 4, 1, NULL, '2003-03-02 00:47:21', NULL, NULL),
(30, 'Display Summary', 'STICKY_ARTICLE_SHORTTEXT', '1', 'Do you want to display the summary? (0=disable; 1=enable)', 4, 2, NULL, '2003-03-02 00:47:21', NULL, NULL),
(31, 'Display Content', 'STICKY_ARTICLE_DESCRIPTION', '1', 'Do you want to display the content? (0=disable; 1=enable)', 4, 3, '2003-03-02 00:49:34', '2003-03-02 00:47:21', NULL, NULL),
(32, 'Display View Counts', 'STICKY_NEWSDESK_VIEWCOUNT', '1', 'Do you want to display View Counts? (0=disable; 1=enable)', 4, 4, NULL, '2003-03-02 00:47:21', NULL, NULL),
(33, 'Display Read More', 'STICKY_NEWSDESK_READMORE', '1', 'Do you want to display Read More? (0=disable; 1=enable)', 4, 5, NULL, '2003-03-02 00:47:21', NULL, NULL),
(34, 'Display Date', 'STICKY_DATE_ADDED', '1', 'Do you want to display the date? (0=disable; 1=enable)', 4, 6, '2003-03-02 00:49:54', '2003-03-02 00:47:21', NULL, NULL),
(35, 'Display URL', 'STICKY_ARTICLE_URL', '0', 'Do you want to display the outside resource URL? (0=disable; 1=enable)', 4, 7, '2004-05-26 17:13:50', '2003-03-02 00:47:21', NULL, NULL),
(36, 'Display URL Name', 'STICKY_ARTICLE_URL_NAME', '1', 'Do you want to display the outside resource URL Name (0=disable; 1=enable)', 4, 8, '2003-03-02 00:51:00', '2003-03-02 00:50:00', NULL, NULL),
(37, 'Display Image', 'STICKY_IMAGE', '1', 'Do you want to display image "1" for the article? (0=disable; 1=enable)', 4, 9, '2003-03-02 00:50:14', '2003-03-02 00:47:21', NULL, NULL),
(38, 'Display Image 2', 'STICKY_IMAGE_TWO', '1', 'Do you want to display image "2"for the article? (0=disable; 1=enable)', 4, 10, NULL, '2003-03-03 23:10:34', NULL, NULL),
(39, 'Display Image 3', 'STICKY_IMAGE_THREE', '1', 'Do you want to display image "3" for the article? (0=disable; 1=enable)', 4, 11, NULL, '2003-03-03 23:10:34', NULL, NULL);

DROP TABLE IF EXISTS newsdesk_configuration_group;
CREATE TABLE newsdesk_configuration_group (
 configuration_group_id int(11) NOT NULL auto_increment,
 configuration_group_title varchar(64) NOT NULL default '',
 configuration_group_description varchar(255) NOT NULL default '',
 sort_order int(5) default NULL,
 visible int(1) default '1',
 PRIMARY KEY  (configuration_group_id)
) TYPE=MyISAM AUTO_INCREMENT=5;

INSERT INTO newsdesk_configuration_group (configuration_group_id, configuration_group_title, configuration_group_description, sort_order, visible) VALUES (1, 'Listing Settings', 'Listing Page configuration options', 1, 1),
(2, 'Frontpage Settings', 'Front Page configuration options', 1, 1),
(3, 'Reviews Settings', 'Reviews configuration options', 1, 1),
(4, 'Sticky Settings', 'Reviews configuration options', 1, 1);

DROP TABLE IF EXISTS newsdesk_description;
CREATE TABLE newsdesk_description (
 newsdesk_id int(11) NOT NULL auto_increment,
 language_id int(11) NOT NULL default '1',
 newsdesk_article_name varchar(64) NOT NULL default '',
 newsdesk_article_description text,
 newsdesk_article_shorttext text,
 newsdesk_article_url varchar(255) default NULL,
 newsdesk_article_url_name varchar(255) default NULL,
 newsdesk_article_viewed int(5) default '0',
 newsdesk_image_text text,
 newsdesk_image_text_two text,
 newsdesk_image_text_three text,
 PRIMARY KEY  (newsdesk_id,language_id),
 KEY newsdesk_article_name (newsdesk_article_name)
) TYPE=MyISAM AUTO_INCREMENT=1;

DROP TABLE IF EXISTS newsdesk_reviews;
CREATE TABLE newsdesk_reviews (
 reviews_id int(11) NOT NULL auto_increment,
 newsdesk_id int(11) NOT NULL default '0',
 customers_id int(11) default NULL,
 customers_name varchar(64) NOT NULL default '',
 reviews_rating int(1) default NULL,
 date_added datetime default NULL,
 last_modified datetime default NULL,
 reviews_read int(5) NOT NULL default '0',
 approved tinyint(3) unsigned default '0',
 PRIMARY KEY  (reviews_id)
) TYPE=MyISAM AUTO_INCREMENT=1;

DROP TABLE IF EXISTS newsdesk_reviews_description;
CREATE TABLE newsdesk_reviews_description (
 reviews_id int(11) NOT NULL default '0',
 languages_id int(11) NOT NULL default '0',
 reviews_text text NOT NULL,
 PRIMARY KEY  (reviews_id,languages_id)
) TYPE=MyISAM;

DROP TABLE IF EXISTS newsdesk_to_categories;
CREATE TABLE newsdesk_to_categories (
 newsdesk_id int(11) NOT NULL default '0',
 categories_id int(11) NOT NULL default '0',
 PRIMARY KEY  (newsdesk_id,categories_id)
) TYPE=MyISAM;

No longer giving free advice. Please place deposit in meter slot provided.  Individual: [=] SME: [==] Corporation: [===]
If deposit does not fit one of the slots provided then you are asking too much! :P

Is your Osc dated try Phoenix  raising oscommerce from the ashes.

Link to comment
Share on other sites

I found it out myself (halfway at least).

 

The error was: 1146 - Table 'mydatabase.TABLE_NEWSDESK_CONFIGURATION' doesn't exist.

 

The solution:

I had copied the additonal code snippets from the install.txt in this mod to the php-files. And the code that was supplied for catalog/includes/database_tables.php does not work. The code supplied for catalog/admin/includes/database_tables.php did work.

Since both should be the same, I copied the newsdesk-code from catalog/admin/includes/database_tables.php to catalog/includes/database_tables.php, and now it works.

Before I tried to find any differences between those two code snippets and did not find any. Must be some minor typo in there.

Link to comment
Share on other sites

Another typo in install.txt of the NewsDesk package is:

 

This is what is in there:

#### [ OPEN ] ##################################################################

 

 

 

admin /index.php

 

 

 

#### [ ADD -- regular osc versions] ############################################################

 

NOTE !!!

 

Below code is ONLY for osC -- 2.2 and MS1

 

 

 

 

 

//BEGIN -- newsdesk

 

array(

 

'title' => BOX_HEADING_NEWSDESK,

 

'image' => 'catalog.gif',

 

'href' => tep_href_link(FILENAME_NEWSDESK, 'selected_box=newsdesk'),

 

'children' => array(

 

  array('title' => NEWSDESK_ARTICLES, 'link' => tep_href_link(FILENAME_NEWSDESK, 'selected_box=newsdesk')),

 

  array('title' => NEWSDESK_REVIEWS, 'link' => tep_href_link(FILENAME_NEWSDESK_REVIEWS, 'selected_box=newsdesk')))),

 

//END -- newsdesk

 

The last comma results in a parse error, so it should be omitted. To make this post complete, the code to add into index.php should be:

 

#### [ OPEN ] ##################################################################

 

 

 

admin /index.php

 

 

 

#### [ ADD -- regular osc versions] ############################################################

 

NOTE !!!

 

Below code is ONLY for osC -- 2.2 and MS1

 

 

//BEGIN -- newsdesk

array(

'title' => BOX_HEADING_NEWSDESK,

'image' => 'catalog.gif',

'href' => tep_href_link(FILENAME_NEWSDESK, 'selected_box=newsdesk'),

'children' => array(

 array('title' => NEWSDESK_ARTICLES, 'link' => tep_href_link(FILENAME_NEWSDESK, 'selected_box=newsdesk')),

 array('title' => NEWSDESK_REVIEWS, 'link' => tep_href_link(FILENAME_NEWSDESK_REVIEWS, 'selected_box=newsdesk'))))

//END -- newsdesk

Link to comment
Share on other sites

I found it out myself (halfway at least).

 

The error was: 1146 - Table 'mydatabase.TABLE_NEWSDESK_CONFIGURATION' doesn't exist.

 

This is not so the code does work.

 

Another typo in install.txt of the NewsDesk package is:

 

This is what is in there:

The last comma results in a parse error, so it should be omitted. To make this post complete, the code to add into index.php should be:

 

This is not true unless you just throw the code in at the end of everything else in which case you change the , comma for a ; semi-colon

 

and people wonder why I no longer support this contribution >_<

No longer giving free advice. Please place deposit in meter slot provided.  Individual: [=] SME: [==] Corporation: [===]
If deposit does not fit one of the slots provided then you are asking too much! :P

Is your Osc dated try Phoenix  raising oscommerce from the ashes.

Link to comment
Share on other sites

Hi Steve!

 

Can I change the default language_id from 1 to 2?

 

DROP TABLE IF EXISTS newsdesk_categories_description;
CREATE TABLE newsdesk_categories_description (
categories_id int(11) NOT NULL default '0',
language_id int(11) NOT NULL default '1',
categories_name varchar(32) NOT NULL default '',
PRIMARY KEY  (categories_id,language_id),
KEY idx_categories_name (categories_name)
) TYPE=MyISAM;

 

DROP TABLE IF EXISTS newsdesk_description;
CREATE TABLE newsdesk_description (
newsdesk_id int(11) NOT NULL auto_increment,
language_id int(11) NOT NULL default '1',
newsdesk_article_name varchar(64) NOT NULL default '',
newsdesk_article_description text,
newsdesk_article_shorttext text,
newsdesk_article_url varchar(255) default NULL,
newsdesk_article_url_name varchar(255) default NULL,
newsdesk_article_viewed int(5) default '0',
newsdesk_image_text text,
newsdesk_image_text_two text,
newsdesk_image_text_three text,
PRIMARY KEY  (newsdesk_id,language_id),
KEY newsdesk_article_name (newsdesk_article_name)
) TYPE=MyISAM AUTO_INCREMENT=1;

 

and from 0 to 2

 

DROP TABLE IF EXISTS newsdesk_reviews_description;
CREATE TABLE newsdesk_reviews_description (
reviews_id int(11) NOT NULL default '0',
languages_id int(11) NOT NULL default '0',
reviews_text text NOT NULL,
PRIMARY KEY  (reviews_id,languages_id)
) TYPE=MyISAM;

 

Cheers, Andrew

Link to comment
Share on other sites

Hi Steve!

 

Can I change the default language_id from 1 to 2?

 

Cheers, Andrew

 

 

Yes

No longer giving free advice. Please place deposit in meter slot provided.  Individual: [=] SME: [==] Corporation: [===]
If deposit does not fit one of the slots provided then you are asking too much! :P

Is your Osc dated try Phoenix  raising oscommerce from the ashes.

Link to comment
Share on other sites

Oh yeah! Its working!

 

One more thing. No harm but I realised that your embedded wysiwyg editor couldnt handle preformatted html content. I'd like to add another wysiwyg editor which can. How do I remove your editor?

Link to comment
Share on other sites

  • 2 weeks later...

have a small problem:

 

look at : http://pokersupply.se/newsdesk_info.php?ne...d=5&language=en

 

For some reason the headline aperas att the rigt and screws upp the table making it to weide. what is wrong?

 

an a smaller thing in what file do I remove the image? (table_background_reviews.gif)

Edited by fredrikb
Link to comment
Share on other sites

have a small problem:

 

look at : http://pokersupply.se/newsdesk_info.php?ne...d=5&language=en

 

For some reason the headline aperas att the rigt and screws upp the table making it to weide. what is wrong?

 

an a smaller thing in what file do I remove the image? (table_background_reviews.gif)

 

newer mind solved it myself....

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...