Post by jsling » Thu Jan 18, 2024 10:48 am

When attempting to search for text containing double quotes (") , an error screen is displayed.


Error occur at common/language.php -> $this->url->link($route, 'language=' . $result['code'] . $url, true)

Code: Select all

		foreach ($results as $result) {
			$this->config->set('config_language_id', $result['language_id']);


			$data['languages'][] = [
				'name'  => $result['name'],
				'code'  => $result['code'],
				'image' => $result['image'],
				'href'  => $this->url->link($route, 'language=' . $result['code'] . $url, true)
			];
		}

Attachments

oc_error01.png

oc_error01.png (12.43 KiB) Viewed 2793 times

Last edited by jsling on Thu Jan 18, 2024 10:51 am, edited 1 time in total.

Newbie

Posts

Joined
Wed Jun 12, 2013 11:58 am

Post by Cue4cheap » Thu Jan 18, 2024 10:50 am

What OC version?
Looks like a test site... did you do a basic install without any modifications?
Mike

cue4cheap not cheap quality


Expert Member

Posts

Joined
Fri Sep 20, 2013 4:45 am

Post by jsling » Thu Jan 18, 2024 10:54 am

Version 4.
It also happen on the demo https://demo.opencart.com/

Newbie

Posts

Joined
Wed Jun 12, 2013 11:58 am

Post by Cue4cheap » Thu Jan 18, 2024 11:38 am

jsling wrote:
Thu Jan 18, 2024 10:54 am
Version 4.
It also happen on the demo https://demo.opencart.com/
"Version 4" What? Right now the latest is 4.0.2.3 and there are 6 prior versions.

cue4cheap not cheap quality


Expert Member

Posts

Joined
Fri Sep 20, 2013 4:45 am

Post by jsling » Thu Jan 18, 2024 3:55 pm

Yes. I using version 4.0.2.3.

Newbie

Posts

Joined
Wed Jun 12, 2013 11:58 am

Post by jsling » Thu Jan 18, 2024 6:27 pm

Found the log..
2024-01-18 18:23:35 - PHP Warning: Undefined array key 1 in /home/public_html/catalog/controller/startup/seo_url.php on line 73

Newbie

Posts

Joined
Wed Jun 12, 2013 11:58 am

Post by jsling » Thu Jan 18, 2024 6:54 pm

fixed the issues by modifying this code
catalog/controller/startup/seo_url.php line 70

Code: Select all

		$parts = explode('&', $url_info['query']);    

Code: Select all

		$parts = explode('&', html_entity_decode($url_info['query']));    

Newbie

Posts

Joined
Wed Jun 12, 2013 11:58 am

Post by ADD Creative » Fri Jan 19, 2024 7:00 pm

The problem is probably related to the way catalog/controller/common/currency.php and catalog/controller/common/language.php build the redirect URLs.

www.add-creative.co.uk


Guru Member

Posts

Joined
Sat Jan 14, 2012 1:02 am
Location - United Kingdom
Who is online

Users browsing this forum: No registered users and 1 guest