Getting AT social icons to open in a new tab


#1

Hi there,

I’ve just started using the hiero theme for my new wordpress blog: http://thecrashcodex.com/

Currently I’m using the AT social icons widget. I’m curious as to how I can edit the widget or code such that the links open in a new tab or window.

Thanks!


#2

Hi

You can do this by adding target="_blank" to the anchor tags of the social icons widget, but as there are no hooks available you will have to do it on the core theme files.

The path to the file is /wp-content/themes/hiero/inc/widgets/widget-social-icons.php

Change line number 144 which now looks like

<li class="widget-si-<?php echo $athemes_widgets_name; ?>"><a href="<?php echo $athemes_widgets_field_value; ?>" title="<?php echo $athemes_widgets_title; ?>"><i class="ico-<?php echo $athemes_widgets_name; ?>"></i></a></li>

to

<li class="widget-si-<?php echo $athemes_widgets_name; ?>"><a href="<?php echo $athemes_widgets_field_value; ?>" target="_blank" title="<?php echo $athemes_widgets_title; ?>"><i class="ico-<?php echo $athemes_widgets_name; ?>"></i></a></li>

Hope it helps!!

Thanks


#3

After making the change you stated above, I tried re-uploading the files but I get an error saying 'The theme is missing the style.css stylesheet’
What do I do?

Regards,

Zak


#4

Hi Zak

I am not sure if you have made changes to the file I have asked for. if yes this wouldn’t have happened.

can you please note down the steps that you followed here.

Thanks


#5

Hi

I unzipped the file hiero.1.7
Then I opened the directory hiero, then inc, then widgets and there i opened the source file widgets-social-icons.php
Then I went to line 144 and did the change you mentioned earlier.
Then I zipped the file again and uploaded it, but it gave me an error.
I couldn’t find the code you were talking about in wordpress even though I went to the same place. It’s weird.

Waiting for your reply

Thanks


#6

Hi

It really seems weird that you couldn’t find the file.

The other thing which you did also seems correct but it seems it needs a closer look.

Can you send me the details for your site in my mail id so that I can help you with it. My mail id is marutimohanty89@gmail.com.

You can get me a temporary admin login to your site and FTP details.

Thanks and Regards,
Maruti