Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

version 1.4 -- NewsDesk released!


moyashi

Recommended Posts

FYI

 

I have exactly the same crash-problem with MS1 and IE 6.00.2800 (danish version). The crash only appears, when I start to fill out the textareas with javascript-buttons.

 

Jakob

Best regards

Jakob Høy Biegel

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

Shopeon.com - Automate your webshop

Link to comment
Share on other sites

  • Replies 244
  • Created
  • Last Reply

Top Posters In This Topic

Quick-fix (in order to be able to make entries in newsdesk) is to disable javascript

 

In file: admin/includes/functions/newsdesk_general.php line 353

Place '//' at the begining of the line

 

In file: admin/newsdesk.hpp line 394

Insert a line with '<? /*' before line 394

Insert a line with '*/ ?>' after line 394

 

Now the javascript-buttons do not work, but more important IE does not crash anymore.

 

Jakob

Best regards

Jakob Høy Biegel

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

Shopeon.com - Automate your webshop

Link to comment
Share on other sites

Quick-fix (in order to be able to make entries in newsdesk) is to disable javascript

 

In file: admin/includes/functions/newsdesk_general.php line 353

Place '//' at the begining of the line

 

In file: admin/newsdesk.hpp line 394

Insert a line with '<? /*' before line 394

Insert a line with '*/ ?>' after line 394

 

Now the javascript-buttons do not work, but more important IE does not crash anymore.

 

Jakob

 

Sorry, it has be:

Insert a line with '<?php /*' before line 394

Insert a line with '*/ ?>' after line 394

Best regards

Jakob Høy Biegel

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

Shopeon.com - Automate your webshop

Link to comment
Share on other sites

After much wondering what the hecks going on here I believe I have a fix for the breadcrumb problem on newsdesk_info.php.

 

After:

 

// lets retrieve all $HTTP_GET_VARS keys and values..

$get_params = tep_get_all_get_params();

$get_params_back = tep_get_all_get_params(array('reviews_id')); // for back button

$get_params = substr($get_params, 0, -1); //remove trailing &

if ($get_params_back != '') {

   $get_params_back = substr($get_params_back, 0, -1); //remove trailing &

} else {

   $get_params_back = $get_params;

}

 

Add This:

 

// calculate category path

if ($HTTP_GET_VARS['newsdeskPath']) {

$newsPath = $HTTP_GET_VARS['newsdeskPath'];

} elseif ($HTTP_GET_VARS['newsdesk_id'] && !$HTTP_GET_VARS['newsdeskPath']) {

$newsPath = newsdesk_get_product_path($HTTP_GET_VARS['newsdesk_id']);

} else {

$newsPath = '';

}



if (strlen($newsPath) > 0) {

$newsPath_array = newsdesk_parse_category_path($newsPath);

$newsPath = implode('_', $newsPath_array);

$current_category_id = $newsPath_array[(sizeof($newsPath_array)-1)];

} else {

$current_category_id = 0;

}



if (isset($newsPath_array)) {

$n = sizeof($newsPath_array);

for ($i = 0; $i < $n; $i++) {

 $categories_query = tep_db_query(

 "select categories_name from " . TABLE_NEWSDESK_CATEGORIES_DESCRIPTION . " where categories_id = '" . $newsPath_array[$i] 

 . "' and language_id='" . $languages_id . "'"

 );

 if (tep_db_num_rows($categories_query) > 0) {

	 $categories = tep_db_fetch_array($categories_query);

	 $breadcrumb->add($categories['categories_name'], tep_href_link(FILENAME_NEWSDESK_INDEX, 'newsdeskPath=' 

	 . implode('_', array_slice($newsPath_array, 0, ($i+1)))));

 } else {

	 break;

 }

}



 } 

 

 if ($HTTP_GET_VARS['newsdesk_id']) {

$model_query = tep_db_query("select newsdesk_article_name from " . TABLE_NEWSDESK_DESCRIPTION . " where newsdesk_id = '" . $HTTP_GET_VARS['newsdesk_id'] . "'");

   $model = tep_db_fetch_array($model_query);

$breadcrumb->add($model['newsdesk_article_name'], tep_href_link(FILENAME_NEWSDESK_INFO, 'newsdeskPath=' . $newsPath . '&newsdesk_id=' 

. $HTTP_GET_VARS['newsdesk_id']));

}

 

Because of the nature of what I am using newsdesk for I have had to water down most of the features... nevertheless it is a great mod... creative use of current osCommerce catalog system.

 

You can see it working here: http://www.propheticlife.com

Link to comment
Share on other sites

Im working on a non e-commerce site using osCommerce as the backend and this contribution makes life so much easier...

 

All we need to do is figure out why the editor is crashing IE6....

 

anyone come up with a solution yet?

Link to comment
Share on other sites

Hello,

 

how can I view complete News at the Main Page of my Shop ?

Not only the headline.

 

 

Thanks

 

Andreas

 

 

This should be just a setting in the admin. Look under frontpage settings.

NewsDesk(934) / FAQDesk(1106) / OrderCheck(1168) :::

Link to comment
Share on other sites

  • 3 weeks later...

I have just found an error in the admin side of newsdesk when i try and preview a news story that ive just added i get:

 

Fatal error: Call to undefined function: tep_get_uploaded_file() in /home/stadmin/public_html/demostore/admin/newsdesk.php on line 918

 

any ideas???

Link to comment
Share on other sites

never mind on that one i realised the upload class in the new snapshots is missing however i do have one bug that i cant seem to resolve...when trying to view the news article i get the error:

 

1064 - You have an error in your SQL syntax near ') as total ' at line 1

 

select count() as total

 

[TEP STOP]

 

 

 

any ideas?

Edited by Johnson
Link to comment
Share on other sites

I should also mention that if i turn off Search engine friendly URL's the bug goes away on the faqdesk contribution but not on the newsdesk contribution....

 

weird seeing that they are basically the same

Link to comment
Share on other sites

  • 4 weeks later...

in file catalog/includes/modules/newsdesk/newsdesk_listing.php

 

on or about line 17 fine the line

 

$listing_split = new splitPageResults($HTTP_GET_VARS['page'], MAX_DISPLAY_NEWSDESK_SEARCH_RESULTS, $listing_sql, $listing_numrows);

 

and change it to:

 

$listing_split = new splitPageResults($listing_sql, MAX_DISPLAY_NEWSDESK_SEARCH_RESULTS, '*', $HTTP_GET_VARS['page']);

 

after making this change it should work fine.

 

This fix also fixes the issues with the faqdesk contribution as well :)

 

Just replace newsdesk with faqdesk.

Link to comment
Share on other sites

Hey again,

looks like I fixed it...

in includes/modules/newsdesk_listing.php, replace

$listing_split = new splitPageResults($HTTP_GET_VARS['page'], MAX_DISPLAY_NEWSDESK_SEARCH_RESULTS, $listing_numrows_sql, $listing_numrows);

with:

$listing_split = new splitPageResults($listing_sql, $HTTP_GET_VARS['page'], MAX_DISPLAY_NEWSDESK_SEARCH_RESULTS, 'p.newsdesk_id');

and the error is gone...

[/code]

Link to comment
Share on other sites

i changed the jsfunc.js in admin/includes/modules/newsdesk/html_editor/jsfunc.js

 

it prevents the ie to crach, just give it a try... :P

 

i added the next lines at the bottom of the file just before :

 

function orignal_code_copyright(text) {

 

//orginally code and images are from htttp://www.fusionphp.com

 

}

 

so it looks like this down at the bottom of jsfunc.js:

 

 

function submitonce(theform) {

// if IE 4+ or NS 6+

if (document.all || document.getElementById) {

// hunt down "submit" and "reset"

for (i=0;i<theform.length;i++) {

var tempobj=theform.elements;

if(tempobj.type.toLowerCase()=="submit"||tempobj.type.toLowerCase()=="reset") {

//disable it

tempobj.disabled=true;

}

}

}

}

 

function check_if_selected() {

var nonactive=true;

// if IE 4+ or NS 6+

if (document.all || document.getElementById) {

// hunt down "checkbox"

for (i=0;i<deleteform.length;i++) {

var tempobj=deleteform.elements;

if(tempobj.type.toLowerCase()=="checkbox") {

//disable it

if (document.forms[ "deleteform" ].elements[tempobj.name].checked)

nonactive=false;

}

}

}

}

function orignal_code_copyright(text) {

 

//orginally code and images are from htttp://www.fusionphp.com

 

}

 

 

// PS i am not a programmer but i found this in the file at htttp://www.fusionphp.com ( maybe if there is a better solution let me know) 8)

Link to comment
Share on other sites

  • 4 weeks later...

Hi there,

 

Please can anyone tell me how I can change the infobox background etc only for the newsdesk mod displayed on default.php?

 

I see there is a reference to 'new contentBox($info_box_contents)' in newsdesk.php, this seems to be where the colours etc are coming from. Changing the infobox colours in the stylesheet changes all info boxes as predicted.. I only want to change the newsdek box colours, not the others at the same time. Can anyone get me on the right track on this please?

 

Thanks in advance.

 

Adam

Link to comment
Share on other sites

Hello Carsten and Newsdesk fans,

This contribution is great! Just wanted to say it once again. I have customized the looks of each news article a little and now I'm thinking of utilizing the contribution (and osCommerce) in one of my first web projects. It's a volunteer web site I created for a organization that promotes bicycling in Flagstaff, AZ.

 

The problem with this site is that it is growing so fast, and everything is in plain HTML. It takes forever to create new pages and I'm mostly the only person who can do updates. :(

 

I have been looking into the CMS programs such as Nukephp etc. but I think they are too complicated. They have a ton of feautures that I don't really want to have. And I find them hard to customize. Whereas I have learned to customize osCommerce quite a bit.

 

Plus, in the future we may want to do fundraisers etc. online and then it wouldn't hurt to have the shopping feautures of osCommerce. :)

 

Now this is what I am planning and thinking of. Let me know what you think. But basically I think Carsten's newsdesk contribution would work great for managing the content of pages around the site. For instance we have column writers that then could write and post their own articles. (and even include 3 images of their own!).

 

My only question is: Would it be possible to make "just a user panel for each columnist writer"? I wouldn't want them to have access to any of the other store features as you can understand. And could I use just one newsdesk module and then have column writers etc. upload their stories into thei own subcategory?

 

I was thinking I could use the Administrator access contribution and make separate newsdesk modules and tables. For example: Newsdesk1, Newsdesk2, Newsdesk3, and on. for each writer.

 

What do you think about this?

 

I love the way this contribution works!

 

If you want to have a look at the current FlagstaffBiking.org page you can. It's not an osCommerce store yet. But I'm plannning to re-do it very soon.

 

http://www.flagstaffbiking.org

 

Thanks in advance for any opinions!

 

Thomas

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...