• Home
  • WordPress Themes
    • eCommerce
    • Corporate
    • Multipurpose
    • Blog
  • Support
    • WoodMart support
    • Basel support
    • Space support
  • Documentation
    • WoodMart
    • Basel
    • Hitek, Luman, Antares
  • Demo
    • WoodMart
    • Basel
    • Hitek
Login / Register
Checkout
Checkout
Menu

Home / Forums / Basel support forum / SVG Logo Image

Home › Forums › Basel support forum › SVG Logo Image

SVG Logo Image

  • This topic has 20 replies, 2 voices, and was last updated 6 years, 7 months ago by Artem Temos.
Viewing 21 posts - 1 through 21 (of 21 total)
  • Author
    Posts
  • August 12, 2016 at 7:26 am #2670

    jackbanister
    Participant

    Hi there,

    Is there a way I can use a SVG image as the logo? Say if I uploaded an svg to the cPanel file manager and pasted the link in the theme options somehow?

    Any help would be greatly appreciated.

    Many thanks,
    Jack

    August 12, 2016 at 7:32 am #2671

    Artem Temos
    Keymaster

    Hello,

    Thank you for contacting us.

    The easiest way for you will be:

    1. Upload your SVG logo to the server

    2. Set up basel child theme

    3. Override logo PHP function to get logo not from Theme Settings but set your path manually. Here is the code that you need to place into functions.php file in the child theme

    function basel_get_logo() {
    	$logo_src = 'http://YOURWEB_SITE/LOGO_IMAGE.svg'
    	?>
    		<a href="<?php echo esc_url( home_url('/') ); ?>" rel="home"><img src="<?php echo esc_url( $logo_src ); ?>" alt="<?php echo esc_attr( get_bloginfo( 'name' ) ); ?>"></a>
    	<?php 
    }

    Don’t forget to set your actual path to the image.

    Regards

    August 12, 2016 at 7:41 am #2672

    jackbanister
    Participant

    Hi, thanks for the prompt reply.

    How do I upload the svg file to the server? Do I just upload it into the theme basel child file in the cPanel ?

    August 12, 2016 at 8:05 am #2673

    Artem Temos
    Keymaster

    Yes, you can just upload your logo image through the cPanel.

    August 12, 2016 at 8:14 am #2674

    jackbanister
    Participant

    ok, do I upload it to the child theme or the main theme?

    August 12, 2016 at 8:19 am #2675

    jackbanister
    Participant

    So I go to the website public html, then wp-content, then upload to the theme?

    August 12, 2016 at 10:06 am #2678

    jackbanister
    Participant

    Also, I was already running the Basel Child theme.

    I just changed the functions php in the basel child theme folder (in the cPanel file manager section) like you said so it’d include the svg file link (http://sarakirkbyinteriors.com/wp-content/themes/basel/images/SaraKLogo4.svg) – I uploaded this to the images section of the Basel theme (not the child theme).

    Should I be doing something else to override the current logo? And should I reload the child theme or will it already take into account I’ve updated the functions php?

    Many thanks,
    Jack

    August 12, 2016 at 7:07 pm #2688

    Artem Temos
    Keymaster

    First: upload your logo not to basel folder but to child theme folder (basel-child/images/your-logo.svg)

    After uploading and activating your child theme you will have the file wp-content/themes/basel-child/functions.php. So please add the code to this file and save it.

    August 12, 2016 at 7:43 pm #2693

    jackbanister
    Participant

    Afraid it still doesn’t work. I was already running the child theme – should I reinstall it? And will it mess up my site progress if I reinstall?

    August 12, 2016 at 7:58 pm #2694

    Artem Temos
    Keymaster

    Please, provide your FTP access we will try to do it faster 🙂

    August 12, 2016 at 8:02 pm #2695

    jackbanister
    Participant

    Sorry, how do I do that?

    August 12, 2016 at 8:03 pm #2696

    Artem Temos
    Keymaster

    Do you have FTP access so wee could connect your server and edit your files?

    August 12, 2016 at 8:04 pm #2697

    jackbanister
    Participant

    I’m not sure if I have FTP access. How do I find out?

    August 12, 2016 at 8:05 pm #2698

    Artem Temos
    Keymaster

    And also try to place this code to the functions.php file instead of previous one

    function basel_header_block_logo() {
    	$logo_src = 'http://YOURWEB_SITE/LOGO_IMAGE.svg'
    	$logo_img = '<img src="' . $logo_src . '" alt="' . get_bloginfo( 'name' ) . '" />'
    
    	?>
    		<div class="site-logo">
    			<a href="<?php echo esc_url( home_url('/') ); ?>" rel="home">
    				<?php echo ( $logo_img ); ?>
    			</a>
    		</div>
    	<?php
    }
    August 12, 2016 at 8:13 pm #2699

    jackbanister
    Participant

    tried that, it’s come up with this-

    Parse error: syntax error, unexpected ‘$logo_img’ (T_VARIABLE) in /home1/jackbanister/public_html/sarakirkbyinteriors.com/wp-content/themes/basel-child/functions.php on line 17

    August 12, 2016 at 8:14 pm #2700

    Artem Temos
    Keymaster

    In this case the only one way to help you is to edit functions.php file by ourselves. Could you please provide your FTP account or cPanel access?

    August 12, 2016 at 8:16 pm #2701

    Artem Temos
    Keymaster

    Sorry again. Try to change code with the following 🙂

    function basel_header_block_logo() {
    	$logo_src = 'http://YOURWEB_SITE/LOGO_IMAGE.svg';
    	$logo_img = '<img src="' . $logo_src . '" alt="' . get_bloginfo( 'name' ) . '" />'
    
    	?>
    		<div class="site-logo">
    			<a href="<?php echo esc_url( home_url('/') ); ?>" rel="home">
    				<?php echo ( $logo_img ); ?>
    			</a>
    		</div>
    	<?php
    }
    August 12, 2016 at 8:20 pm #2702

    jackbanister
    Participant

    Yes, it worked! Thanks so much!

    … Now can I adjust its size?

    August 12, 2016 at 8:25 pm #2703

    jackbanister
    Participant

    Not to worry, just found it in the theme options section!

    Thanks again for being so helpful!

    August 12, 2016 at 9:06 pm #2705

    jackbanister
    Participant

    ok, sorry I’m back to ask something else to do with the logo.

    How do I change the white logo on the footer..

    August 13, 2016 at 8:24 am #2710

    Artem Temos
    Keymaster

    You can change your footer logo image in Appearance -> Widgets.

  • Author
    Posts

Tagged: svg, svg logo

Viewing 21 posts - 1 through 21 (of 21 total)
  • You must be logged in to create new topics. Login / Register

Your request can't be resolved for a long time? Contact our general support manager.

Contact form
Recent Replies
  • Luke Nielsen on How to remove the name 4 seconds ago
  • xealcargologic on Page number dont show good on Mobile 1 minute ago
  • Luke Nielsen on Extra description no sale visible en la pagina de caterogia 13 minutes ago
  • Matteo on Recently Viewed Product with Cache 17 minutes ago
WoodMart 7.1
Create your WordPress website.
  • Resources
    • Video tutorials
    • Blog
    • Contact us
    • Refund Policy
    • Terms of Service
  • Social links
    • Facebook
    • Twitter
    • Instagram
    • YouTube
    • Telegram

@ XTemos studio. 2022   WordPress development from 2015.

Privacy Policy

  • Home
  • WordPress Themes
    • eCommerce
    • Corporate
    • Multipurpose
    • Blog
  • Support
    • WoodMart support
    • Basel support
    • Space support
  • Documentation
    • WoodMart
    • Basel
    • Hitek, Luman, Antares
  • Demo
    • WoodMart
    • Basel
    • Hitek
  • Login / Register

Sign in

close

Lost your password?

No account yet?

Create an Account