Keyword

Extra Space

  • Bluebeep
  • Bluebeep's Avatar Topic Author
  • Offline
  • New Member
More
12 years 5 months ago #64849 by Bluebeep
Extra Space was created by Bluebeep
Hi,

My first post - sorry if this isn't in the right category but I did look around and the other 3 didn't look like they worked for this.

I have a site using K2 and the 'Written by" (itemAuthor) has a space I'm trying to remove. Please see the image.

Where can I remove the nbsp?

Please Log in or Create an account to join the conversation.

  • Bluebeep
  • Bluebeep's Avatar Topic Author
  • Offline
  • New Member
More
12 years 4 months ago #64850 by Bluebeep
Replied by Bluebeep on topic Re: Extra Space
It seems that Google is using the 'by Author' now and it associates the authors Google account and profile picture with where it finds 'by Whoever'.

This makes it more important for me to figure this one out.

Articles that are submitted are not showing the profile and some have told me it's coz of the nbsp.

Does anyone have an idea? I don't know if this is a K2 thing or the template that I'm using really but it would be helpful to be pointed in the right direction.

Thanks!

Please Log in or Create an account to join the conversation.

  • Bluebeep
  • Bluebeep's Avatar Topic Author
  • Offline
  • New Member
More
12 years 4 months ago #64851 by Bluebeep
Replied by Bluebeep on topic Re: Extra Space
Waited for a month to get some help but I figured it out myself.

Here is the answer if anyone needs it...

Edit the file item.php located in: components/com_k2/templates/default

Around line 71 you'll see:
<?php echo K2HelperUtilities::writtenBy($this->item->author->profile->gender); ?>&nbsp;

I think the last &nbsp; was intended for the beginning of the line because as you can see in the picture I posted before there is no space between the time and author. So here is how I edited mine:
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<?php echo K2HelperUtilities::writtenBy($this->item->author->profile->gender); ?>

I put 5 nbsp before the php code. Now it looks good and probably Google will show the author profile also.

Won't report back if Google shows the author profile. No love from this site means I won't be wasting my time here either. I just wanted to finish what I started.

Lata.

Please Log in or Create an account to join the conversation.


Powered by Kunena Forum