Solved

Syntax error

Posted on 2013-12-18
4
386 Views
Last Modified: 2013-12-18
Hi- BBB gave us this code to use, but dreamweaver says there is a syntax error, It says the error is on the line that reads:unescape('%2Flogo%2Fmagickitchencom-1000001150.js') +

code below, any idea where the problem lies?

<a id="bbblink" class="ruhzbum" 
href="http://www.bbb.org/sanjose/business-reviews/food-
products/magickitchencom-in-los-altos-ca-1000001150#bbbseal" 
title="MagicKitchen.com, Food Products, Los Altos, CA" style="display: 
block;position: relative;overflow: hidden; width: 150px; height: 68px; 
margin: 0px; padding: 0px;"><img style="padding: 0px; border: none;" 
id="bbblinkimg" src="http://seal-
sanjose.bbb.org/logo/ruhzbum/magickitchencom-1000001150.png" 
width="300" height="68" alt="MagicKitchen.com, Food Products, Los Altos, 
CA" /></a><script type="text/javascript">var bbbprotocol = ( ("https:" == 
document.location.protocol) ? "https://" : "http://" ); document.write
(unescape("%3Cscript src='" + bbbprotocol + 'seal-sanjose.bbb.org' + 
unescape('%2Flogo%2Fmagickitchencom-1000001150.js') + "' 
type='text/javascript'%3E%3C/script%3E"));</script>

Open in new window

0
Comment
Question by:mel200
  • 2
4 Comments
 
LVL 52

Expert Comment

by:Scott Fell, EE MVE
ID: 39727416
Just place it on your site. It will work regardless of what dreamweaver shows.  http://jsbin.com/AXaSEdo/1/edit?html,output
0
 

Author Comment

by:mel200
ID: 39727899
I did, and it works, but I don't want it interfering with anything else, or slowing down my site or anything. Can we discover why it is showing a syntax error? Thanks.
0
 
LVL 35

Accepted Solution

by:
Robert Schutt earned 500 total points
ID: 39728113
Put a backslash at the end of line 13, it makes the string literal valid (in Firebug).
<a id="bbblink" class="ruhzbum" 
href="http://www.bbb.org/sanjose/business-reviews/food-
products/magickitchencom-in-los-altos-ca-1000001150#bbbseal" 
title="MagicKitchen.com, Food Products, Los Altos, CA" style="display: 
block;position: relative;overflow: hidden; width: 150px; height: 68px; 
margin: 0px; padding: 0px;"><img style="padding: 0px; border: none;" 
id="bbblinkimg" src="http://seal-
sanjose.bbb.org/logo/ruhzbum/magickitchencom-1000001150.png" 
width="300" height="68" alt="MagicKitchen.com, Food Products, Los Altos, 
CA" /></a><script type="text/javascript">var bbbprotocol = ( ("https:" == 
document.location.protocol) ? "https://" : "http://" ); document.write
(unescape("%3Cscript src='" + bbbprotocol + 'seal-sanjose.bbb.org' + 
unescape('%2Flogo%2Fmagickitchencom-1000001150.js') + "' \
type='text/javascript'%3E%3C/script%3E"));</script>

Open in new window

0
 

Author Closing Comment

by:mel200
ID: 39728146
Perfect, thanks!
0

Featured Post

Master Your Team's Linux and Cloud Stack

Come see why top tech companies like Mailchimp and Media Temple use Linux Academy to build their employee training programs.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Why doesn't Google directions work? 6 47
Jquery 10 20
replace link with jQuery 4 14
Syntax for query to update table 2 14
Find out what you should include to make the best professional email signature for your organization.
Color can increase conversions, create feelings of warmth or even incite people to get behind a cause. If you want your website to really impact site visitors, then it is vital to consider the impact color has on them.
In this tutorial viewers will learn how to embed Flash content in a webpage using HTML5. Ensure your DOCTYPE declaration is set to HTML5: "<!DOCTYPE html>": Use the <object> tag to embed Flash content.: To specify that the object is Flash content, d…
Any person in technology especially those working for big companies should at least know about the basics of web accessibility. Believe it or not there are even laws in place that require businesses to provide such means for the disabled and aging p…

809 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question