-
AuthorPosts
-
November 24, 2016 at 7:04 am #716276
Hi kriesi,
on my dev page i use a svg logo as an image- and my question is how can i use the logo with a svg code instead of svg image, i tried to put it in the -> function-set-avia-fronted.php but it don´t work
have you and idee where i have to put it?
thank youNovember 25, 2016 at 11:54 am #716766Hey siteraum,
1. Please install this plugin https://wordpress.org/plugins/svg-support/
2. Upload your svg file to media library
3. Browse the svg file or just insert the URL to the svg file in the logo upload options.Let us know if you need any help :)
Best regards,
VinayNovember 25, 2016 at 4:07 pm #716916hi vinay, thank yo for answer,
but i want to replace my svg logo image with the svg code, and with this plugin i cant load the svg code for the logo, where i have to put the svg code? sorry about this…
November 25, 2016 at 7:03 pm #716992Hey!
You will need to remake the function of the logo, change the logo placment and add the SVG.
https://kriesi.at/support/topic/replace-default-logo-with-text-or-remove-it-completely/here is an example of the function.
Thanks a lot
Regards,
BasilisNovember 25, 2016 at 7:15 pm #716995Hi basilis, thank you for answer,
this thread i read before but it dont works- perhaps i am not so fit for iti dont know how too put the svg code inside- when you have time please help me to figured it out- thany you basillis
see privat linkNovember 29, 2016 at 3:47 pm #718290Hi,
put the first code inside your functions.php and the try for the second one to use a Code Block element of it (inside of Content Elements in ALB).
Best regards,
AndyNovember 29, 2016 at 4:17 pm #718314Hi andy,
thank you for answer.
Sorry but i don’t understand- you say that have to use a code block in the ALB element?i want to replace the logo (is an svg images) with the svg code of the logo… I
Thank you
perhaps i write in german- my english is not so goodNovember 29, 2016 at 4:25 pm #718318Hi!
Please add the code in private content field into Functions.php file in Appearance > Editor and then add following code to Quick CSS in Enfold theme options under General Styling tab
.logo > a > img { display: none !important; }
Cheers!
Yigit- This reply was modified 8 years ago by Yigit.
November 29, 2016 at 4:34 pm #718327thank you very much yigit- it works!!!
thank you!! super!!
November 29, 2016 at 4:39 pm #718329thank you thank you- i spend days with that!!!
November 29, 2016 at 4:49 pm #718337yes the code is important to set the logo to display: none (ps don’t forget to make it for the responsive case too.)
but you don’t need any plugin for that.
The code to be able to upload svgs to wordpress is old:(both comes to child-theme functions.php)
function custom_mtypes( $m ){ $m['svg'] = 'image/svg+xml'; $m['svgz'] = 'image/svg+xml'; return $m; } add_filter( 'upload_mimes', 'custom_mtypes' );
after you set the original “logo” to display none you can insert the svg code (so without img src) into enfold:
function first_logo($logo) { $logo .= '<strong class="logo first-logo"><a href="path to an url1">' ; $logo .= file_get_contents("/wp-content/uploads/logo1.svg"); $logo .= '</a></strong>'; return $logo; } add_filter('avf_logo_final_output', 'first_logo');
this is a big andvantage because now you have the possibility to setup f.e. hover styles to svg path or something like that.
- This reply was modified 8 years ago by Guenni007.
November 29, 2016 at 5:00 pm #718349Hey!
You are welcome!
For your information, you can take a look at Enfold documentation here – http://kriesi.at/documentation/enfold/
And if there are features that you wish Enfold had, you can request them and vote the requested ones here – https://kriesi.at/support/enfold-feature-requests/
For any other questions or issues, feel free to post them here on the forum and we will gladly try to help you :)
@guenni007 Thanks for your help :)Regards,
Yigit -
AuthorPosts
- The topic ‘SVG code for Logo’ is closed to new replies.