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

replace javascript in catalog pages with call to external js

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design
 
Thread Tools Search this Thread
  #1  
Old 04-11-2005, 09:43 AM
  wowfundraising's Avatar 
wowfundraising wowfundraising is offline
 

Newbie
  
Join Date: Mar 2005
Posts: 8
 

Default replace javascript in catalog pages with call to external js

When I generate the html catalog pages, I'd like to replace the large block of javascript with a call to an external javascript file. From what I understand, the one line call to an external js file is better for SEO than the really long block of javascript code as it is now.

I looked at the admin/html_catalog.php file but could not make heads/tails of it for what I want to do.

Can anyone point me in the right direction?

Thanks,
Scott
__________________
Version 4.0.12
Reply With Quote
  #2  
Old 05-31-2005, 08:01 AM
  wowfundraising's Avatar 
wowfundraising wowfundraising is offline
 

Newbie
  
Join Date: Mar 2005
Posts: 8
 

Default update

Hey, someone online here mailed me about whether or not I'd gotten this working. The answer is no - not a peep from anyone about how to do it.

Basically, I put the whole issue on back burner. I would still like to accomplish this. Can anyone on the XCART team point me in the right direction?

Great product... I'm a little surprised posts like mine can get several months old without *any* reply whatsoever... I didn't think it was *that* bad of a request.

-scott
__________________
Version 4.0.12
Reply With Quote
  #3  
Old 08-08-2005, 12:27 PM
 
Dorette Dorette is offline
 

Advanced Member
  
Join Date: Jun 2005
Posts: 71
 

Default

any news so far?
__________________
Version 4.0.17
Reply With Quote
  #4  
Old 08-08-2005, 12:41 PM
  wowfundraising's Avatar 
wowfundraising wowfundraising is offline
 

Newbie
  
Join Date: Mar 2005
Posts: 8
 

Default No. Nobody EVER bothers to reply.

NO, I have never received a reply - positive or negative - to my question. So far as support for the product, the forums are useless. I've basically given up on getting an answer from anyone who is part of the "XCART TEAM".

H*ll, even if they replied - don't know and not working on it - it would be better than totally being ignored. Or even, hey, "you posted to the wrong place" or "hey, you have to pay for an answer" - but NOTHING. CUSTOMER SUPPORT = BIG FAT ZERO on this one.

Guess I'm lucky it hasn't been mission critical.
__________________
Version 4.0.12
Reply With Quote
  #5  
Old 08-08-2005, 12:42 PM
 
balinor balinor is offline
 

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

Default

Remember, this board is run by users, not X-Cart themselves. If you want a guaranteed response, best to open a ticket with X-Cart.
__________________
Padraic Ryan
Ryan Design Studio
Professional E-Commerce Development
Reply With Quote
  #6  
Old 08-08-2005, 12:53 PM
  wowfundraising's Avatar 
wowfundraising wowfundraising is offline
 

Newbie
  
Join Date: Mar 2005
Posts: 8
 

Default FINALLY!

For the benefit of the forums here, I recommend someone looking to make sure posts just don't fall through the cracks without ever getting a reply.

It is confusing to post on a form on x-cart.com and never hear anything at all.

I appreciate your post. I'm disappointed it took a crappy message like I posted minutes ago in order to get a reply.

Back to the topic at hand, now that there is some activity... any ideas on the original question? I think there are at least three of us interested from the mail I have received and the additional post on the forum.

Thanks in advance,
Scott
__________________
Version 4.0.12
Reply With Quote
  #7  
Old 08-08-2005, 01:13 PM
 
balinor balinor is offline
 

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

Default

Scott,

Do you have any idea how many posts are added here each day? There are over 7000 users of this forum, and 3 VOLUNTEER moderators. We try to keep things running smoothly, but there is absolutely no way we are going to guarantee an answer to every post.

As with most forums, 99% of the members here want immediate help, but don't ever give anything back to the community. The 1% of people who do can only do so much.

On top of that, if no one has an answer to your question, you obviously aren't going to get an answer, which is what probably happened with this post. If I had an answer for you, I'd be happy to help, but I don't.

As I said above, if you want a guaranteed answer, post a ticket in your X-Cart help desk.
__________________
Padraic Ryan
Ryan Design Studio
Professional E-Commerce Development
Reply With Quote
  #8  
Old 08-08-2005, 01:23 PM
 
Dorette Dorette is offline
 

Advanced Member
  
Join Date: Jun 2005
Posts: 71
 

Default

Hi Ryan,
this is the what is in the home.tpl

I am guessing the javascript is this if $body_onload ne ''} onload="{$body_onload}"{/if}

if so where do you think I can find this tag so i can change it to a .js file


<BODY leftmargin="0" topmargin="0" rightmargin="0" bottomargin="0" marginwidth="0" marginheight="0"{if $body_onload ne ''} onload="{$body_onload}"{/if}>
{ include file="rectangle_top.tpl" }
{ include file="head_customer.tpl" }
{if $active_modules.SnS_connector}
{include file="modules/SnS_connector/header.tpl"}
{/if}
__________________
Version 4.0.17
Reply With Quote
  #9  
Old 08-08-2005, 01:25 PM
 
Dorette Dorette is offline
 

Advanced Member
  
Join Date: Jun 2005
Posts: 71
 

Default

i think i found the file it is

common_js.tpl

now how do I call it as


<SCRIPT src="common.js"></SCRIPT>
__________________
Version 4.0.17
Reply With Quote
  #10  
Old 11-24-2005, 04:24 PM
  BoomBoomBap's Avatar 
BoomBoomBap BoomBoomBap is offline
 

Senior Member
  
Join Date: Nov 2002
Location: San Francisco
Posts: 184
 

Default

This should do the trick...

Code:
Open: skin1/rectangle_top.tpl Find: {include file="common_js.tpl"} Modify: {* include file="common_js.tpl" *} Add: <script type="text/javascript" src="common_js.js" language="JavaScript 1.2"></script>

Code:
Open: common_js.tpl Delete: {literal} Delete: {/literal} Rename File: common_js.js

I have NOT tested this extensively (just a few clicks around my local install) but I can't see any reason why it wouldn't work...

Also FYI to echo balinor's comment - you can't exactly enter a forum and demand answers. 99% of this Forum is powered by other users with very little involvement from X-cart staff. Hang in there and usually someone will come through with an answer. If not perhaps no one has an answer just yet...
__________________
Site 1 > XCART LIVE 3.4.12

Site 2 > XCART LIVE 4.0.17
Reply With Quote
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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:20 AM.

   

 
X-Cart forums © 2001-2020