1082 users online
NEW ZEALAND

GP Forums / Tech Discussion / Topics / Programming & HTML Post a new thread in the current forumPost a new reply in the current thread
What are you working on today?
Page: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 ... Last Last

Soup Erman
Winter is Coming
Old Post 29 Oct 2010 11:32 pm REPLY Edit Profile Send PM Add Friend

kyreenaTIME wrote:
hah, thanks guys, the deal was that it all had to be text based for SEO nonsense



You could use css to hide the text, so users will see an image and search bots will see the text. This is what I usually do for banner headings:

Code
h2 {
  font-size:1px;
  color:black; /* same as whatever your background color is */
  background:url('logo.png');
}

<h2>My Awesome Website</h2>



Looking at a clients magento website, they've got something a bit more thorough:

Code
.header .logo strong {
  font-size: 0px;
  height: 0px;
  left: -999em;
  line-height: 0;
  overflow: hidden;
  position: absolute;
  text-indent: -999em;
  top: -999em;
  width: 0px;
}
<h1 class="logo">
  <strong>Website Title</strong>
  <a href="homepage-link" class="logo">
    <img src="logo.png" alt="Logo Text">
  </a>
</h1>



You could also use position and z-index to overlay the image on top of the text

OfflineSoup Erman is offline
Xelogen
Old Post 30 Oct 2010 1:01 am REPLY Edit Profile Send PM Add Friend
Investigating KPI dashboards _b

OfflineXelogen is offline
Bandy
Old Post 30 Oct 2010 2:20 am REPLY Edit Profile Send PM Add Friend
I was told search engines view hiding text like that as a black hat technique and you'll get penalised for doing the same colour trick. Would be interested to hear if this isn't the case.

In other news, continued my work on jobsboard.co.nz but it's slow going with no foreseeable monetary benefit. Today I added job alerts and re-thought how the internal messaging works. Points for anyone that registers!
Last edited 30 Oct 2010 at 2:27 am by Bandy

OfflineBandy is offline
Soup Erman
Winter is Coming
Old Post 30 Oct 2010 10:36 am REPLY Edit Profile Send PM Add Friend

Bandy wrote:
I was told search engines view hiding text like that as a black hat technique and you'll get penalised for doing the same colour trick. Would be interested to hear if this isn't the case.


http://googlewebmastercentral.blogs...accessible.html

As long as the text matches the image exactly then it's generally fine.

OfflineSoup Erman is offline
Stevie
Old Post 31 Oct 2010 2:59 am REPLY Edit Profile Send PM Add Friend
Working on a PSD->HTML/CSS conversion of a design. Harder than I initially thought. Thanks gradients.

OfflineStevie is offline
dement
Old Post 1 Nov 2010 5:38 pm REPLY Edit Profile Send PM Add Friend

Stevie wrote:
Working on a PSD->HTML/CSS conversion of a design. Harder than I initially thought. Thanks gradients.



have you tried css3 gradients?
---

elliarto wrote:
Just went to GP to get doctors cert so I can stay home and watch game, he gave me anti depressants :/

Game time!!


Offlinedement is offline
kTIME
Old Post 2 Nov 2010 3:12 pm REPLY Edit Profile Send PM Add Friend

Soup Erman wrote:
You could use css to hide the text, so users will see an image and search bots will see the text. This is what I usually do for banner headings:


You could also use position and z-index to overlay the image on top of the text



Yeah… emphasis on "nonsense". I told him about doing that, but he wanted perfect SEO, so that the text is all laid out nicely in Google search and for god knows what other reasons :/ basically alt text etc was not good enough :/



haze_xp wrote:
Here are some general best practices when it comes to cleaning up dead code.

Firstly, you really need to be using a version control system for something like this, if you're not already doing so, use Subversion, Git or Mercurial.

If there's already a VCS in place, you might want to have a look through the history of all of the pieces of code, something that hasn't been touched for a while is more likely to be dead code.

Commit one change at a time to your VCS, you don't want to have to look through the history later and have to spend a while working out what caused something to break.

Make good use of grep or some other searching tool to observe where a code fragment is being referenced, if it's not being referenced or called at all, it's a good candidate for removal.

Others here will have plenty more experience at this than I do and should have better suggestions :).




Cheers, we use Subversions, and have some really good developers who could do all this, but are just too busy, so I thought I'd try give it a go, so this will help :)

OfflinekTIME is offline
Soup Erman
Winter is Coming
Old Post 2 Nov 2010 5:26 pm REPLY Edit Profile Send PM Add Friend

kyreenaTIME wrote:
Yeah… emphasis on "nonsense". I told him about doing that, but he wanted perfect SEO, so that the text is all laid out nicely in Google search and for god knows what other reasons :/ basically alt text etc was not good enough :/


well it's the clients call at the end of the day, but the SEO results would be exactly the same...

OfflineSoup Erman is offline
pantz
Old Post 2 Nov 2010 6:57 pm REPLY Edit Profile Send PM Add Friend

Soup Erman wrote:
well it's the clients call at the end of the day, but the SEO results would be exactly the same...


I disagree, more weight is placed on a <h1> tag than it is alt text in SEO. If I wanted to replace a text heading with an image but still maintain the strenght of a <h1> tag I would use something like this,

html;

<h1><span>your seo text here</span></h1>

css;

h1 {
margin: _ _ _ _;
width: ___px;
height: __px;
background-image: url(images/image.jpg);
}

h1 span {
display: none;
}

This will show the user the image but search engine bots/spiders will still read the text within the span class.
---
Xbox Live Gamertag: b1ades77

Offlinepantz is offline
Soup Erman
Winter is Coming
Old Post 2 Nov 2010 7:40 pm REPLY Edit Profile Send PM Add Friend

pantz wrote:
I disagree, more weight is placed on a <h1> tag than it is alt text in SEO. If I wanted to replace a text heading with an image but still maintain the strenght of a <h1> tag I would use something like this,

This will show the user the image but search engine bots/spiders will still read the text within the span class.


I was talking about hidden html, not alt text. See my previous posts

OfflineSoup Erman is offline
Edward Diego
In The House
In A Heartbeat
Old Post 3 Nov 2010 12:43 pm REPLY Edit Profile Send PM Add Friend

haze_xp wrote:

Make good use of grep or some other searching tool to observe where a code fragment is being referenced, if it's not being referenced or called at all, it's a good candidate for removal.



Odds are it's PHP, so I'd recommend http://www.jetbrains.com/phpstorm/
---

Lite wrote:
I did have a weapon on me... ...it was a beer bottle just like most other people had


OnlineEdward Diego is currently online
kTIME
Old Post 4 Nov 2010 1:16 pm REPLY Edit Profile Send PM Add Friend
Ah, I see, yes it is PHP :) Thanks

OfflinekTIME is offline
Stevie
Old Post 4 Nov 2010 1:30 pm REPLY Edit Profile Send PM Add Friend

pantz wrote:
I disagree, more weight is placed on a <h1> tag than it is alt text in SEO. If I wanted to replace a text heading with an image but still maintain the strenght of a <h1> tag I would use something like this,

<h1><span>your seo text here</span></h1>



Why bother with the <span> ?.

Code
h1{display: block; font-size: 0px; text-indent: -9999px; line-height: 0;}


OfflineStevie is offline
pantz
Old Post 4 Nov 2010 6:23 pm REPLY Edit Profile Send PM Add Friend
Personal choice I guess, both work equally. I'm just not into bloated css like above, it looks like an old hack to hide text o_O
---
Xbox Live Gamertag: b1ades77

Offlinepantz is offline
Egor
Old Post 4 Nov 2010 6:37 pm REPLY Edit Profile Send PM Add Friend
The span is better if you're talking about an <a> link. With text-indent: -999, Firefox puts a big ugly selection border around the invisible part when you click on it otherwise :mad:

OfflineEgor is offline
Bell
[!]
Old Post 6 Nov 2010 8:41 pm REPLY Edit Profile Send PM Add Friend
Working mainly on gameplay input mechanics at the moment.
Using lua almost exclusively, really miss C++.

OfflineBell is offline
Jihad Jeep
Old Post 6 Nov 2010 11:50 pm REPLY Edit Profile Send PM Add Friend
Started writing thesis, which is going to occupy me for the next wee while and is perhaps the least exciting part of the whole process.

Wrinkled out some bugs in some contracting work that I'm doing, a few days after saying that if there were any bugs then I'd be up for some castration, now how to word it so that the git logs don't give me away? :p

OfflineJihad Jeep is offline
Tank
dunedin massive!
Old Post 9 Nov 2010 2:45 pm REPLY Edit Profile Send PM Add Friend

Egor wrote:
The span is better if you're talking about an <a> link. With text-indent: -999, Firefox puts a big ugly selection border around the invisible part when you click on it otherwise :mad:


outline: none;


trying to find motivation to start new projects... lacking...

also, managed to sign up for a .net web app project, time to come out of my php/mysql shell :(

for a start, if I wanted to create a really simple CRUD cms for a few pages - whats the smart way to go about it (Where should I start reading)? (asp.net)

OfflineTank is offline
Edward Diego
In The House
In A Heartbeat
Old Post 9 Nov 2010 3:24 pm REPLY Edit Profile Send PM Add Friend

Tank wrote:
outline: none;


trying to find motivation to start new projects... lacking...

also, managed to sign up for a .net web app project, time to come out of my php/mysql shell :(

for a start, if I wanted to create a really simple CRUD cms for a few pages - whats the smart way to go about it (Where should I start reading)? (asp.net)



ASP.NET MVC would be a good place - uses bits of ASP.NET, but is simpler (no bullshit page lifecycle necessary, IIRC), and more modern.
---

Lite wrote:
I did have a weapon on me... ...it was a beer bottle just like most other people had


OnlineEdward Diego is currently online
Edward Diego
In The House
In A Heartbeat
Old Post 9 Nov 2010 3:26 pm REPLY Edit Profile Send PM Add Friend
Flash/Flex is the devil for this kind of undocumented shit: http://www.bit-101.com/blog/?p=946

Also, **** FlowPlayer for the shittiest goddamned most untestable API I have ever encountered ever. A ****ing public ****ing constructor on a shitting public ****ing class SHOULD NOT TAKE A PACKAGE PRIVATE CLASS AS A ****ING PARAMETER, you Finnish ****s.

/angry
---

Lite wrote:
I did have a weapon on me... ...it was a beer bottle just like most other people had


OnlineEdward Diego is currently online
Edward Diego
In The House
In A Heartbeat
Old Post 9 Nov 2010 5:24 pm REPLY Edit Profile Send PM Add Friend
Rage sorta over, we just created our own little loader inside the same package, which allowed us to instantiate it... then we had to trial-and-error getting it setup in a correct state. >_< Which is what a constructor's supposed to do. Instead FlowPlayer has a Launcher() to do that... except that everything in the Launcher() is private - and nothing returns a FlowPlayer instance anyway, which makes our unit testing of our plugin impossible.

Tomorrow's fun event - catching our video event notifications within FlexUnit - the concept of writing a basic HTTP server in ActionScript 3 terrifies me.
---

Lite wrote:
I did have a weapon on me... ...it was a beer bottle just like most other people had


OnlineEdward Diego is currently online
porges
of mass destruction
Old Post 9 Nov 2010 6:18 pm REPLY Edit Profile Send PM Add Friend

Edward Diego wrote:
A ****ing public ****ing constructor on a shitting public ****ing class SHOULD NOT TAKE A PACKAGE PRIVATE CLASS AS A ****ING PARAMETER, you Finnish ****s.

/angry



Wow, that kind of stuff won't even compile in most languages...
---
You are standing in an open field west of a white house, with a boarded front door.
There is a small mailbox here.

> _
---
Xbox Live Gamertag: porg3s

Offlineporges is offline
Egor
Old Post 9 Nov 2010 6:35 pm REPLY Edit Profile Send PM Add Friend

Tank wrote:
outline: none;



Yeah but then you break accessibility / keyboard navigation.

OfflineEgor is offline
Tank
dunedin massive!
Old Post 9 Nov 2010 6:41 pm REPLY Edit Profile Send PM Add Friend

Egor wrote:
Yeah but then you break accessibility / keyboard navigation.



Yeah but you can replace feedback of the outline with other styles via :hover/:active ?

OfflineTank is offline
Edward Diego
In The House
In A Heartbeat
Old Post 11 Nov 2010 11:40 am REPLY Edit Profile Send PM Add Friend

porges wrote:
Wow, that kind of stuff won't even compile in most languages...



Yeah, I know, the whole environment's a disgrace tbh. The constructor on the FlowPlayer class can't create itself in a correct state - it relies on a 'Launcher' to provide all its dependencies, configured precisely how it needs them to be - and the dependencies have dependencies on each other.... basically, FlowPlayer's constructor has its guts hanging out, it's ugly as sin.
---

Lite wrote:
I did have a weapon on me... ...it was a beer bottle just like most other people had


OnlineEdward Diego is currently online

Page: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 ... Last Last

Post a new thread in the current forumPost a new reply in the current thread

Print Show printable version
Email Email this page to a friend
Subscribe Receive updates to this thread

All times are GMT +12 hours. The time now is 11:53 am.
Previous Thread | Next Thread