Jump to content

Javascript - Whitepage


Man_

Recommended Posts

Hello friends,

 

I hope someone can help me out, see; I am build my theme and I add the following JS.

<script language="javascript">
		$(function(){
			$('form').jqTransform({imgPath:'{$STORE_URL}/skins/{$SKIN_FOLDER}/images/'});
		});
	</script>

to the HTML and preview and it shows white-blank page, when I remove, everything works well, does anyone know a solution?

 

Thanks in advance.

Link to comment
Share on other sites

This looks to be a jQuery statement. If so, it cannot run until the jQuery framework is loaded and started, and that won't happen until last -- after all the images and CSS are loaded.

 

Once the /js/common.js gets loaded and executed, this "starts" the jQuery framework:

jQuery(document).ready(function()

 

I suggest you put this in the script.js file found in the skin's /js/ folder.

 

I suppose you are getting a white screen because javascript is crashing hard.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...