Search found 32 matches

Search found 32 matches

Re: Display current category_id in layout.tpl?

I just realized the categories module does something similar (it bolds the current category whether you're on the category page or on that product's page). In /catalog/controller/module/category.php -- inside the getCategories function is this: if ($this->category_id == $result['category_id']) { $ou...

Jump to post
  • Tue Nov 17, 2009 11:39 pm
  • Replies 3
  • Views 1216
Display current category_id in layout.tpl?

Is it possible to do this? I have a secondary navigation menu with my categories...but I'd like to get each one to have an active background color once you're ON that category page. I've done this many times but never in OC...really all I need is the ability to print the category_id on the main layo...

Jump to post
  • Mon Nov 16, 2009 9:27 am
  • Replies 3
  • Views 1216
Re: apostrophe in product name

I hope I'm understanding your problem correctly. Try using the html_entity_decode method....i've used it a few times with great results. Never with e-mails but you might be able to make it work. Instead of: <?php echo $fieldname; ?> Maybe try something like this: <?php echo html_entity_decode($field...

Jump to post
  • Mon Nov 16, 2009 8:18 am
  • Replies 6
  • Views 999
Re: How can I allow letters in the "weight" field?

Nevermind -- figured it out ;D

Just had to change a few things in admin/model/catalog/product.php

FROM:

Code: Select all

(float)@$data['weight']
TO:

Code: Select all

$this->db->escape(@$data['weight'])
In both the addproduct and editproduct functions.

Jump to post
  • Mon Nov 16, 2009 5:13 am
  • Replies 3
  • Views 493
Re: How can I allow letters in the "weight" field?

I've already used the model field but I don't have a "SKU" field in the data tab of my product form.

I'm running 1.3.0 -- was that added afterwards?

Jump to post
  • Mon Nov 16, 2009 4:53 am
  • Replies 3
  • Views 493
How can I allow letters in the "weight" field?

I don't need the weight field as it is for this particular site and I would like to use this field for something else. I have already gone into the database and changed the row type from decimal to varchar but opencart still won't update this field correctly. If I try submitting the field comes back...

Jump to post
  • Mon Nov 16, 2009 2:27 am
  • Replies 3
  • Views 493
Re: How can I display Meta Description on Product page?

LOL...thanks for that. Definitely much cleaner.

Jump to post
  • Mon Nov 16, 2009 12:43 am
  • Replies 26
  • Views 9536
Re: How can I display Meta Description on Product page?

Ok i figured it out! The problem was that the changes needed to be made to the category.php controller, not product.php

Everything looks good now, thanks! ;D

Jump to post
  • Sun Nov 15, 2009 11:09 pm
  • Replies 26
  • Views 9536
Re: How can I display Meta Description on Product page?

moggiex -- for some reason, that's not working for me. this is what my product array looked like before: $this->data['products'][] = array( 'name' => $result['name'], 'model' => $result['model'], 'rating' => $rating, 'stars' => sprintf($this->language->get('text_stars'), $rating), 'thumb' => HelperI...

Jump to post
  • Sun Nov 15, 2009 11:05 pm
  • Replies 26
  • Views 9536
Re: How can I display Meta Description on Product page?

Anyone know how i can call the product_id of each listing in the category.tpl template file?

Jump to post
  • Sun Nov 15, 2009 10:34 pm
  • Replies 26
  • Views 9536
Re: How can I display Meta Description on Product page?

Qphoria wrote:There is no meta keyword field. The keyword is for SEO urls. Meta keywords have been deemed useless for the past 2 years (google some info about it).
I understand but I'm just trying to re-use this field for another purpose like I did with the meta description product field.

Jump to post
  • Sun Nov 15, 2009 5:14 am
  • Replies 26
  • Views 9536
Re: How can I display Meta Description on Product page?

Any idea how I can do the same for the meta keyword field?

I tried doing it with the exact directions above but it appears that this field might behave a bit differently and it doesn't show up on either the product or category pages.

Thanks!

Jump to post
  • Sun Nov 15, 2009 3:20 am
  • Replies 26
  • Views 9536
Re: Displaying something other than $0 when no price is given

Thanks for the info! My code isn't the same (i'm running 1.3.0) but i was able to get this to work on the product pages. However, I haven't been able to get it to work on the category pages. Here's what my code looks like in category.php $special = $this->model_catalog_product->getProductSpecial($re...

Jump to post
  • Sat Nov 14, 2009 1:42 pm
  • Replies 61
  • Views 42471
[Mod]Displaying something other than $0 if no price is given

Anyone have an easy solution to this? Ideally, I'd love the system to say "Coming soon" if a product is listed at a price of $0.00

Thanks in advance.

Jump to post
  • Sat Nov 14, 2009 8:52 am
  • Replies 61
  • Views 42471
Re: Free Public Downloads via function getProductDownloads?

Thanks Q, you put me on the right track. Now -- i have the following code working but it only returns one result. I'm pretty sure I'll need to join these table queries somehow but my SQL skills are VERY limited. Do any MySQL experts want to take a stab at joining these 3 queries into one so I can th...

Jump to post
  • Sat Nov 14, 2009 8:47 am
  • Replies 6
  • Views 1174
Re: Free Public Downloads via function getProductDownloads?

it should work. You seem to have done the research so try it out. Check out how the link is structured in the downloads area for normal downloads. Where is the downloads area template located? Is it catalog/view/theme/default/template/account/download.tpl? Doesn't seem right but it's the only one I...

Jump to post
  • Sat Nov 14, 2009 5:54 am
  • Replies 6
  • Views 1174
Re: How can I display Meta Description on Product page?

You, sir, are a life saver!

I wish i had money to donate but I have at least purchased like 3 of your modules so far (it was for the FishSmith site a couple of months ago if you recall). :)

Thanks for all the great work!

Jump to post
  • Sat Nov 14, 2009 5:46 am
  • Replies 26
  • Views 9536

Search found 32 matches