Follow us on Twitter X-Cart on Facebook Wiki
Shopping cart software Solutions for online shops and malls
 

Trying to use javascript in catagory description

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design
 
Thread Tools Search this Thread
  #1  
Old 06-20-2005, 11:51 AM
 
toddmc toddmc is offline
 

Newbie
  
Join Date: Nov 2004
Posts: 9
 

Default Trying to use javascript in catagory description

What i am trying to do is to have a javascipt tag open up a separate window onclick. The html and javascript for this was generated in dreamweaver mx. I am pasting the html with the javascript into the catagory description. I have tried to just paste it all there, but when i leave the <script> tags it will delete all text in description. I also have tried to put the script tag in the head.tpl to call upon a separate javascript file, but still nothing. I have seen javascript work in other parts of xcart so i know it can work but will it in the description?

Please help!!

Here is the link if you want a visual of what im talking about, youll notice when you click on the 4 circles they should open up a separate window the size of the pic being displayed and with no browser functions. But nothing happens onclick.

http://www.benchworx.com/home.php?cat=248

Thanks,
Jamey Miller
Playnation Playsystems
jamey@playset.com
__________________
X-Cart/LiteCommerce 4.0
Reply With Quote
  #2  
Old 06-20-2005, 12:46 PM
 
balinor balinor is offline
 

Veteran
  
Join Date: Oct 2003
Location: Connecticut, USA
Posts: 30,253
 

Default

Try putting {literal} tags around the javascript. Example:

{literal} Insert Javascript here {/literal}

Not sure if javascript will work in the product descriptions, but it will definitely work elsewhere in the site.
__________________
Padraic Ryan
Ryan Design Studio
Professional E-Commerce Development
Reply With Quote
  #3  
Old 06-21-2005, 05:57 AM
 
toddmc toddmc is offline
 

Newbie
  
Join Date: Nov 2004
Posts: 9
 

Default Thanks

Thanks a lot, I put the literal tags with my javascript head info in the head.tpl and it works great. Thanks a million, you saved me alot of time!!

Jamey
__________________
X-Cart/LiteCommerce 4.0
Reply With Quote
  #4  
Old 07-05-2005, 11:59 AM
 
shiehshieh shiehshieh is offline
 

Advanced Member
  
Join Date: Oct 2004
Posts: 85
 

Default

Does anyone know how to make it work in the product description? I tried to add {literal} around it, but it doesn't work. Please advise. Thanks so much in advance!
__________________
Cheers,
Tom
X-Cart v4.1.9 PRO

Boba Tea Direct
"Your source for bubble tea, boba, coffee, tea, chai, and more"
www.bobateadirect.com

Hevla Coffee Co
Freshest roast-to-order low acid coffee
www.hevlacoffeeco.com
Reply With Quote
  #5  
Old 07-05-2005, 12:49 PM
 
balinor balinor is offline
 

Veteran
  
Join Date: Oct 2003
Location: Connecticut, USA
Posts: 30,253
 

Default

Not sure it will work in the product description....
__________________
Padraic Ryan
Ryan Design Studio
Professional E-Commerce Development
Reply With Quote
  #6  
Old 07-05-2005, 01:16 PM
 
shiehshieh shiehshieh is offline
 

Advanced Member
  
Join Date: Oct 2004
Posts: 85
 

Default

You mean, you don't think it's possible to get it to work in the product description? Oh no..... We have video demos on a bunch of these products that we're trying to integrate.

Hmm, if it works for the category description, why not for the product description?

Thanks again.
__________________
Cheers,
Tom
X-Cart v4.1.9 PRO

Boba Tea Direct
"Your source for bubble tea, boba, coffee, tea, chai, and more"
www.bobateadirect.com

Hevla Coffee Co
Freshest roast-to-order low acid coffee
www.hevlacoffeeco.com
Reply With Quote
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -8. The time now is 06:59 AM.

   

 
X-Cart forums © 2001-2020