Code Monkey home page Code Monkey logo

opencart-3's Introduction

OpenCart

Overview

Minimum PHP Version GitHub release Lint

OpenCart is a free open source e-commerce platform for online merchants. OpenCart provides a professional and reliable foundation from which to build a successful online store.

How to install

Please read the installation instructions included in the repository or download file.

How to upgrade from previous versions

Please read the upgrading instructions included in the repository or download file.

Reporting a bug

Read the instructions below before you create a bug report.

  1. Search the OpenCart forum, ask the community if they have seen the bug or know how to fix it.
  2. Check all open and closed issues on the GitHub bug tracker.
  3. If your bug is related to the OpenCart core code then please create a bug report on GitHub.
  4. READ the changelog for the master branch
  5. Use Google to search for your issue.
  6. Make sure that your bug/issue is not related to your hosting environment.

If you are not sure about your issue, it is always best to ask the community on our bug forum thread

Important!

  • If your bug report is not related to the core code (such as a 3rd party module or your server configuration) then the issue will be closed without a reason. You must contact the extension developer, use the forum or find a commercial partner to resolve a 3rd party code issue.
  • If you would like to report a serious security bug please PM an OpenCart moderator/administrator on the forum. Please do not report concept/ideas/unproven security flaws - all security reports are taken seriously but you must include the EXACT details steps to reproduce it. Please DO NOT post security flaws in a public location.

How to contribute

Fork the repository, edit and submit a pull request.

Please be very clear on your commit messages and pull request, empty pull request messages may be rejected without reason.

Your code standards should match the OpenCart coding standards. We use an automated code scanner to check for most basic mistakes - if the test fails your pull request will be rejected.

How to run the application Locally (Docker Image)

Windows OS

  • make sure you have Docker Desktop installed on your Local Machine
  • in the terminal in the file containing the projects run docker-compose up -d

Versioning

The version is broken down into 4 points e.g 1.2.3.4 We use MAJOR.MINOR.FEATURE.PATCH to describe the version numbers.

A MAJOR is very rare, it would only be considered if the source was effectively re-written or a clean break was desired for other reasons. This increment would likely break most 3rd party modules.

A MINOR is when there are significant changes that affect core structures. This increment would likely break some 3rd party modules.

A FEATURE version is when new extensions or features are added (such as a payment gateway, shipping module etc). Updating a feature version is at a low risk of breaking 3rd party modules.

A PATCH version is when a fix is added, it should be considered safe to update patch versions e.g 1.2.3.4 to 1.2.3.5

Releases

OpenCart will announce to developers 1 week prior to public release of FEATURE versions, this is to allow for testing of their own modules for compatibility. For bigger releases (ones that contain many core changes, features and fixes) an extended period will be considered following an announced release candidate (RC). Patch versions (which are considered safe to update with) may have a significantly reduced developer release period.

The master branch will always contain an "_rc" postfix of the next intended version. The next "_rc" version may change at any time.

Developer release source code will not change once tagged.

If a bug is found in an announced developer release that is significant (such as a major feature is broken) then the release will be pulled. A patch version will be issued to replace it, depending on the severity of the patch an extended testing period may be announced. If the developer release version was never made public then the preceding patch version tag will be removed.

To receive developer notifications about release information, sign up to the newsletter on the OpenCart website - located in the footer. Then choose the developer news option.

License

GNU General Public License version 3 (GPLv3)

Links

opencart-3's People

Contributors

addcreative avatar ajenbo avatar code-factor avatar condor2 avatar danielkerr avatar jigius avatar marvinklein1508 avatar mathsolutions avatar mhcwebdesign avatar opencartcomvn avatar pemaier avatar rasulsh avatar thecartpenter avatar turzo333 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

opencart-3's Issues

PHP8.1+ Required

Should not require PHP 8. should be put back to 5.4 or create new version of open cart.

Maintenance mode not working

I have recently intalled OC 3.0.3.8 via Maintenance branch to work with PHP 8.1.

As I'm starting to setup my store, I put it in maintenance mode the local and online stores but, the maintenance mode page/message isn't working. My store remains with the normal navigation.

Here I setup de maintenance mode:
imagen

Here is the online and local store without any message:

imagen

Klarna payment

Because Klarna library is deprecated this payment should be removed.

PHP Unknown: preg_replace()

Account link
/index.php?route=account/subscription
The show error
PHP Unknown: preg_replace(): Passing null to parameter #3 ($subject) of type array|string is deprecated in /system/engine/action.php on line 61

ArgumentCountError: Too few arguments to function

With SMTP enabled

ArgumentCountError: Too few arguments to function Mail\Smtp::__construct(), 0 passed in system\library\mail.php on line 35 and exactly 1 expected in system\library\mail\smtp.php on line 20

Estimate Shipping & taxes

2022-10-12 07:26:22 - Error: Call to undefined method Cart\Tax::unsetRates() in catalog\controller\extension\total\shipping.php on line 71

Why both Recurring and Subscriptions?

Hi,
Please check why both Recurring and Subscriptions?

sudo apt install rename

find . -exec rename 's/recurring/subscription_plan/' {} ";"

find ./ -type f -readable -writable -exec sed -i "s/Recurring/SubscriptionPlan/g" {} \;

find ./ -type f -readable -writable -exec sed -i "s/recurring/subscription_plan/g" {} \;

Moving storage folder does not work

After a fresh installation and the first login to admin you'll be promted to move your storage folder.

When clicking on apply, the config.php will be changed and an empty folder will be created. However, the files from system/storage won't be moved and the shop is broken.

Warning: require_once(C:/xampp/storage/vendor/symfony/polyfill-ctype/bootstrap.php): Failed to open stream: No such file or directory in C:\xampp\htdocs\system\vendor.php on line 19

Fatal error: Uncaught Error: Failed opening required 'C:/xampp/storage/vendor/symfony/polyfill-ctype/bootstrap.php' (include_path='C:\xampp\php\PEAR') in C:\xampp\htdocs\system\vendor.php:19 Stack trace: #0 C:\xampp\htdocs\system\framework.php(5): require_once() #1 C:\xampp\htdocs\system\startup.php(107): require_once('C:\\xampp\\htdocs...') #2 C:\xampp\htdocs\admin\index.php(19): start('admin') #3 {main} thrown in C:\xampp\htdocs\system\vendor.php on line 19

Type parameters error in google when you checkout as customer

TypeError: ControllerExtensionAdvertiseGoogle::before_checkout_success(): Argument #2 ($data) must be of type array, null given, called in system\storage\modification\system\engine\action.php on line 75 in catalog\controller\extension\advertise\google.php on line 41

Cannot install

Hi,
Please check
Cannot install with your latest commit

Wrong linking to account/affiliate

In both the footer and the account panel the links go to account/affiliate. However this controller has no index function which results in an issue in routing:

TypeError: Cannot assign null to property Router::$error of type object in /home/webpages/lima-city/marvinkleinmusic/opencart/system/engine/router.php on line 75

For example:
https://opencart.marvinkleinmusic.de/index.php?route=account/affiliate&customer_token=ZYtncbCKYLgQZ82k5c4zi75Qor

In the account panel it should either redirect to account/affiliate/add or account/affiliate/edit

In the footer it should link to affliate/login

Otherwise nobody can signup for the affiliate program.

No releases?

Just a short question: why is there no release published?

Reason why I ask: more and more people are asking for a php 8.x compatible OpenCart 3.0.3.8
And find at least this repo, but without any release it may be hard to install.
Or at least - if no releases will be published, publish a short description for those, are not firm with Github.

And state in the readme that this repo IS compatible with php 8.x (8.1.x).
And an official fork of the original.

Custom filed missing escap, strange UTF-8 chars in custom fileds

Affected version 3.0.3.7
(maybe exist on lower versions)

File (original)
in catalog\model\checkout\order.php
line 4
insert query 3 times account, shipping payment
looks like this

..custom_field = '" . $this->db->escape(isset($data['custom_field']) ? json_encode($data['custom_field']) : '') . "',...
Wrong!

this is the right way
...custom_field = '" . (isset($data['custom_field']) ? $this->db->escape(json_encode($data['custom_field']) : '')) . "',...

Like chars like éáűőúöüóí it save to DB like u00e9u00e1u0151
without slash and json_encode cant' translate it back.

Bug in Extension Installer

Opencart version 3.0.3.9
Default Theme

Operating System
CentOS v7.9.2009

Server type: MySQL
Server version: 5.7.41

PHP Version ea-php81

Installing a extension from opencart marketplace "PDF Invoice Pro For Orders" https://www.opencart.com/index.php?route=marketplace/extension/info&extension_id=22647&filter_search=PDF%20Invoice%20Pro%20For%20Orders
Installed the extension via Extension Installer the message was showing successful but Extension/extension> Module doesn't show any extension to installed.
image

Same happened with other extension Atome payment.

Only the OCMOD file shows up in modifications.
image

Admin custom_fields bug when a Customer is edited

If a customer has 2 custom_fields: one is for Account (named custom_field_account) second is for Affiliate (named custom_field_affiliate)
When customer is edited and both custom_fields are filled in with values, these values are inserted together in database in both tables.

customer table
customer_affiliate table
When custom_field_account value should be inserted only in customer table and custom_field_affiliate value should be inserted only in customer_affiliate table.

Or I think is much better to change admin affiliate structure like in 4.0 Marketing->Affiliate

mail sender smtp not working

Hello, if I select mail from settings->store->mail, not sending email to customer for new order confirmation. If I try to set smtp, not working (page show alert "error" and connection refused in logs). But server config is right because working with same parameters in Windows Mail Client!! I have try ssl:// and tls://, provider instructions says port 465 for smtp server. Also I try without suffix with no luck. I want only send email confirmation to customer when new order success!

Notice: Undefined property: Proxy::getExtensionsByType

index.php?route=checkout/checkout

Notice: Undefined property: Proxy::getExtensionsByType in \system\engine\loader.php on line 243
#########################################
PHP Unknown: preg_replace(): Passing null to parameter #3 ($subject) of type array|string is deprecated in \system\engine\action.php on line 61
#########################################
Exception: Error: Could not load model catalog/subscription!
admin/index.php?route=catalog/product/edit
admin\controller\catalog\product.php
Line 700
// Subscription
$this->load->model('catalog/subscription');

    $data['subscriptions'] = $this->model_catalog_subscriptions->getSubscriptions();

##########################################
Warning: You do not have permission to modify subscription plans!
admin\controller\catalog\subscription_plan.php
Line 472
protected function validateForm() {
if (!$this->user->hasPermission('modify', 'catalog/subscription')) {
$this->error['warning'] = $this->language->get('error_permission');
}

##########################################
Notice: Undefined property: Proxy::addSubscription in
##########################################

Add, Get - Scripts, Styles position Footer

Hi,
system/library/document.php
Oder version can add script and style to header and footer from controller

$this->document->addScript('catalog/view/javascript/jquery/magnific/jquery.magnific-popup.min.js', 'header');
$this->document->addStyle('catalog/view/javascript/jquery/magnific/magnific-popup.css', 'footer');

But not work with this version and MB

[<b>Warning</b>: Array to string conversion in]

Please check

how to combine duplicate custom_field name with value opencart version 3038?

how to combine duplicate custom_field name with value opencart version 3038?
admin=>order info=>Account Custom Fields
before combination:
Account Custom Fields
color yellow
color green
color red
image 3ba9557e23ecb68b0152683e2623dd72907bdfff
image MPX2102AP.jpg
size big
size small
after combination, the chart will show like:
Account Custom Fields
color: yellow,green,red
image: 3ba9557e23ecb68b0152683e2623dd72907bdfff, MPX2102AP.jpg
size: big, small
how to do it?
combine

Edit order does not change currency selected on step 1

What version of OpenCart are you reporting this for?

3.0.3.8

Describe the bug
There is 5 steps of edit order: on first one change currency, on step 2 you see product(s) with correct new currency and on final step 5 is all visible in new currency (no problem) but clicking save opencart confirm saving on green background but email comes with previous currency, in databse there are not updated columns: currency_id, currency_code, currency_value.

To Reproduce

Go to any order and choose edit ( I did fresh install of 3.0.3.8 made one order in default USD and tried to change that into EUR)
on Step 1 change currency into whatever (EUR on my case)
Save on step 5
See error - no error, but return to that order, still in previous currency
Expected behavior
order in new currency

Server / Test environment (please complete the following information):

Local development? Deployed to a web server? - local docker + web server
Operating system - linux
PHP version - 7.3.32
Apache version - 2.4.51 debian
Browser(s) tested with [e.g. chrome, safari - if applicable] - opera, chrome, edge
Additional context
in the API edit function in catalog/controller/api/order.php and model_checkout_order->editOrder there is nothing that sets the currency when updating an order.

Installer doesn't work

Fatal error: Uncaught TypeError:

Argument 1 passed to Session\File::__construct() must be an instance of Session\Registry, instance of Registry given, called in system\library\session.php on line 29 and defined in system\library\session\file.php:4

Stack trace:

0 system\library\session.php(29): Session\File->__construct(Object(Registry))
1 system\framework.php(88): Session->__construct('file', Object(Registry))
2 system\startup.php(104): require_once('...')
3 install\index.php(37): start('install')
4 {main} thrown in system\library\session\file.php on line 4

Undefined array key "extension" in

Undefined array key "extension" in
catalog/model/checkout/payment_method.php on line 12
catalog/model/checkout/shipping_method.php on line 12

ArgumentCountError: Too few arguments to function getMethod(),

PHP 8.1 errors

HI.
upgrading a current staging installation from 3.0.3.6 to 3.0.3.8 I found the following errors
Steps to reproduce:
Navigated to the folder installation.

  1. Run composer update
  2. <store.local>/install
  3. Finish installation (many errors encounter with the current opencart.sql ) I had to adjust this manually (push request on the way)
  4. Navigate to the store and /admin area
  5. Errors:
  6. PHP Unknown: preg_match(): Passing null to parameter #4 ($flags) of type int is deprecated in /home/user/storage/vendor/scssphp/scssphp/src/Parser.php on line 1151
  7. PHP Unknown: preg_match(): Passing null to parameter #4 ($flags) of type int is deprecated in/home/user/storage/vendor/scssphp/scssphp/src/Parser.php on line 1232
  8. Automatic conversion of false to array is deprecated in /home/user/storage/modification/catalog/controller/startup/startup.php on line 115
  9. PHP Unknown: strpos(): Passing null to parameter #1 ($haystack) of type string is deprecated in /home/user/storage/modification/catalog/controller/startup/seo_url.php on line 60
  10. PHP Unknown: Return type of Twig\Markup::count() should either be compatible with Countable::count(): int, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home/user/storage/vendor/twig/twig/src/Markup.php on line 35
  11. PHP Unknown: Return type of Twig\Markup::jsonSerialize() should either be compatible with JsonSerializable::jsonSerialize(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home/user/storage/vendor/twig/twig/src/Markup.php on line 40

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.