...

View Full Version : How do you resize a element of javascript



Atari1596
08-01-2010, 05:45 PM
I have a <script></script> that I basically want to hide, so I want to resize it to 1px by 1px. I have tried putting it inside <div></div> and <span></span> tags but that didn't work. I am new to this forum and I thought if anyone could help, it would be someone from here.

Any help would be greatly appreciated. Thanks in advance

met
08-01-2010, 06:02 PM
what?

you can't "resize" javascript, it's a client side scripting language that does stuff. there's no visible output (unless the JS outputs something of course)

if you want to hide the source, give up now, as it isn't possible.

Atari1596
08-01-2010, 08:21 PM
That makes sense, but the javascript does have an output. It puts a counter on my page that I would rather not have. Is there a way to resize the javascript's output, or at very least cover it up with an image or something?

Again, thanks for the help.

met
08-01-2010, 08:46 PM
perhaps post the javascript and any relevant code

Atari1596
08-01-2010, 08:49 PM
Sure.

<A href="http://www.alexa.com/siteinfo/www.askpersonalquestions.com"><SCRIPT type='text/javascript' language='JavaScript' src='http://xslt.alexa.com/site_stats/js/s/a?url=www.askpersonalquestions.com'></SCRIPT></A>

met
08-02-2010, 06:46 PM
if you want to hide it, just remove it ? seems kind of redundant.

anyway



<!DOCTYPE html>
<head>
<title>Untitled Document</title>
<style type="text/css">
/* will completely hide it..but anyone can still view it should they look at the source */
#alexaStats { display:none; }
</style>
</head>

<body>

<div id="alexaStats">
<A href="http://www.alexa.com/siteinfo/www.askpersonalquestions.com"><SCRIPT type='text/javascript' language='JavaScript' src='http://xslt.alexa.com/site_stats/js/s/a?url=www.askpersonalquestions.com'></SCRIPT></A>
</div>

</body>
</html>


the generated code has no IDs or Classes appended to it so it's just wrapped in a DIV and "hid" it.

Atari1596
08-03-2010, 12:00 AM
Thanks, that worked perfectly. I really appreciate your help, met.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum