Jump to content
burt

Responsive osCommerce - Bootstrap

Recommended Posts

5 hours ago, Demitry said:

another question... I installed a threat scanner and ran it. One of the things it identified was the /admin/define_language.php file. I know that this file had some security vulnerabilities in the older versions of osC. I assume that those vulnerabilities are now secured in that file. With what version of osC were these changes made to resolve the security issues? Thanks.

 

 

not a bootstrap question.  ask it elsewhere please


This is a signature that appears on all my posts.  
IF YOU MAKE A POST REQUESTING HELP...please state the exact version
of osCommerce that you are using. THANKS

 
Get the latest Responsive osCommerce CE (community edition) here

Share this post


Link to post
Share on other sites
8 hours ago, Demitry said:

hi,

I noticed that product_info.php page and product_reviews.php (and likely some others) have addslashes($product_info['products_name']), which displays a backslash before an apostrophe in the alt tags for the product image. 

I changed it to stripslashes(),.. but was wondering if there is any significant purpose to keeping the addslashes() alt tags?

 

as far as I recall, this is also true in all version of historical oscommerce

hence:  not a bootstrap question, please ask elsewhere


This is a signature that appears on all my posts.  
IF YOU MAKE A POST REQUESTING HELP...please state the exact version
of osCommerce that you are using. THANKS

 
Get the latest Responsive osCommerce CE (community edition) here

Share this post


Link to post
Share on other sites

@BrockleyJohn, @burt

John, Burt, thank you for the replies.

John, The latest BS Edge does have this code in the product_info.php, page reviews, and others. The screenshot below is from the latest download of BS Edge in the product_info.php page.

Burt, with all due respect, I'm not sure how the osC community is supposed to help improve on this software when we cannot address issues, ..which are both present in the latest release of BS Edge.

If adding of slashes to alt tags is also true in all version of historical oscommerce, and this is an issue that had never been corrected, ..and it currently exists in BS Edge, ..then how is this not the place to address it?

Demitry

 

 

 

product_info-source.png

Edited by Demitry

osCommerce: made for programmers, ...because store owners do not want to be programmers.

https://trends.google.com/trends/explore?date=all&geo=US&q=oscommerce

Share this post


Link to post
Share on other sites

@Demitry apologies - sloppy checking. I've never seen that code path before; I don't believe I've had a BS client yet that doesn't use large images which is the only time that statement gets used. I had to go back remove the large images from my test product to reproduce. The reason it is originally there is to prevent a quote (or double-quote) in the product name breaking the page or throwing an error. You should check whether either breaks your change.

2 hours ago, Demitry said:

@BrockleyJohn, @burt

If adding of slashes to alt tags is also true in all version of historical oscommerce, and this is an issue that had never been corrected, ..and it currently exists in BS Edge, ..then how is this not the place to address it?product_info-source.png

This isn't necessarily the place to address it because the scope of the project is to provide a responsive variant of the main osc release. The more additional change that's done, the harder it is to bring this variant and the main release stream back together in the future. The only serious departure from this has been php7 compliance because of the strength of demand from BS-users. If there's a big problem that prevents people using the project for some reason, an urgent new requirement (eg for google, meta data etc) or something that makes it much easier to create addons without changing core code then maybe there's a discussion to be had but I don't think that what you're raising here falls into these categories.

If changes are introduced for an issue that's carried through from the mainstream but which eventually gets fixed in a different way in the mainstream, that can create an extra migration issue for getting BS-based projects into a mainstream version at some point in the future.


For a new install or if your store isn't mobile-friendly, get the community-supported responsive osCommerce (Phoenix).

here: on the official osc download page

Working on generalising bespoke solutions for Quickbooks integration, Easify integration and pay4later (DEKO) integration at 2.3.x

Share this post


Link to post
Share on other sites
2 hours ago, BrockleyJohn said:

This isn't the place to address it because the scope of the project is to provide a responsive variant of the main osc release.

This.  So please stop asking questions that are outside this scope.

You would be better off asking them in their own thread.


This is a signature that appears on all my posts.  
IF YOU MAKE A POST REQUESTING HELP...please state the exact version
of osCommerce that you are using. THANKS

 
Get the latest Responsive osCommerce CE (community edition) here

Share this post


Link to post
Share on other sites

getting this error under PHP7.2 , have I forgotton to install an update? I take it this is right thread for this?

Warning: sizeof(): Parameter must be an array or an object that implements Countable in \includes\functions\general.php on line 89

Warning: sizeof(): Parameter must be an array or an object that implements Countable in \a*****\categories.php on line 976

Installed Version: osCommerce Online Merchant v2.3.4.1


 

Share this post


Link to post
Share on other sites

Geting this error on the content in Modules.

Warning: Use of undefined constant OSCOM_APP_PAYPAL_LOGIN_SORT_ORDER - assumed 'OSCOM_APP_PAYPAL_LOGIN_SORT_ORDER' (this will throw an Error in a future version of PHP) in public_html\includes\modules\content\login\cm_paypal_login.php on line 41


 

Share this post


Link to post
Share on other sites
1 hour ago, justcatering said:

Geting this error on the content in Modules.

Warning: Use of undefined constant OSCOM_APP_PAYPAL_LOGIN_SORT_ORDER - assumed 'OSCOM_APP_PAYPAL_LOGIN_SORT_ORDER' (this will throw an Error in a future version of PHP) in public_html\includes\modules\content\login\cm_paypal_login.php on line 41

https://github.com/gburton/Responsive-osCommerce/blob/c418847961c7a483f17f99c5fe04095520b47d8c/includes/apps/paypal/modules/LOGIN/LOGIN.php#L127-L130

 

This piece of code tries to find that, if it exists deletes it and replaces with something else.  If it does not exist, it likely throws that error.
Is the error still there?


This is a signature that appears on all my posts.  
IF YOU MAKE A POST REQUESTING HELP...please state the exact version
of osCommerce that you are using. THANKS

 
Get the latest Responsive osCommerce CE (community edition) here

Share this post


Link to post
Share on other sites
1 hour ago, justcatering said:

getting this error under PHP7.2 , have I forgotton to install an update? I take it this is right thread for this?

Warning: sizeof(): Parameter must be an array or an object that implements Countable in \includes\functions\general.php on line 89

Warning: sizeof(): Parameter must be an array or an object that implements Countable in \a*****\categories.php on line 976

Installed Version: osCommerce Online Merchant v2.3.4.1

https://github.com/gburton/Responsive-osCommerce/blob/c418847961c7a483f17f99c5fe04095520b47d8c/admin/categories.php#L976

if (sizeof($cPath_array) > 0) {

Therefore your variable cPath_array does not exist.

cPath_array is made here:

https://github.com/gburton/Responsive-osCommerce/blob/c418847961c7a483f17f99c5fe04095520b47d8c/admin/includes/application_top.php#L220-L226

You'll need to do more investigations.  It could be a php7.2 problem.


This is a signature that appears on all my posts.  
IF YOU MAKE A POST REQUESTING HELP...please state the exact version
of osCommerce that you are using. THANKS

 
Get the latest Responsive osCommerce CE (community edition) here

Share this post


Link to post
Share on other sites

Must be a PHP 7.2 issue! I just imported old converted databse using same method used on old PHP5.2 sites and converted ok imported ok in SQL but totaly crashed new site giving countless errors such as those below.

Warning: Use of undefined constant GZIP_COMPRESSION - assumed 'GZIP_COMPRESSION' (this will throw an Error in a future version of PHP) in C:\xampp\htdocs\public_html\includes\application_top.php on line 77

Warning: Use of undefined constant SEARCH_ENGINE_FRIENDLY_URLS - assumed 'SEARCH_ENGINE_FRIENDLY_URLS' (this will throw an Error in a future version of PHP) in C:\xampp\htdocs\public_html\includes\application_top.php on line 94

Warning: Use of undefined constant USE_CACHE - assumed 'USE_CACHE' (this will throw an Error in a future version of PHP) in C:\xampp\htdocs\public_html\includes\application_top.php on line 131

Warning: Use of undefined constant SESSION_WRITE_DIRECTORY - assumed 'SESSION_WRITE_DIRECTORY' (this will throw an Error in a future version of PHP) in C:\xampp\htdocs\public_html\includes\application_top.php on line 144

Warning: Use of undefined constant SESSION_FORCE_COOKIE_USE - assumed 'SESSION_FORCE_COOKIE_USE' (this will throw an Error in a future version of PHP) in C:\xampp\htdocs\public_html\includes\application_top.php on line 158


 

Share this post


Link to post
Share on other sites

I'd suggest that these problems stem from the use of an older database, as SEARCH_ENGINE_FRIENDLY_URLS and USE_CACHE both exist and are used.  The others probably do as well, if you check;

https://github.com/gburton/Responsive-osCommerce/search?utf8=✓&q=USE_CACHE

Replace USE_CACHE with the other missing things and you will see.


This is a signature that appears on all my posts.  
IF YOU MAKE A POST REQUESTING HELP...please state the exact version
of osCommerce that you are using. THANKS

 
Get the latest Responsive osCommerce CE (community edition) here

Share this post


Link to post
Share on other sites

OK after restore ran error script it did not report anything. However store front is OK but admin side is broken.

Warning: Use of undefined constant BUS_ENABLE_DELETE - assumed 'BUS_ENABLE_DELETE' (this will throw an Error in a future version of PHP) in C:\xampp\htdocs\public_html\a*******\index.php on line 32

Sorry restore was back to default database as in new install of Edge

Edited by justcatering
update

 

Share this post


Link to post
Share on other sites

When you get something "missing" like this...do a search;

https://github.com/gburton/Responsive-osCommerce/search?utf8=✓&q=BUS_ENABLE_DELETE

You can see that it should not be there as it does not exist.

As is *is* in your version...it's a mistake on your side somewhere.

 


This is a signature that appears on all my posts.  
IF YOU MAKE A POST REQUESTING HELP...please state the exact version
of osCommerce that you are using. THANKS

 
Get the latest Responsive osCommerce CE (community edition) here

Share this post


Link to post
Share on other sites

The line that's now failing on BUS_ENABLE_DELETE must be add-on code. My guess is that the add-on needs an installation script running to add this constant and you've forgotten to do it on your current database.


For a new install or if your store isn't mobile-friendly, get the community-supported responsive osCommerce (Phoenix).

here: on the official osc download page

Working on generalising bespoke solutions for Quickbooks integration, Easify integration and pay4later (DEKO) integration at 2.3.x

Share this post


Link to post
Share on other sites
6 hours ago, justcatering said:

Installed Version: osCommerce Online Merchant v2.3.4.1

That is not Bootstrap (2.3.4BS). If that's what you're actually running, there's no point in asking questions about it in this thread. You may get lucky and the same code is in both, but often not.

Share this post


Link to post
Share on other sites
47 minutes ago, MrPhil said:

That is not Bootstrap (2.3.4BS). If that's what you're actually running, there's no point in asking questions about it in this thread. You may get lucky and the same code is in both, but often not.

2.3.4 bs was updated to 2.3.4.1 back in the Summer;

https://github.com/gburton/Responsive-osCommerce/commit/c39cf08b6a182e3bd4f0a136dc6a2951480f01a3

We've gone 2.3.3.4 -> 2.3.4 -> 2.3.4.1 over the years, mirroring the official osc as new versions come out.


This is a signature that appears on all my posts.  
IF YOU MAKE A POST REQUESTING HELP...please state the exact version
of osCommerce that you are using. THANKS

 
Get the latest Responsive osCommerce CE (community edition) here

Share this post


Link to post
Share on other sites

Well it look like all the errors were caused by the group update addon! I thought I had done all the conversion to BS  and its stabe when using it, but clearly its still not happy.

if (BUS_ENABLE_DELETE == 1){ // add Delete to select box

Dont uderstand why as this is defined in /languages/english/orders.php 

 


 

Share this post


Link to post
Share on other sites

Can confirm that all the    "Warning: sizeof(): Parameter must be an array or an object that implements Countable in" errors stop when running PHP7.1 One Edge.


 

Share this post


Link to post
Share on other sites

Whether it calls itself 2.3.4 or 2.3.4.1 would depend on when Zahid picked up a copy and installed it. Awfully confusing to claim to be the "official" version number, but I guess there are reasons. I have no problem with keeping the code upgraded in sync with the official release, but I have my doubts about not having a unique version number (not to mention having to version 2.3.4BS by date rather than a built-in version number). If 2.3.6 is ever released, I guess it will be moot at that point. I have seen people install 2.3.4 or 2.3.4.1 plus a Bootstrap responsive add-on or template, and then ask for support in this 2.3.4BS area, so it's confusing to many.

Share this post


Link to post
Share on other sites

TY @beerbee for spotting a problem.
TY @BrockleyJohn for the PR.

https://github.com/gburton/Responsive-osCommerce/commit/98cdc6828c224ff957899d9abfeae7a387cb0db4

It is not a showstopper; after all, no one has noticed a problem in years
However, it would be wise to take the time to update this particular file asap.
 


This is a signature that appears on all my posts.  
IF YOU MAKE A POST REQUESTING HELP...please state the exact version
of osCommerce that you are using. THANKS

 
Get the latest Responsive osCommerce CE (community edition) here

Share this post


Link to post
Share on other sites

I have a very old, heavily modified osc site. Working perfectly fine for me but I need to upgrade the code(have some from 10 years ago!). I'm confused on all the releases. Do I want to do the 2.3.4.1 boot strap version or the 2.3.4.1 downloaded from the osc site? 

I have downloaded Responsive Oscommerce Master which has a zip date of 2/4/18. Is this the one I should start working with?

Can I run this with php7?  I believe my current sites code will not let me upgrade it from php5. 

My biggest fear is that I have a massive images folder. Is there something for BS which will organize that folder?

Share this post


Link to post
Share on other sites
Guest
This topic is now closed to further replies.

×