Can we use javascript?

I’m trying to add a code to top.tpl for AddThis. This is the code:


```php


Share
|







```

When placing it I get this error when viewing the site:

[B]Fatal error: Smarty error: [in top.tpl line 33]: syntax error: unrecognized tag: data_track_clickback:true (Smarty_Compiler.class.php, line 440) in /home/username/public_html/dreamsoy/classes/templater/Smarty.class.php on line 1095[/B]

When I remove this line it works without errors:

```php ```

But I need that line because that's what tells it to track clickbacks. Also on another note, I can't get it to align to the right. Any suggestions? Here's the page: [URL="http://www.dreamsoy.com"]http://www.dreamsoy.com[/URL]

You need to surround javascript with literal tages:


```php

[COLOR=Red]{literal}[/COLOR]


[COLOR=Red]{/literal}[/COLOR]

```

Excellent that got rid of the error, thanks!



Any suggestions about right-aligning the AddThis buttons? It’s at the top of the page in the header area.

[quote name=‘Brennie369’]Excellent that got rid of the error, thanks!



Any suggestions about right-aligning the AddThis buttons? It’s at the top of the page in the header area.[/quote]

Find this css: [url]http://s7.addthis.com/static/r07/widget53.css[/url] and change:


.addthis_default_style .addthis_separator, .addthis_default_style .at300b, .addthis_default_style .at300m, .addthis_default_style .at300bs {
float: [COLOR=Red]left[/COLOR];


}





to


.addthis_default_style .addthis_separator, .addthis_default_style .at300b, .addthis_default_style .at300m, .addthis_default_style .at300bs {
float: [COLOR=Red]right[/COLOR];


}

That css isn’t stored in my site it’s on the AddThis site so I don’t have access to it.

The AddThis feature is also breaking SSL on your secure pages because it’s pulling the image from a nonsecure source

Here is the fix



[url]http://www.addthis.com/help/ssl[/url]




[QUOTE]HTTPS / SSL Support



If you are using AddThis on a https:// page you will need to make some small changes.



In the code of the widget replace:



http://s7.addthis.com or http://s5.addthis.com



with:



[url]https://s7.addthis.com/[/url]



That’s it. All features will continue to work the same.[/QUOTE]

Is there anyway to exclude it from my secure pages?



Just saw your fix post - THANKS I appreciate that heads up!

When we had the addthis on our older CS site we just put it on the “product” pages as this seemed to be the main place someone would want to talk about something. This avoided the image issue when it crossed over to ssl.



We did have addthis on the home page too but we took it off to keep the main page as small as possible and without having to access external sites for it too load.

[quote name=‘Brennie369’]That css isn’t stored in my site it’s on the AddThis site so I don’t have access to it.[/quote]

Then try to create a new class in your hosted css file with:


.addthis_toolbox addthis_default_style!important
{
float: right;
}




or


.addthis_default_style .addthis_separator!important,
.addthis_default_style .at300b!important,
.addthis_default_style .at300m!important,
.addthis_default_style .at300bs!important
{
float: right;
}


If that doesn’t work then it would need to be edited ‘live’ (admin or FTP access necessary).

Neither of those worked. By “live” do you mean editing it on the hosting site?

[quote name=‘Brennie369’]Neither of those worked. By “live” do you mean editing it on the hosting site?[/quote]

Yes

Just wrap their content with a div like below:


```php




Share
|





{literal}


{/literal}

```

[quote name=‘whiplash13’]Just wrap their content with a div like below:


```php




Share
|





{literal}


{/literal}

```[/quote]
It is currently wraped inside ```php
``` therefor I sugested to use:

```php .addthis_toolbox addthis_default_style!important
{
float: right;
} ```

[quote name=‘Brennie369’]Neither of those worked. By “live” do you mean editing it on the hosting site?[/quote]

Hi,



add this to the ‘styles.css’ file:


.addthis_toolbox,
.addthis_default_style,
.addthis_default_style a
{
float: right;
padding: 10px 10px 0px 30px;
text-decoration: none!important;
}




Demo: CS-Cart demo

[quote name=‘indy0077’]Hi,



add this to the ‘styles.css’ file:


.addthis_toolbox,
.addthis_default_style,
.addthis_default_style a
{
float: right;
padding: 10px 10px 0px 30px;
text-decoration: none!important;
}




Demo: CS-Cart demo[/QUOTE]



THAT DID IT! Thank you!