1: How do I change the text of various buttons? Say I am wanting to change the button "continue" to "home".
Solved
2: I am wanting to remove the Payment option in checkout as customers are buying the product via company account. How would I skip this process? I have seen a topic for this already but didn't quite understand it.
3: I am using a custom template and I am having a problem with my search page. Everything works fine until you enter a search term, then my template goes all up the wop. Can anyone tell me what I'm doing wrong?
link to search page: http://www.linkuppaints.co.nz/eshop/ind ... uct/search
Solved
4: I am only wanting current customers to login. Is there anyway to remove the option for registering/creating a new account? I will be investing in the CUSTOMER LOGIN SCREEN (OPENCART ADDON) in the near future, but until then. Solved
5: In my product details, can I change "model" to "code"?
Solved
6: When adding a customer to my list with the admin panel, is there anyway I can add a customers address etc myself? And also how do I change the telephone number from being a required field. All from the admin side.
Solved
7: How do I edit the text in the login page saying "I am a returning customer"?
Solved
8: For my manufacturers, why am I uploading a logo for them? What is it used for? And also can I make a page for them that when you click on the brand name it tells you about the brand above the products section?
Solved
10: Can I make a product quantity unlimited? And if so, how?
Solved
11: When creating a customer, can I change the "First name" and "Last name" to just be "Customer"? If so, how would I do this?
Solved
Sorry the list is so long
Thats all I can think of for now
Thanks heaps for this amazing product. (Content removed).
http://dpDesignz.webs.com Web & Publication Designer
Have a look at the top level language file eg. "catalog/language/english/english.php". You'll find the button text defined there.1: How do I change the text of various buttons? Say I am wanting to change the button "continue" to "home".
As you stated, there is a topic about this on the forum somewhere (I can remember seeing it). But, from what I remember, it was working for some but not for others. Without trying it myself, I can't give any advice on this one.2: I am wanting to remove the Payment option in checkout as customers are buying the product via company account. How would I skip this process? I have seen a topic for this already but didn't quite understand it.
Looks like you might have a closing </div> too mahy in your "catalog/view/theme/YOUR_TEMPLATE/template/common/header.tpl". Find the line that starts with the following:-3: I am using a custom template and I am having a problem with my search page. Everything works fine until you enter a search term, then my template goes all up the wop. Can anyone tell me what I'm doing wrong?
link to search page: http://www.linkuppaints.co.nz/eshop/ind ... uct/search
Code: Select all
<div class="div3">
Easiest way is to remove lines 18 to 45 in "catalog/view/theme/YOUR_TEMPLATE/account/login.tpl". At least, it's lines 18 to 45 in the default.4: I am only wanting current customers to login. Is there anyway to remove the option for registering/creating a new account?
Modules for OpenCart 2.3.0.2
Homepage Module [Free - since OpenCart 0.7.7]
Multistore Extensions
Store Manager Multi-Vendor/Multi-Store management tool
If you're not living on the edge ... you're taking up too much space!
I found that more files then I though came under this category. Is there anyway for me to redo only some of them with the new code? Example when I'm in my profile etc, it has continue which redirects to the homepage, but when I go to check something out it also has the same button "continue". Is there any way to make a new button but have it do the same thing? I don't know if that's explained clearly.Have a look at the top level language file eg. "catalog/language/english/english.php". You'll find the button text defined there.
That's fine, I'm sure I'll find it again sometime.As you stated, there is a topic about this on the forum somewhere (I can remember seeing it). But, from what I remember, it was working for some but not for others. Without trying it myself, I can't give any advice on this one
I have this fine, and it all works until I input something and then press enter, then the page goes strange.Looks like you might have a closing </div> too mahy in your "catalog/view/theme/YOUR_TEMPLATE/template/common/header.tpl". Find the line that starts with the following:-
CODE: SELECT ALL
<div class="div3">
and remove one of the "</div>" tags at the end of this line.
example:
http://www.linkuppaints.co.nz/eshop/ind ... egory_id=0
Here's the code in my header.tpl file:
Code: Select all
<?php $path_theme = "catalog/view/theme/Linkup";?>
<?php echo '<?xml version="1.0" encoding="UTF-8"?>' . "\n"; ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" dir="<?php echo $direction; ?>" lang="<?php echo $lang; ?>" xml:lang="<?php echo $lang; ?>">
<head>
<title><?php echo $title; ?></title>
<?php if ($description) { ?>
<meta name="description" content="<?php echo $description; ?>" />
<?php } ?>
<base href="<?php echo $base; ?>" />
<?php if ($icon) { ?>
<link href="image/<?php echo $icon; ?>" rel="icon" />
<?php } ?>
<link rel="stylesheet" type="text/css" href="<?=$path_theme;?>/stylesheet/stylesheet.css" />
<link rel="stylesheet" type="text/css" href="<?=$path_theme;?>/stylesheet/style.css" />
<!--[if lt IE 7]>
<link rel="stylesheet" type="text/css" href="<?=$path_theme?>/stylesheet/ie6.css" />
<script type="text/javascript" src="catalog/view/javascript/unitpngfix/unitpngfix.js"></script>
<![endif]-->
<script type="text/javascript" src="catalog/view/javascript/jquery/jquery-1.3.2.min.js"></script>
<script type="text/javascript" src="catalog/view/javascript/jquery/thickbox/thickbox-compressed.js"></script>
<link rel="stylesheet" type="text/css" href="catalog/view/javascript/jquery/thickbox/thickbox.css" />
<script type="text/javascript" src="catalog/view/javascript/jquery/tab.js"></script>
</head>
<body>
<div id="container">
<div id="header">
<div class="div1">
<div class="div2"><a href="<?php echo $home; ?>"><img src="<?php echo $logo; ?>" title="<?php echo $store; ?>" alt="<?php echo $store; ?>" /></a></div>
<div class="div3"><?php echo $entry_search; ?>
<?php if ($keyword) { ?>
<input type="text" value="<?php echo $keyword; ?>" id="filter_keyword" />
<?php } else { ?>
<input type="text" value="<?php echo $text_keyword; ?>" id="filter_keyword" onclick="this.value = '';" onkeydown="this.style.color = '#000000'" style="color: #999;" />
<a onclick="moduleSearch();" class="button"><span><?php echo $button_go; ?></span></a> <br><div align="center" ><a href="<?php echo str_replace('&', '&', $advanced); ?>"><?php echo $text_advanced; ?></a></div></div>
<?php } ?>
</div>
<div class="div4">
<div class="menu">
<ul>
<li><a href="<?php echo $home; ?>"><?php echo $text_home; ?></a></li>
<li><a href="<?php echo $account; ?>"><?php echo $text_account; ?></a></li>
<li>
<?php if (!$logged) { ?>
<a href="<?php echo $login; ?>"><?php echo $text_login; ?></a>
<?php } else { ?>
<a href="<?php echo $logout; ?>"><?php echo $text_logout; ?></a>
<?php } ?>
</li>
</ul>
</div>
</div>
<div id="breadcrumb">
<div class="div5">
<?php foreach ($breadcrumbs as $breadcrumb) { ?>
<a href="<?php echo $breadcrumb['href']; ?>"><?php echo $breadcrumb['text']; ?></a><img src="<?=$path_theme?>/image/tab.png" alt="" class="split" />
<?php } ?>
</div>
<div class="div6">
<img src="<?=$path_theme?>/image/icon_checkout.png" alt="" class="icon" /><a href="<?php echo $checkout; ?>"><?php echo $text_checkout; ?></a>
<img src="<?=$path_theme?>/image/icon_basket.png" alt="" class="icon" /><a href="<?php echo $cart; ?>"><?php echo $text_cart; ?></a>
</div>
</div>
</div>
<script type="text/javascript"><!--
$('#module_search input').keydown(function(e) {
if (e.keyCode == 13) {
moduleSearch();
}
});
function moduleSearch() {
url = 'index.php?route=product/search';
var filter_keyword = $('#filter_keyword').attr('value')
if (filter_keyword) {
url += '&keyword=' + encodeURIComponent(filter_keyword);
}
var filter_category_id = $('#filter_category_id').attr('value');
if (filter_category_id) {
url += '&category_id=' + filter_category_id;
}
location = url;
}
//--></script>
<script type="text/javascript"><!--
$('.switcher').bind('click', function() {
$(this).find('.option').slideToggle('fast');
});
//--></script>
Thanks so much for this. Worked great.Easiest way is to remove lines 18 to 45 in "catalog/view/theme/YOUR_TEMPLATE/account/login.tpl". At least, it's lines 18 to 45 in the default.
I have also added two more questions to the original post. Can you help at all with those?
Thank you so much for your help.
http://dpDesignz.webs.com Web & Publication Designer
You could leave the continue button as is in the language file and add in the following:-dpDesignz wrote:Is there anyway for me to redo only some of them with the new code?
Code: Select all
$_['button_home'] = 'Home';
Code: Select all
$this->data['button_continue'] = $this->language->get('button_continue');
Code: Select all
$this->data['button_continue'] = $this->language->get('button_home');
Code: Select all
<?php $path_theme = "catalog/view/theme/Linkup";?>
<?php echo '<?xml version="1.0" encoding="UTF-8"?>' . "\n"; ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" dir="<?php echo $direction; ?>" lang="<?php echo $lang; ?>" xml:lang="<?php echo $lang; ?>">
<head>
<title><?php echo $title; ?></title>
<?php if ($description) { ?>
<meta name="description" content="<?php echo $description; ?>" />
<?php } ?>
<base href="<?php echo $base; ?>" />
<?php if ($icon) { ?>
<link href="image/<?php echo $icon; ?>" rel="icon" />
<?php } ?>
<link rel="stylesheet" type="text/css" href="<?=$path_theme;?>/stylesheet/stylesheet.css" />
<link rel="stylesheet" type="text/css" href="<?=$path_theme;?>/stylesheet/style.css" />
<!--[if lt IE 7]>
<link rel="stylesheet" type="text/css" href="<?=$path_theme?>/stylesheet/ie6.css" />
<script type="text/javascript" src="catalog/view/javascript/unitpngfix/unitpngfix.js"></script>
<![endif]-->
<script type="text/javascript" src="catalog/view/javascript/jquery/jquery-1.3.2.min.js"></script>
<script type="text/javascript" src="catalog/view/javascript/jquery/thickbox/thickbox-compressed.js"></script>
<link rel="stylesheet" type="text/css" href="catalog/view/javascript/jquery/thickbox/thickbox.css" />
<script type="text/javascript" src="catalog/view/javascript/jquery/tab.js"></script>
</head>
<body>
<div id="container">
<div id="header">
<div class="div1">
<div class="div2"><a href="<?php echo $home; ?>"><img src="<?php echo $logo; ?>" title="<?php echo $store; ?>" alt="<?php echo $store; ?>" /></a></div>
<div class="div3"><?php echo $entry_search; ?>
<?php if ($keyword) { ?>
<input type="text" value="<?php echo $keyword; ?>" id="filter_keyword" />
<?php } else { ?>
<input type="text" value="<?php echo $text_keyword; ?>" id="filter_keyword" onclick="this.value = '';" onkeydown="this.style.color = '#000000'" style="color: #999;" />
<a onclick="moduleSearch();" class="button"><span><?php echo $button_go; ?></span></a> <br>
<div align="center" ><a href="<?php echo str_replace('&', '&', $advanced); ?>"><?php echo $text_advanced; ?></a></div>
<?php } ?>
</div>
<div class="div4">
<div class="menu">
<ul>
<li><a href="<?php echo $home; ?>"><?php echo $text_home; ?></a></li>
<li><a href="<?php echo $account; ?>"><?php echo $text_account; ?></a></li>
<li><?php if (!$logged) { ?>
<a href="<?php echo $login; ?>"><?php echo $text_login; ?></a>
<?php } else { ?>
<a href="<?php echo $logout; ?>"><?php echo $text_logout; ?></a>
<?php } ?></li>
</ul>
</div>
</div>
<div id="breadcrumb">
<div class="div5">
<?php foreach ($breadcrumbs as $breadcrumb) { ?>
<a href="<?php echo $breadcrumb['href']; ?>"><?php echo $breadcrumb['text']; ?></a><img src="<?=$path_theme?>/image/tab.png" alt="" class="split" />
<?php } ?>
</div>
<div class="div6">
<img src="<?=$path_theme?>/image/icon_checkout.png" alt="" class="icon" /><a href="<?php echo $checkout; ?>"><?php echo $text_checkout; ?></a>
<img src="<?=$path_theme?>/image/icon_basket.png" alt="" class="icon" /><a href="<?php echo $cart; ?>"><?php echo $text_cart; ?></a>
</div>
</div>
</div>
<script type="text/javascript"><!--
$('#module_search input').keydown(function(e) {
if (e.keyCode == 13) {
moduleSearch();
}
});
function moduleSearch() {
url = 'index.php?route=product/search';
var filter_keyword = $('#filter_keyword').attr('value')
if (filter_keyword) {
url += '&keyword=' + encodeURIComponent(filter_keyword);
}
var filter_category_id = $('#filter_category_id').attr('value');
if (filter_category_id) {
url += '&category_id=' + filter_category_id;
}
location = url;
}
//--></script>
<script type="text/javascript"><!--
$('.switcher').bind('click', function() {
$(this).find('.option').slideToggle('fast');
});
//--></script>
Two? I counted six extra questions.I have also added two more questions to the original post. Can you help at all with those?
Look in the corresponding language file (catalog/language/english/product/product.php), and change:5: In my product details, can I change "model" to "code"?
Code: Select all
$_['text_model'] = 'Model:';
Code: Select all
$_['text_model'] = 'Code:';
There isn't any way in the default to add a customer's address, but there is a mod (or some instructions) somewhere, either on the forum (I don't know where - but I have seen it mentioned) or at the OpenCart extensions pages.6: When adding a customer to my list with the admin panel, is there anyway I can add a customers address etc myself? And also how do I change the telephone number from being a required field. All from the admin side.
To change the telphone from being a required field, you will have to remove or comment the validation in "admin/controller/sale/customer.php", lines 816 to 818:
Code: Select all
if ((strlen(utf8_decode($this->request->post['telephone'])) < 3) || (strlen(utf8_decode($this->request->post['telephone'])) > 32)) {
$this->error['telephone'] = $this->language->get('error_telephone');
}
Look in the corresponding language file (catalog/language/english/account/login.php).7: How do I edit the text in the login page saying "I am a returning customer"?
Good question, since the logo isn't used at all.8: For my manufacturers, why am I uploading a logo for them? What is it used for? And also can I make a page for them that when you click on the brand name it tells you about the brand above the products section?
The manufacturer table in the database also has no description field or associated "manufacturer_description" table for the purpose of storing this information. Somewhere in this forum, there is a mod to provide some form of manufacturer description (although it has no language independence).
Not that I'm aware of, apart from adding to the session data or cookies. But, session data is only stored for the "session", and cookies can be deleted by the customer, since they are stored on the customer's computer. I suppose it could be possible to add an extra field to the customer table to store the page there were last on, BUT that is most likely to be the "Account Logout" page. However, a function could be used for the purpose. BUT, the customer might not want to go back to the "Checkout Success" page either.9: When a customer logs in, is there any way to make them go to the last page they were at?
In the product entry form, eave the default quantity at "1" and, under "System->Setting", under the "Option" tab, set "Stock Subtract" to "No".10: Can I make a product quantity unlimited? And if so, how?
Modules for OpenCart 2.3.0.2
Homepage Module [Free - since OpenCart 0.7.7]
Multistore Extensions
Store Manager Multi-Vendor/Multi-Store management tool
If you're not living on the edge ... you're taking up too much space!
Thanks. This helped alot.You could leave the continue button as is in the language file and add in the following:-
CODE: SELECT ALL
$_['button_home'] = 'Home';
Then, in the controller files where you want the button to say "Home", change:
CODE: SELECT ALL
$this->data['button_continue'] = $this->language->get('button_continue');
to:
CODE: SELECT ALL
$this->data['button_continue'] = $this->language->get('button_home');
That stuffed up all my pages now, not just the search results page.With regard to your header template file, as I said, you have a "</div>" too many which isn't seen until you do a search. This is because it is hidden away inside an if/else statement. Try using this and see how you go:
Sorry. I'm adding them as I think of them. I will make a new post from now on.Two? I counted six extra questions.
BIG HELP!Look in the corresponding language file (catalog/language/english/product/product.php), and change:
CODE: SELECT ALL
$_['text_model'] = 'Model:';
to:
CODE: SELECT ALL
$_['text_model'] = 'Code:';
Thanks. I have just found out that this will be in the next release.6: When adding a customer to my list with the admin panel, is there anyway I can add a customers address etc myself? And also how do I change the telephone number from being a required field. All from the admin side.
There isn't any way in the default to add a customer's address, but there is a mod (or some instructions) somewhere, either on the forum (I don't know where - but I have seen it mentioned) or at the OpenCart extensions pages.
To change the telphone from being a required field, you will have to remove or comment the validation in "admin/controller/sale/customer.php", lines 816 to 818:
CODE: SELECT ALL
if ((strlen(utf8_decode($this->request->post['telephone'])) < 3) || (strlen(utf8_decode($this->request->post['telephone'])) > 32)) {
$this->error['telephone'] = $this->language->get('error_telephone');
}
Thank you very much.7: How do I edit the text in the login page saying "I am a returning customer"?
Look in the corresponding language file (catalog/language/english/account/login.php).
Thanks. Perhaps it will be integrated later on. But as for the images, here is something that I found it can go with. http://theqdomain.com/ocstore/manu_select_images8: For my manufacturers, why am I uploading a logo for them? What is it used for? And also can I make a page for them that when you click on the brand name it tells you about the brand above the products section?
Good question, since the logo isn't used at all.
The manufacturer table in the database also has no description field or associated "manufacturer_description" table for the purpose of storing this information. Somewhere in this forum, there is a mod to provide some form of manufacturer description (although it has no language independence).
Thanks. Have also decided against this one as the integrated login will not be used by me soon anyway.9: When a customer logs in, is there any way to make them go to the last page they were at?
Not that I'm aware of, apart from adding to the session data or cookies. But, session data is only stored for the "session", and cookies can be deleted by the customer, since they are stored on the customer's computer. I suppose it could be possible to add an extra field to the customer table to store the page there were last on, BUT that is most likely to be the "Account Logout" page. However, a function could be used for the purpose. BUT, the customer might not want to go back to the "Checkout Success" page either.
Yet again, thanks a heap. You are a great help fido-x, and I hope any of my questions and your answers will also help others. Cheers10: Can I make a product quantity unlimited? And if so, how?
In the product entry form, eave the default quantity at "1" and, under "System->Setting", under the "Option" tab, set "Stock Subtract" to "No".
http://dpDesignz.webs.com Web & Publication Designer
Solved
http://dpDesignz.webs.com Web & Publication Designer
Umm, yes. You can change the "First Name" to "Customer" in the language file(s), but you would also have to remove the "Last Name" in the template file(s) and remove the validation in the controller(s).dpDesignz wrote:11: When creating a customer, can I change the "First name" and "Last name" to just be "Customer"? If so, how would I do this?
You'll note the (s) on the end of the word "file". That's because there are several files to modify. You've got the controllers for account/create, account/edit, account/address, checkout/address, checkout/guest_step_1, their associated language files, and their template files.
Modules for OpenCart 2.3.0.2
Homepage Module [Free - since OpenCart 0.7.7]
Multistore Extensions
Store Manager Multi-Vendor/Multi-Store management tool
If you're not living on the edge ... you're taking up too much space!
http://dpDesignz.webs.com Web & Publication Designer
Ok. Here goes. This may be a tad long, but it works. If it can be done easier, then please tell me. . It would take too long to write it all out, so it's just in simple txt format. Sorry.11: When creating a customer, can I change the "First name" and "Last name" to just be "Customer"? If so, how would I do this?
system/library/customer.php
Find:
private $lastname;
<---and--->
$this->lastname = $customer_query->row['lastname'];
<---and--->
$this->lastname = $customer_query->row['lastname'];
<---and--->
$this->lastname = '';
<---and--->
public function getLastName() {
return $this->lastname;
}
<---and delete these lines--->
-----------------------------------------------------------------------------------------
admin/controller/sale/customer.php
Find:
$this->data['entry_lastname'] = $this->language->get('entry_lastname');
<---and--->
if ((strlen(utf8_decode($this->request->post['lastname'])) < 1) || (strlen(utf8_decode($this->request->post['lastname'])) > 32)) {
$this->error['lastname'] = $this->language->get('error_lastname');
}
<---and--->
if (isset($this->error['lastname'])) {
$this->data['error_lastname'] = $this->error['lastname'];
} else {
$this->data['error_lastname'] = '';
}
<---and--->
if (isset($this->request->post['lastname'])) {
$this->data['lastname'] = $this->request->post['lastname'];
} elseif (isset($customer_info)) {
$this->data['lastname'] = $customer_info['lastname'];
} else {
$this->data['lastname'] = '';
}
<---and--->
. ' ' . $customer_info['lastname']
<---and delete these lines--->
-----------------------------------------------------------------------------------------
admin/model/sale/customer.php
Find:
"', lastname = '" . $this->db->escape($data['lastname']) . <---there are two of these--->
<---and--->
, ' ', c.lastname <---there are two of these--->
<---and--->
lastname,
<---and--->
, ' ', lastname
<---and--->
lastname,
<---and--->
, ' ', lastname
<---and delete these lines--->
-----------------------------------------------------------------------------------------
admin/view/template/sale/customer_form.tpl
Find:
<tr>
<td><span class="required">*</span> <span class="entry"><?php echo $entry_lastname; ?></span></td>
<td><input type="text" name="lastname" value="<?php echo $lastname; ?>" />
<?php if ($error_lastname) { ?>
<span class="error"><?php echo $error_lastname; ?></span>
<?php } ?></td>
</tr>
<---and delete these lines--->
-----------------------------------------------------------------------------------------
admin/language/english/sale/customer.php
Find:
$_['entry_firstname'] = 'First Name:';
Change to:
$_['entry_firstname'] = 'Customer:';
Find:
$_['error_firstname'] = 'First Name must be greater than 1 and less than 32 characters!';
Change to:
$_['error_firstname'] = 'Customer Name must be greater than 1 and less than 32 characters!';
----------------------------------------------------------------------------------------
catalog/model/account/customer.php
Find:
"', lastname = '" . $this->db->escape($data['lastname']) . <---there are three of these--->
<---and delete these lines--->
-----------------------------------------------------------------------------------------
catalog/language/english/account/edit.php
Find:
$_['entry_firstname'] = 'First Name:';
Change to:
$_['entry_firstname'] = 'Company Name:';
Find:
$_['error_firstname'] = 'First Name must be greater than 1 and less than 32 characters!';
Change to:
$_['error_firstname'] = 'Company Name must be greater than 1 and less than 32 characters!';
-----------------------------------------------------------------------------------------
catalog/language/english/account/address.php
Find:
$_['entry_firstname'] = 'First Name:';
Change to:
$_['entry_firstname'] = 'Company Name:';
Find:
$_['error_firstname'] = 'First Name must be greater than 1 and less than 32 characters!';
Change to:
$_['error_firstname'] = 'Company Name must be greater than 1 and less than 32 characters!';
-----------------------------------------------------------------------------------------
catalog/controller/account/edit.php
Find:
$this->data['entry_lastname'] = $this->language->get('entry_lastname');
<---and--->
if (isset($this->error['lastname'])) {
$this->data['error_lastname'] = $this->error['lastname'];
} else {
$this->data['error_lastname'] = '';
}
<---and--->
if (isset($this->request->post['lastname'])) {
$this->data['lastname'] = $this->request->post['lastname'];
} elseif (isset($customer_info)) {
$this->data['lastname'] = $customer_info['lastname'];
} else {
$this->data['lastname'] = '';
}
<---and--->
if ((strlen(utf8_decode($this->request->post['lastname'])) < 1) || (strlen(utf8_decode($this->request->post['lastname'])) > 32)) {
$this->error['lastname'] = $this->language->get('error_lastname');
}
<---and delete these lines--->
-----------------------------------------------------------------------------------------
catalog/controller/account/address.php
Find:
{lastname}
<---and--->
'{lastname}',
<---and--->
'lastname' => $result['lastname'],
<---and--->
$this->data['entry_lastname'] = $this->language->get('entry_lastname');
<---and--->
if (isset($this->error['lastname'])) {
$this->data['error_lastname'] = $this->error['lastname'];
} else {
$this->data['error_lastname'] = '';
}
<---and--->
if (isset($this->request->post['lastname'])) {
$this->data['lastname'] = $this->request->post['lastname'];
} elseif (isset($address_info)) {
$this->data['lastname'] = $address_info['lastname'];
} else {
$this->data['lastname'] = '';
}
<---and--->
if ((strlen(utf8_decode($this->request->post['lastname'])) < 1) || (strlen(utf8_decode($this->request->post['lastname'])) > 32)) {
$this->error['lastname'] = $this->language->get('error_lastname');
}
<---and delete these lines--->
-----------------------------------------------------------------------------------------
MY_THEME/template/account/address.tpl
Find:
<tr>
<td><span class="required">*</span> <?php echo $entry_lastname; ?></td>
<td><input type="text" name="lastname" value="<?php echo $lastname; ?>" />
<?php if ($error_lastname) { ?>
<span class="error"><?php echo $error_lastname; ?></span>
<?php } ?></td>
</tr>
<---and delete these lines--->
-----------------------------------------------------------------------------------------
MY_THEME/template/account/create.tpl
Find:
<tr>
<td><span class="required">*</span> <?php echo $entry_lastname; ?></td>
<td><input type="text" name="lastname" value="<?php echo $lastname; ?>" />
<?php if ($error_lastname) { ?>
<span class="error"><?php echo $error_lastname; ?></span>
<?php } ?></td>
</tr>
<---and delete these lines--->
-----------------------------------------------------------------------------------------
MY_THEME/template/account/edit.tpl
Find:
<tr>
<td><span class="required">*</span> <?php echo $entry_lastname; ?></td>
<td><input type="text" name="lastname" value="<?php echo $lastname; ?>" />
<?php if ($error_lastname) { ?>
<span class="error"><?php echo $error_lastname; ?></span>
<?php } ?></td>
</tr>
<---and delete these lines--->
-----------------------------------------------------------------------------------------
This isn't fully bug proof, so if you do find one, please tell me.
Hope this helps you all
http://dpDesignz.webs.com Web & Publication Designer
header.tpl
Code: Select all
<?php $path_theme = "catalog/view/theme/Linkup";?>
<?php echo '<?xml version="1.0" encoding="UTF-8"?>' . "\n"; ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" dir="<?php echo $direction; ?>" lang="<?php echo $lang; ?>" xml:lang="<?php echo $lang; ?>">
<head>
<title><?php echo $title; ?></title>
<?php if ($description) { ?>
<meta name="description" content="<?php echo $description; ?>" />
<?php } ?>
<base href="<?php echo $base; ?>" />
<?php if ($icon) { ?>
<link href="image/<?php echo $icon; ?>" rel="icon" />
<?php } ?>
<link rel="stylesheet" type="text/css" href="<?=$path_theme;?>/stylesheet/stylesheet.css" />
<link rel="stylesheet" type="text/css" href="catalog/view/theme/default/stylesheet/livesearch.css" />
<link rel="stylesheet" type="text/css" href="<?=$path_theme;?>/stylesheet/style.css" />
<!--[if lt IE 7]>
<link rel="stylesheet" type="text/css" href="<?=$path_theme?>/stylesheet/ie6.css" />
<script type="text/javascript" src="catalog/view/javascript/unitpngfix/unitpngfix.js"></script>
<![endif]-->
<script type="text/javascript" src="catalog/view/javascript/jquery/jquery-1.3.2.min.js"></script>
<script type="text/javascript" src="catalog/view/javascript/jquery/thickbox/thickbox-compressed.js"></script>
<link rel="stylesheet" type="text/css" href="catalog/view/javascript/jquery/thickbox/thickbox.css" />
<script type="text/javascript" src="catalog/view/javascript/jquery/tab.js"></script>
</head>
<body>
<div id="container">
<div id="header">
<div class="div1">
<div class="div2"><a href="<?php echo $home; ?>"><img src="<?php echo $logo; ?>" title="<?php echo $store; ?>" alt="<?php echo $store; ?>" /></a></div>
<div class="div3"><?php echo $entry_search; ?>
<?php if ($keyword) { ?>
<input type="text" value="<?php echo $keyword; ?>" id="filter_keyword" />
<?php } else { ?>
<input type="text" value="<?php echo $text_keyword; ?>" id="filter_keyword" onclick="this.value = '';" onkeydown="this.style.color = '#000000'" style="color: #999;" />
<a onclick="moduleSearch();" class="button"><span><?php echo $button_go; ?></span></a> <br><div align="center" ><a href="<?php echo str_replace('&', '&', $advanced); ?>"><?php echo $text_advanced; ?></a></div></div>
<?php } ?>
</div>
<div class="div4">
<div class="menu">
<ul>
<li><a href="<?php echo $home; ?>"><?php echo $text_home; ?></a></li>
<li><a href="<?php @$this->language->load('product/all'); echo 'index.php?route=product/all';?>"><?php echo $this->language->get('text_all_products'); //Q: AllProducts ?></a></li>
<li><a href="<?php echo $account; ?>"><?php echo $text_account; ?></a></li>
<li>
<?php if (!$logged) { ?>
<a href="<?php echo $login; ?>"><?php echo $text_login; ?></a>
<?php } else { ?>
<a href="<?php echo $logout; ?>"><?php echo $text_logout; ?></a>
<?php } ?>
</li>
</ul>
</div>
</div>
<div id="breadcrumb">
<div class="div5">
<?php foreach ($breadcrumbs as $breadcrumb) { ?>
<a href="<?php echo $breadcrumb['href']; ?>"><?php echo $breadcrumb['text']; ?></a><img src="<?=$path_theme?>/image/tab.png" alt="" class="split" />
<?php } ?>
</div>
<div class="div6">
<img src="<?=$path_theme?>/image/icon_checkout.png" alt="" class="icon" /><a href="<?php echo $checkout; ?>"><?php echo $text_checkout; ?></a>
<img src="<?=$path_theme?>/image/icon_basket.png" alt="" class="icon" /><a href="<?php echo $cart; ?>"><?php echo $text_cart; ?></a>
</div>
</div>
</div>
<script type="text/javascript"><!--
$('#module_search input').keydown(function(e) {
if (e.keyCode == 13) {
moduleSearch();
}
});
function moduleSearch() {
url = 'index.php?route=product/search';
var filter_keyword = $('#filter_keyword').attr('value')
if (filter_keyword) {
url += '&keyword=' + encodeURIComponent(filter_keyword);
}
var filter_category_id = $('#filter_category_id').attr('value');
if (filter_category_id) {
url += '&category_id=' + filter_category_id;
}
location = url;
}
//--></script>
<script type="text/javascript"><!--
$('.switcher').bind('click', function() {
$(this).find('.option').slideToggle('fast');
});
//--></script>
<?php if ($this->customer->isLogged()) { ?>
<b>Welcome. You are logged in as <?php echo $this->customer->getFirstName(); ?>.</b>
<?php } ?>
Code: Select all
<?php echo $header; ?><?php echo $column_left; ?><?php echo $column_right; ?>
<div id="content">
<div class="top">
<h1><?php echo $heading_title; ?></h1>
</div>
<div class="middle"><b><?php echo $text_critea; ?></b>
<div id="content_search" style="background: #F7F7F7; border: 1px solid #DDDDDD; padding: 10px; margin-top: 3px; margin-bottom: 10px;">
<table>
<tr>
<td><?php echo $entry_search; ?></td>
<td><?php if ($keyword) { ?>
<input type="text" name="keyword" value="<?php echo $keyword; ?>" id="keyword" />
<?php } else { ?>
<input type="text" value="<?php echo $text_keyword; ?>" id="keyword" onclick="this.value = '';" onkeydown="this.style.color = '000000'" style="color: #999;" />
<?php } ?></td>
</tr>
<tr>
<td colspan="2"><?php if ($description) { ?>
<input type="checkbox" name="description" id="description" checked="checked" />
<?php } else { ?>
<input type="checkbox" name="description" id="description" />
<?php } ?>
<?php echo $entry_description; ?></td>
</tr>
</table>
</div>
<div class="buttons">
<table>
<tr>
<td align="right"><a onclick="contentSearch();" class="button"><span><?php echo $button_search; ?></span></a></td>
</tr>
</table>
</div>
<div class="heading"><?php echo $text_search; ?></div>
<?php if (isset($products)) { ?>
<div class="sort">
<div class="div1">
<select name="sort" onchange="location=this.value">
<?php foreach ($sorts as $sorts) { ?>
<?php if (($sort . '-' . $order) == $sorts['value']) { ?>
<option value="<?php echo $sorts['href']; ?>" selected="selected"><?php echo $sorts['text']; ?></option>
<?php } else { ?>
<option value="<?php echo $sorts['href']; ?>"><?php echo $sorts['text']; ?></option>
<?php } ?>
<?php } ?>
</select>
</div>
<div class="div2"><?php echo $text_sort; ?></div>
</div>
<table class="list">
<?php for ($i = 0; $i < sizeof($products); $i = $i + 4) { ?>
<tr>
<?php for ($j = $i; $j < ($i + 4); $j++) { ?>
<td width="25%"><?php if (isset($products[$j])) { ?>
<a href="<?php echo $products[$j]['href']; ?>"><img src="<?php echo $products[$j]['thumb']; ?>" title="<?php echo $products[$j]['name']; ?>" alt="<?php echo $products[$j]['name']; ?>" /></a><br />
<a href="<?php echo $products[$j]['href']; ?>"><?php echo $products[$j]['name']; ?></a><br />
<span style="color: #999; font-size: 11px;"><?php echo $products[$j]['model']; ?></span><br />
<?php if ($display_price) { ?>
<?php if (!$products[$j]['special']) { ?>
<span style="color: #900; font-weight: bold;"><?php echo $products[$j]['price']; ?></span><br />
<?php } else { ?>
<span style="color: #900; font-weight: bold; text-decoration: line-through;"><?php echo $products[$j]['price']; ?></span> <span style="color: #F00;"><?php echo $products[$j]['special']; ?></span>
<?php } ?>
<?php } ?>
<?php if ($products[$j]['rating']) { ?>
<img src="catalog/view/theme/Linkup/image/stars_<?php echo $products[$j]['rating'] . '.png'; ?>" alt="<?php echo $products[$j]['stars']; ?>" />
<?php } ?>
<?php } ?></td>
<?php } ?>
</tr>
<?php } ?>
</table>
<div class="pagination"><?php echo $pagination; ?></div>
<?php } else { ?>
<div style="background: #F7F7F7; border: 1px solid #DDDDDD; padding: 10px; margin-top: 3px; margin-bottom: 15px;"><?php echo $text_empty; ?></div>
<?php }?>
</div>
<div class="bottom"> </div>
<script type="text/javascript"><!--
$('#content_search input').keydown(function(e) {
if (e.keyCode == 13) {
contentSearch();
}
});
function contentSearch() {
url = 'index.php?route=product/search';
var keyword = $('#keyword').attr('value');
if (keyword) {
url += '&keyword=' + encodeURIComponent(keyword);
}
if ($('#description').attr('checked')) {
url += '&description=1';
}
location = url;
}
//--></script>
</div>
<?php echo $footer; ?>
My search page is at http://www.linkuppaints.co.nz/eshop/ind ... uct/search and a example of a wonky results page is http://www.linkuppaints.co.nz/eshop/ind ... egory_id=0
Thanks in advance for any help
http://dpDesignz.webs.com Web & Publication Designer
Code: Select all
<?php $path_theme = "catalog/view/theme/Linkup";?>
<?php echo '<?xml version="1.0" encoding="UTF-8"?>' . "\n"; ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" dir="<?php echo $direction; ?>" lang="<?php echo $lang; ?>" xml:lang="<?php echo $lang; ?>">
<head>
<title><?php echo $title; ?></title>
<?php if ($description) { ?>
<meta name="description" content="<?php echo $description; ?>" />
<?php } ?>
<base href="<?php echo $base; ?>" />
<?php if ($icon) { ?>
<link href="image/<?php echo $icon; ?>" rel="icon" />
<?php } ?>
<link rel="stylesheet" type="text/css" href="<?=$path_theme;?>/stylesheet/stylesheet.css" />
<link rel="stylesheet" type="text/css" href="catalog/view/theme/default/stylesheet/livesearch.css" />
<link rel="stylesheet" type="text/css" href="<?=$path_theme;?>/stylesheet/style.css" />
<!--[if lt IE 7]>
<link rel="stylesheet" type="text/css" href="<?=$path_theme?>/stylesheet/ie6.css" />
<script type="text/javascript" src="catalog/view/javascript/unitpngfix/unitpngfix.js"></script>
<![endif]-->
<script type="text/javascript" src="catalog/view/javascript/jquery/jquery-1.3.2.min.js"></script>
<script type="text/javascript" src="catalog/view/javascript/jquery/thickbox/thickbox-compressed.js"></script>
<link rel="stylesheet" type="text/css" href="catalog/view/javascript/jquery/thickbox/thickbox.css" />
<script type="text/javascript" src="catalog/view/javascript/jquery/tab.js"></script>
</head>
<body>
<div id="container">
<div id="header">
<div class="div1">
<div class="div2"><a href="<?php echo $home; ?>"><img src="<?php echo $logo; ?>" title="<?php echo $store; ?>" alt="<?php echo $store; ?>" /></a></div>
<div class="div3"><?php echo $entry_search; ?>
<?php if ($keyword) { ?>
<input type="text" value="<?php echo $keyword; ?>" id="filter_keyword" />
<?php } else { ?>
<input type="text" value="<?php echo $text_keyword; ?>" id="filter_keyword" onclick="this.value = '';" onkeydown="this.style.color = '#000000'" style="color: #999;" />
<?php } ?>
<a onclick="moduleSearch();" class="button"><span><?php echo $button_go; ?></span></a><br />
<div align="center" ><a href="<?php echo str_replace('&', '&', $advanced); ?>"><?php echo $text_advanced; ?></a></div>
</div>
</div>
<div class="div4">
<div class="menu">
<ul>
<li><a href="<?php echo $home; ?>"><?php echo $text_home; ?></a></li>
<li><a href="<?php @$this->language->load('product/all'); echo 'index.php?route=product/all';?>"><?php echo $this->language->get('text_all_products'); //Q: AllProducts ?></a></li>
<li><a href="<?php echo $account; ?>"><?php echo $text_account; ?></a></li>
<li>
<?php if (!$logged) { ?>
<a href="<?php echo $login; ?>"><?php echo $text_login; ?></a>
<?php } else { ?>
<a href="<?php echo $logout; ?>"><?php echo $text_logout; ?></a>
<?php } ?>
</li>
</ul>
</div>
</div>
<div id="breadcrumb">
<div class="div5">
<?php foreach ($breadcrumbs as $breadcrumb) { ?>
<a href="<?php echo $breadcrumb['href']; ?>"><?php echo $breadcrumb['text']; ?></a><img src="<?=$path_theme?>/image/tab.png" alt="" class="split" />
<?php } ?>
</div>
<div class="div6">
<img src="<?=$path_theme?>/image/icon_checkout.png" alt="" class="icon" /><a href="<?php echo $checkout; ?>"><?php echo $text_checkout; ?></a>
<img src="<?=$path_theme?>/image/icon_basket.png" alt="" class="icon" /><a href="<?php echo $cart; ?>"><?php echo $text_cart; ?></a>
</div>
</div>
</div>
<script type="text/javascript"><!--
$('#module_search input').keydown(function(e) {
if (e.keyCode == 13) {
moduleSearch();
}
});
function moduleSearch() {
url = 'index.php?route=product/search';
var filter_keyword = $('#filter_keyword').attr('value')
if (filter_keyword) {
url += '&keyword=' + encodeURIComponent(filter_keyword);
}
var filter_category_id = $('#filter_category_id').attr('value');
if (filter_category_id) {
url += '&category_id=' + filter_category_id;
}
location = url;
}
//--></script>
<script type="text/javascript"><!--
$('.switcher').bind('click', function() {
$(this).find('.option').slideToggle('fast');
});
//--></script>
<?php if ($this->customer->isLogged()) { ?>
<b>Welcome. You are logged in as <?php echo $this->customer->getFirstName(); ?>.</b>
<?php } ?>
Modules for OpenCart 2.3.0.2
Homepage Module [Free - since OpenCart 0.7.7]
Multistore Extensions
Store Manager Multi-Vendor/Multi-Store management tool
If you're not living on the edge ... you're taking up too much space!
http://dpDesignz.webs.com Web & Publication Designer
dpDesignz wrote:.... I am highly considering a paypal donation, once I have the final shop ready.
Not good business practice to make a promises you can't keep! In fact, where I come from, this would be considered a breach of the fair trading laws. However, I don't have a problem with you putting a link back to my site.dpDesignz wrote:.... Sorry I can't donate as I am unable to have paypal. But I will happily put a link to you from our site in the near future. (Once I have it sorted out). Hope this is ok.
Modules for OpenCart 2.3.0.2
Homepage Module [Free - since OpenCart 0.7.7]
Multistore Extensions
Store Manager Multi-Vendor/Multi-Store management tool
If you're not living on the edge ... you're taking up too much space!
Sorry for the misunderstanding. In the 1st comment I meant that the customer I am building the site for are considering doing a paypal to opencart (Note the "highly considering a paypal donation"). I myself am underage to have a paypal account according to local law, that is why I can't do anything. I am very sorry for any problems or issues caused by this.fido-x wrote:dpDesignz wrote:.... I am highly considering a paypal donation, once I have the final shop ready.Not good business practice to make a promises you can't keep! In fact, where I come from, this would be considered a breach of the fair trading laws. However, I don't have a problem with you putting a link back to my site.dpDesignz wrote:.... Sorry I can't donate as I am unable to have paypal. But I will happily put a link to you from our site in the near future. (Once I have it sorted out). Hope this is ok.
http://dpDesignz.webs.com Web & Publication Designer
http://dpDesignz.webs.com Web & Publication Designer
Aah, OK, I understand. Apology accepted. No hard feelings.dpDesignz wrote:Sorry for the misunderstanding. In the 1st comment I meant that the customer I am building the site for are considering doing a paypal to opencart (Note the "highly considering a paypal donation"). I myself am underage to have a paypal account according to local law, that is why I can't do anything. I am very sorry for any problems or issues caused by this.
Modules for OpenCart 2.3.0.2
Homepage Module [Free - since OpenCart 0.7.7]
Multistore Extensions
Store Manager Multi-Vendor/Multi-Store management tool
If you're not living on the edge ... you're taking up too much space!
Good thing this is the internet! I am highly considering giving all forum users a huge donation!fido-x wrote:dpDesignz wrote:.... I am highly considering a paypal donation, once I have the final shop ready.Not good business practice to make a promises you can't keep! In fact, where I come from, this would be considered a breach of the fair trading laws. However, I don't have a problem with you putting a link back to my site.dpDesignz wrote:.... Sorry I can't donate as I am unable to have paypal. But I will happily put a link to you from our site in the near future. (Once I have it sorted out). Hope this is ok.
This wasn't necessary, but thank you anyway. You can take it down now that I've seen it.dpDesignz wrote:...A public apology has been posted on my personal homepage.
Modules for OpenCart 2.3.0.2
Homepage Module [Free - since OpenCart 0.7.7]
Multistore Extensions
Store Manager Multi-Vendor/Multi-Store management tool
If you're not living on the edge ... you're taking up too much space!
Was that supposed to be a joke Qphoria? I don't get it.
http://dpDesignz.webs.com Web & Publication Designer
I think he forgot that great American punchline. "What's that all about?"dpDesignz wrote:Was that supposed to be a joke Qphoria? I don't get it.
Funny sense of humour these Americans have
Modules for OpenCart 2.3.0.2
Homepage Module [Free - since OpenCart 0.7.7]
Multistore Extensions
Store Manager Multi-Vendor/Multi-Store management tool
If you're not living on the edge ... you're taking up too much space!
Users browsing this forum: No registered users and 20 guests