Camen Design Forum

embedd youtube videos?

MS

I tried to mess with the avatar -code. Instead of the md5 thing, id like to have avatars' filenames as username.png (cause i couldnt figure out the md5 stuff myself :P

%
<img src="/avatar/' . md5(trim($node->nodeValue)) . '.png" alt="" />
%

How should i modify this line of code so someone like 'ms' would have the avatar name ms.png. Propably an easy task, but i just keep getting errors no matter how i try to accomplish this :)

Thanks!

- MS

:: @MS added on 26 Oct ’13 · 07:11

Oh, and i also tried to change the code so it would show something like a default icon in case there is no 'username.jpg' but outcame failure, so if its a very simple one line of code could someone help me out, id be more than happy once more! :)

Append

(Leave this as-is, it’s a trap!)

Only the original author or a moderator can append to this post.

Pro tip: Use markup to add links, quotes and more.

Your friendly neighbourhood moderators: Kroc, Impressed, Martijn