Page 1 of 1

path() is not a function?

Posted: Mon Mar 24, 2008 7:22 am
by JAB Creations
It looks like any other function I've written, what am I missing here?

Code: Select all

<script type="text/javascript">var path = 'http://example.com/123';function path() {alert (path);}</script>

Code: Select all

<a href="javascript&#058; path();">alert</a>
* The semi-colon is being output as an entity in my preview of the post.

Re: path() is not a function?

Posted: Mon Mar 24, 2008 7:23 am
by JAB Creations
Ha I realized it the moment after I posted, the function and the variable have the exact same name. Ops! :mrgreen: