Author Topic: [SOLVED]Change Font Color in Part of Short Description  (Read 994 times)

bakgerman1972

  • Beginner
  • *
  • Posts: 6
  • A beginner
  • Skype Name: bora.akgerman
[SOLVED]Change Font Color in Part of Short Description
« on: September 13, 2015, 13:09:27 pm »
Hello I have J 3.4 and VM3 installed on my site.

Please see this category view where I have made a single word bold and red in the short description:
http://puu.sh/k9GRz/7069ec8476.jpg
http://www.bmbtechnology.com/products/eco-series.html

No problems here.

But when I actually click on the product details to go to the product page, I get an error on top left of the page. Please see here:
http://puu.sh/k9H3q/fa7354afc0.jpg
http://www.bmbtechnology.com/products/eco-series/bmb-10-mineral-detail.html

As you can see the short description is displayed properly but it also displays a run off on the top left corner of the page.

Now here is the weird part.
This is my original short description that makes this problem:
Code:
Code: [Select]
Self-standing, 5 filter reverse osmosis system that incorporates a pH stabilizer, nano zinc powder activated antibacterial filter and <font color="ce4d39"><strong>Mineral</strong></font> filter for anti-aging water properties.

If I remove the font color tag then no problems everything works fine:
Code:
Code: [Select]
Self-standing, 5 filter reverse osmosis system that incorporates a pH stabilizer, nano zinc powder activated antibacterial filter and <strong>Mineral</strong> filter for anti-aging water properties.

If I try another approach again I have the same problem:
Code:
Code: [Select]
Self-standing, 5 filter reverse osmosis system that incorporates a pH stabilizer, nano zinc powder activated antibacterial filter and <strong style="color:red" >Mineral</strong> filter for anti-aging water properties.

This only happens, I guess, when I try to make a different color inside the short description for one or a few words.

Can someone please help me.

jenkinhill

  • UK Web Developer & Consultant
  • Global Moderator
  • Super Hero
  • *
  • Posts: 27478
  • Always on vacation
    • Jenkin Hill Internet
Re: Change Font Color in Part of Short Description
« Reply #1 on: September 13, 2015, 13:19:52 pm »
Just look at the page code!!  This looks like where the problem lies:
<meta property="og:description" content="Self-standing, 5 filter reverse osmosis system that incorporates a pH stabilizer, nano zinc powder activated antibacterial filter and <font color="ce4d39"><strong>Mineral</strong></font> filter for anti-aging water properties."/>

You could maybe fix this in your open graph plugin.  Disable it to confim that's where the problem is.
Kelvyn

Jenkin Hill Internet,
Lowestoft, Suffolk, UK

Unsolicited PMs/emails will be ignored.

Please mention your VirtueMart, Joomla and PHP versions when asking a question in this forum

Currently using VM 3.4.3.10057 on Joomla 3.9.10 PHP 7.0.33
Testing VM 3.5.0.10097 on Joomla 3.9.10

bakgerman1972

  • Beginner
  • *
  • Posts: 6
  • A beginner
  • Skype Name: bora.akgerman
Re: Change Font Color in Part of Short Description
« Reply #2 on: September 13, 2015, 13:27:41 pm »
Hi Jenkin,

Thanks for the very quick reply!

I am somewhat of a newb, I can fiddle with php code and css etc., but please excuse me if this sounds totally stupid:
- where do I find the open graph plugin, I did a search for "open" and "graph" in plugins but ... :-(

jenkinhill

  • UK Web Developer & Consultant
  • Global Moderator
  • Super Hero
  • *
  • Posts: 27478
  • Always on vacation
    • Jenkin Hill Internet
Re: Change Font Color in Part of Short Description
« Reply #3 on: September 13, 2015, 13:49:35 pm »
Either you installed it or it came with your template - you can get a load of unwanted crap if you use a "quick start" package. But this is a Joomla question - not about VirtueMart.
Kelvyn

Jenkin Hill Internet,
Lowestoft, Suffolk, UK

Unsolicited PMs/emails will be ignored.

Please mention your VirtueMart, Joomla and PHP versions when asking a question in this forum

Currently using VM 3.4.3.10057 on Joomla 3.9.10 PHP 7.0.33
Testing VM 3.5.0.10097 on Joomla 3.9.10

bakgerman1972

  • Beginner
  • *
  • Posts: 6
  • A beginner
  • Skype Name: bora.akgerman
Re: Change Font Color in Part of Short Description
« Reply #4 on: September 13, 2015, 13:55:57 pm »
Hi Jenkin,

Again thanks for your quick reply. Unfortunately your last comment is not that helpful. I have search VM and J forums but there is no information for anyone wanting to change the color of a single word in the VM short description. Not sure what would happen on other versions.

GJC Web Design

  • 3rd party VirtueMart Developer
  • Super Hero
  • *
  • Posts: 8940
  • Virtuemart, Joomla & php developer
    • GJC Web Design
  • VirtueMart Version: 3.4.2
Re: Change Font Color in Part of Short Description
« Reply #5 on: September 13, 2015, 20:38:51 pm »
Your markup is simply wrong..  you need to improve your basic css skills
The <font> tag is not supported in HTML5. Use CSS instead.

<font color="ce4d39"><strong>Mineral</strong></font>

ce4d39 isn't a color--  #ce4d39  is

<span style="color:#ce4d39"><strong>Mineral</strong></span>
GJC Web Design
VirtueMart and Joomla Developers - php developers http://www.gjcwebdesign.com
VM3 AusPost Shipping Plugin - e-go Shipping Plugin - VM3 Postcode Shipping Plugin - Radius Shipping Plugin - VM3 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
http://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

bakgerman1972

  • Beginner
  • *
  • Posts: 6
  • A beginner
  • Skype Name: bora.akgerman
Re: Change Font Color in Part of Short Description
« Reply #6 on: September 13, 2015, 20:56:41 pm »
Hi,

I had also tried that before but it did not work. If you look now you can see I am using exactly what you wrote and still it is not working. Any other ideas?


GJC Web Design

  • 3rd party VirtueMart Developer
  • Super Hero
  • *
  • Posts: 8940
  • Virtuemart, Joomla & php developer
    • GJC Web Design
  • VirtueMart Version: 3.4.2
Re: Change Font Color in Part of Short Description
« Reply #8 on: September 13, 2015, 21:24:29 pm »
Exactly as jenks says -- what ever is forming your :og tags is not striping html as it must .. use something like strip_tags() in how ever the og tag is formed

have you also looked at the source code of your site.. vast amounts of inline css..  huge amounts of javascript
a page load of 2+MB!!!

GJC Web Design
VirtueMart and Joomla Developers - php developers http://www.gjcwebdesign.com
VM3 AusPost Shipping Plugin - e-go Shipping Plugin - VM3 Postcode Shipping Plugin - Radius Shipping Plugin - VM3 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
http://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

bakgerman1972

  • Beginner
  • *
  • Posts: 6
  • A beginner
  • Skype Name: bora.akgerman
Re: [SOLVED]Change Font Color in Part of Short Description
« Reply #9 on: September 13, 2015, 21:51:28 pm »
I am a huge failure  :'(

GJC Web Design

  • 3rd party VirtueMart Developer
  • Super Hero
  • *
  • Posts: 8940
  • Virtuemart, Joomla & php developer
    • GJC Web Design
  • VirtueMart Version: 3.4.2
Re: [SOLVED]Change Font Color in Part of Short Description
« Reply #10 on: September 13, 2015, 22:22:52 pm »
It is the template at fault... sadly many templates out there are very poorly coded forgetting that a website is .. well..  internet based..  ;)
GJC Web Design
VirtueMart and Joomla Developers - php developers http://www.gjcwebdesign.com
VM3 AusPost Shipping Plugin - e-go Shipping Plugin - VM3 Postcode Shipping Plugin - Radius Shipping Plugin - VM3 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
http://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation