Adding Fontawesome Icons?
Hi there,
Is it possible to use font awesome icons in Hikashop, for example to add an Icon to the checkout button:
What is the best way to implement this?
Best regards,
Jethro.
EDIT: :blush: So sorry for posting this in the wrong category! Should go in the Display Category. :blush:
Please Log in or Create an account to join the conversation.
Depending where you want to put the icon, you can use a view override (like "checkout | step") or a translation override.
More about the HikaShop customization: www.hikashop.com/support/support/documen...ize-the-display.html
Regards,
Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.
Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
<i class="fa fa-plus-square"></i>
Using FireBug, how to I know which view to edit, and how do I know where to inject the code?
Many thanks,
Jethro.
Please Log in or Create an account to join the conversation.
You can use the documentation that I gave you in my previous message.
See below in the page for the product page description
www.hikashop.com/support/support/documen...-display.html#layout
Regards,
Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.
Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
Without a link to a page or more details about what that "checkout" is exactly ; it will be difficult to help you correctly.
Regards,
Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.
Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.
Please Log in or Create an account to join the conversation.
Many thanks,
Jethro.
Please Log in or Create an account to join the conversation.
did you add the link to css file that define location of font library ( otf .ttf svg .....)
in index.php file add in the <head> this code :oops: <link rel="stylesheet" href="//maxcdn.bootstrapcdn.com/font-awesome/4.3.0/css/font-awesome.min.css">.
define library
@font-face{
font-family:'gzipper';
src: url('gzipperblot.eot');
}
initiate library
iconic {
font-family: gzipper , Helvetica, Arial, sans-serif;
}
call the glyph
<span class="iconic " data-glyph="microphone">
.iconic[data-glyph="microphone"]:before {
content: "";
}
Please Log in or Create an account to join the conversation.
The CSS file should be linked fine as font awesome is working just perfectly on the rest of my site, in addition font-awesome is integrated into my template (T3 Bootstrap) so it should work.
Please Log in or Create an account to join the conversation.
In you actual code there of the page there is no selector ( fa-*) that call font awesome !
Take care that checkout is not a text content but show/mange by the <input> html tag !!
I see that css file fontawesome is load ( OK basic )
Does the custom layout override is really load ?
Attachment not found
Please Log in or Create an account to join the conversation.
Here is what I have done.
1 - Gone to the language override section in configuration in the Hikashop backend and added the code: <i class="fa fa-arrow-circle-right"></i> to the field PROCEED_TO_CHECKOUT=
So it looks like this:
This is how it looks in my backend:
However it still fails and shows the code in the checkout button...
It should not be a complicated thing, you can even see on my home page and in the menu I am using fontawesome all over.
Very confusing, :whistle:
Please Log in or Create an account to join the conversation.
lionel75 wrote: Hi
In you actual code there of the page there is no selector ( fa-*) that call font awesome !
Take care that checkout is not a text content but show/mange by the <input> html tag !!
I see that css file fontawesome is load ( OK basic )
Does the custom layout override is really load ?
Attachment not found
The error should be showing on the cart now if you look again.
It would be great if Hikashop was integrated with fontawesome out of the box!
Please Log in or Create an account to join the conversation.
you CAN' T use translation in the way you do because the string checkout is the value of a arrtibute name call value in < input value = "checkout " > </input> . The brower take this text like raw text and show it without compute it /add it in the node of <input > .
you should put the translation value not inside <input value ="here" ></input > but rather <input value="" > here</input>.
In web design what you see can be implemented in many way !!! you have to edit the php file and change the location where your translation string is call put it in hte green location .
Attachment not found
The browser understand/show manage data after build a DOM ( memory structure of document where all tag define a node and node contain node . the content in value="" ll be never a node. Try to select the string ""Checkout <i class=fa fa-arrow-circle-right></i>"" you can't so this text is not real text it a kind of shadow text : you see it but you can't select it !!!!! . See the capture screen ; in the code source you don't see the value beetween/inside <input >here </input> but you see in the html page ...... ( to be dig ...... by yourself ) .
hope this ll help ( i think yes )
Please Log in or Create an account to join the conversation.
even it take time try to understand the example i give in my first post
.iconic[data-glyph="microphone"]:before {
content: "";
}
what mean the value after content ? ( attach to pseudo element = virtual ghost data )
what mean :before ? ( pseudo element )
what mean data-glyph ( html 5 concept name data- )
do i need a script to manage HTML5 data- ?
Please Log in or Create an account to join the conversation.
You can't add HTML code in an attribute of an HTML tag ; the checkout button is a button and you can put some HTML in the "value" of the button.
So if you use normal buttons (as it is the case on your website), you can't use a translation override.
It would be possible if you changed the "button style" option of the HikaShop configuration to "CSS" instead of "normal".
But in that case, that also means that you would have to adapt the CSS of the buttons so that they display again like you want.
Regards,
Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.
Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.
Please Log in or Create an account to join the conversation.
Thanks Lionel, your in-depth explanations are extremely helpful, it looks like I need to learn some PHP to resolve this issue.
EDIT: Jerome! Your solution was extraordinarily useful and ultimately helped me resolve my issues.
Just to confirm: Changing the button display to CSS wont cause any problems? Is there a major difference between the two options or any problems I might have?
For those struggling with something similar here are the steps I took:
1 - I changed the button display setting in configuration/display to "CSS" this removed all of my css changes for the buttons.
2 - Next I re-styled all the buttons to look how I wanted them to
3 - Next I went to the language overrides and added the Fontawesome icons to the language override section. Be sure to use single brackets 'example' instead of double brackets "example".
This is how the edits looked in my en-GB language override:
And that is that! All icons working like a charm... feel free to take a look: www.smart-drones.com/store
10/10 support guys, thanks!
Please Log in or Create an account to join the conversation.
Nothing is difficult when understand what we do but click on hks button BE don't let us understand what occur on the code source !!
If all work it is ok nobody ( consumer) ll look at the code source !!
Here the wysiwyg and code source after change
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
my way
I think better is to put the html tag and class in the layout . Layout view contain look and feel , icon are for look and feel ................theme .......In a way font icon don't have to be translate . icon font are international language !!!
hks way
seem they manage the issue you have by hks BE option so i can't say nothing about the way they implement it . it work ...so all is ok ...
the site use joomla template purity iii
regard's
(NB i don't really resolve my joomla date issue today )
Please Log in or Create an account to join the conversation.