If you want to accomplish the ip thangy in script on the client, just:
HTML content:
This is normal HTML text, and we just want
to say, Welcome
<script type=blah...>
document.write (ip);
</script>.
where 'ip' is a variable you have previously stuffed with the appropriate string.