# Calling javascript function?

**URL:** <https://forum.kirupa.com/t/calling-javascript-function/311347>\
**Category:** Uncategorized\
**Created:** [July 3, 2010, 3:05pm UTC](https://forum.kirupa.com/t/calling-javascript-function/311347 "2010-07-03T15:05:46Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Soledad](https://avatars.discourse-cdn.com/v4/letter/s/97f17d/32.png) [@Soledad](https://forum.kirupa.com/u/Soledad)\
**Post date:** [July 3, 2010, 3:05pm UTC](https://forum.kirupa.com/t/calling-javascript-function/311347/1 "2010-07-03T15:05:46Z")

</div>

hello everybody

I put this javascript code in my new blog :

```php

<script language="javascript" type="text/javascript">
function showAlert() {
 alert('Hello World - this is an alert message!');
}
</script>

```

and wanna call it from flash

when the flash is embedded in the same page it’s so easy

```php

btn.onRelease = function () { 
getURL('javascript:showAlert()')
}

```

but I wanna embed the flash in some websites and calling the function which is found in my blog

I did this but it failed :

```php

btn.onRelease = function () { 
getURL('javascript:baseURL("http://engnajjar.blogspot.com/") & showAlert()')
}

```

please help me

thanks
