Archived

This topic is now archived and is closed to further replies.

  • 0

Resolved Change social website icons

Question

Posted · Report post

Hi I used to develop a website by another theme, and my boss still likes the social icons of it very much,

Like x69chen.com, the social icons on the right top, the round button ones, including the search button.

And now I have bought the PageLine Prof, I want to ask how I can change the icons like those?

I am a new starter, thanks for helping

Share this post


Link to post
Share on other sites

14 answers to this question

Posted · Report post

Hi,

Can you provide a link to the site where these social icons are not appearing please.

Oh thanks here you go, x69chen.com

I just have one domination sorry about that

Share this post


Link to post
Share on other sites

Posted · Report post

Hi I add the codes to the Custom CSS, also upload logos, get the url addresses and replace the images/ with the addresses, but they does not work,

and it says Custom LESS/CSS error.

also I find these codes which build in that theme

function pinboard_social_media_options() {

add_settings_field( 'pinboard_facebook_link', __( 'Facebook Page', 'pinboard' ), 'pinboard_facebook_link', 'pinboard_options', 'pinboard_social_media_options' );}

function pinboard_facebook_link() { ?>

<input name="pinboard_theme_options[facebook_link]" type="text" value="<?php echo pinboard_get_option( 'facebook_link' ); ?>" />

<?php}

I find these in their theme-option.php folder

Share this post


Link to post
Share on other sites

Posted · Report post

The CSS is placed in Dashboard > PageLines > Site Options > Custom Code in CSS Rules.

The first bit of text requires that you add a sidebar or some other element to the Header. To do this, you go to Dashboard > PageLines > Drag & Drop and you'll see "Header" (it will be blue). Drag an element like Universal Sidebar from Available Sections to Active Sections.

Then, go to Dashboard > Appearance > Widgets. Click on Universal Sidebar. Drag "Text Widget" into the Universal Sidebar. It will open.

Paste the code I provided in the first group into the text widget. Click save.

We may need to add more CSS later to align it.

Share this post


Link to post
Share on other sites

Posted · Report post

Ok thanks so much for helping, I finished social icons, they look exactly the same ;)

And how about the Search icon? Seems like it is supported by a totally different codes?

Share this post


Link to post
Share on other sites

Posted · Report post

The search field will be in a different hook. pagelines_search_form

You can edit that in the same manner as you did the icons. However you also might be able to get the same look using css to style the search field.

A full list of the hooks can be found here http://api.pagelines.com/hooks

Share this post


Link to post
Share on other sites

Posted · Report post

Ok I just finished :)

Thank you Rob, Danny and James for helping~

Have a good day

Share this post


Link to post
Share on other sites

Posted · Report post

The topic was marked as resolved.

Share this post


Link to post
Share on other sites

Posted · Report post

That site appears to be using the following in the header. This may be done by placing a widget in the header, but that will need extra CSS to align.


<div id="social-media-icons">

<a class="social-media-icon facebook" href="http://facebook.com">Facebook</a>

<a class="social-media-icon twitter" href="http://twitter.com">Twitter</a>

<a class="social-media-icon youtube" href="http://youtube.com">Vimeo</a>

<a class="social-media-icon google-plus" href="http://google.ca">Google+</a>

<a class="social-media-icon linkedin" href="https://www.linkedin.com/">LinkedIn</a>

</div>

Then, in the CSS for that site I found this:

#social-media-icons {

float: right;

margin-top: 60px;

}

a.social-media-icon {

display: inline-block;

width: 32px;

height: 32px;

margin-right: 6px;

background-position: 0 0;

overflow: hidden;

text-indent: -1000px;

-moz-transition: background-position .25s ease;

-webkit-transition: background-position .25s ease;

-o-transition: background-position .25s ease;

-ms-transition: background-position .25s ease;

transition: background-position .25s ease;

}

a.social-media-icon:hover {

background-position: 0 -32px;

}

.facebook {

background-image: url('images/facebook.png');

}

.twitter {

background-image: url('images/twitter.png');

}

.pinterest {

background-image: url('images/pinterest.png');

}

.flickr {

background-image: url('images/flickr.png');

}

.vimeo {

background-image: url('images/vimeo.png');

}

.youtube {

background-image: url('images/youtube.png');

}

.google-plus {

background-image: url('images/google-plus.png');

}

.dribble {

background-image: url('images/dribble.png');

}

.linkedin {

background-image: url('images/linkedin.png');

}

You'd have to include the full URL, not images/ but your full URL to the image.

The hook should have worked. Is there a dev site we can see?

1 person likes this

Share this post


Link to post
Share on other sites

Posted · Report post

That site appears to be using the following in the header. This may be done by placing a widget in the header, but that will need extra CSS to align.

Oh I just find a demo site here http://demo.onedesigns.com/pinboard/,

I also found those codes in the Chrome, but how could I use them,

Could I directly put them in the Custom CSS code, or in the theme Editor?

Thank you for helping

Share this post


Link to post
Share on other sites

Posted · Report post

You can add a simple hook associated with the Branding section, plus some CSS.

You'll want the PageLines Customize plugin found in the Store (free), installed and activated.

Once activated, you go to Dashboard > Plugins > Editor.

On the top right, you'll see a drop-down list. Select Pagelines-Customize. It will say "Inactive". Ignore that.

In the right column, you will see pagelines-customize/functions.php. Click it to open and edit.

Copy and paste this:


add_action('pagelines_inside_top_branding', 'my_unique_icons');

// function name

function my_unique_icons(){

?>

<div class="my_unique_icons"><a href="http://www.yoursite.com"><img src="http://www.yoursite.com/images/myimage1.jpg"></a> <a href="http://www.yoursite.com"><img src="http://www.yoursite.com/images/myimage2.jpg"></a>

</div>

<?php }

// end function

You will also want to add this to Dashboard > PageLines > Site Options > Custom Code in CSS Rules:

#branding .my_unique_icons {

    float: right;

    z-index: 10;

    position: relative;

}

Each icon may need individual CSS as well to ensure its placement is in a row.

Share this post


Link to post
Share on other sites

Posted · Report post

You can add a simple hook associated with the Branding section, plus some CSS.

You'll want the PageLines Customize plugin found in the Store (free), installed and activated.

Once activated, you go to Dashboard > Plugins > Editor.

On the top right, you'll see a drop-down list. Select Pagelines-Customize. It will say "Inactive". Ignore that.

In the right column, you will see pagelines-customize/functions.php. Click it to open and edit.

Copy and paste this:


add_action('pagelines_inside_top_branding', 'my_unique_icons');

// function name

function my_unique_icons(){

?>

<div class="my_unique_icons"><a href="http://www.yoursite.com"><img src="http://www.yoursite.com/images/myimage1.jpg"></a> <a href="http://www.yoursite.com"><img src="http://www.yoursite.com/images/myimage2.jpg"></a>

</div>

<?php }

// end function

You will also want to add this to Dashboard > PageLines > Site Options > Custom Code in CSS Rules:

#branding .my_unique_icons {

float: right;

z-index: 10;

position: relative;

}

Each icon may need individual CSS as well to ensure its placement is in a row.

thanks so much!

i will try it now

Share this post


Link to post
Share on other sites

Posted · Report post

...

Hi sir I have followed your instruction step by step but seems it does not work,

I changed "www.yoursite.com" to my website address, upload an image and replace the "http://yoursite.com/...es/myimage2.jpg"

Do I need to make other changes?

As I said, I am a new starter, Sorry to take your time

Share this post


Link to post
Share on other sites

Posted · Report post

HI,

All custom CSS needs to be added to either the Custom CSS/LESS area in Custom Code, your child themes style.css file or if you're using the PageLines Customisation plugin, add the custom CSS to the plugins style.css file.

Share this post


Link to post
Share on other sites

Posted · Report post

Hi,

Can you provide a link to the site where these social icons are not appearing please.

Share this post


Link to post
Share on other sites