Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 4619092
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 22, 20262026-05-22T02:22:38+00:00 2026-05-22T02:22:38+00:00

After using Packer (http://dean.edwards.name/packer/) I end up throwing a missing ; after (the long

  • 0

After using Packer (http://dean.edwards.name/packer/) I end up throwing a
missing ; after (the long packer string). I have no idea of the what and why.
possible fix and explanation please?

jQuery.fn.extend({
ImageRotate:function(parameters)
{   
    if (this.Wilq32&&this.Wilq32.PhotoEffect) return;
    return (new Wilq32.PhotoEffect(this.get(0),parameters))._temp;
},
rotate:function(parameters)
{
    if (this.length===0) return;
    if (typeof parameters=="undefined") return;
    if (typeof parameters=="number") parameters={angle:parameters};
    var returned=[];
    for (var i=0,i0=this.length;i<i0;i++)
    {
        var element=this.get(i);    
        if (typeof element.Wilq32 == "undefined") 
            returned.push($($(element).ImageRotate(parameters)));
        else 
        {
            element.Wilq32.PhotoEffect._rotate(parameters.angle);
        }
    }
    return returned;
},

rotateAnimation:function(parameters)
{
    if (this.length===0) return;
    if (typeof parameters=="undefined") return;
    if (typeof parameters=="number") parameters={angle:parameters};
    var returned=[];
    for (var i=0,i0=this.length;i<i0;i++)
    {   
        var element=this.get(i);
        if (typeof element.Wilq32 == "undefined") 
            returned.push($($(element).ImageRotate(parameters)));
        else 
        {
            element.Wilq32.PhotoEffect._parameters.animateAngle = parameters.angle;
            element.Wilq32.PhotoEffect._parameters.callback = parameters.callback ||
            function()
            {
            };
            element.Wilq32.PhotoEffect._animateStart();
        }
    }
    return returned;
}

});

Wilq32={};

Wilq32.PhotoEffect=function(img,parameters)
{
            this._IEfix=img;
            this._parameters=parameters;
            this._parameters.className=img.className;
            this._parameters.id=img.getAttribute('id');

            if (!parameters) this._parameters={};
            this._angle=0;
            if (!parameters.angle) this._parameters.angle=0;
            this._temp=document.createElement('span');
            this._temp.Wilq32 = 
                {
                    PhotoEffect: this
                };          
            var image=img.src;
            img.parentNode.insertBefore(this._temp,img);
            this._img= new Image();
            this._img.src=image;
            this._img._ref=this;
            jQuery(this._img).bind("load", function()
            {
                this._ref._Loader.call(this._ref);
            });
            if (jQuery.browser.msie) if (this._img.complete) this._Loader();
}

Wilq32.PhotoEffect.prototype._Loader=
(function()
{
    if (jQuery.browser.msie)
    return function()
    {
        var src=this._IEfix.src;
        this._IEfix.parentNode.removeChild(this._IEfix);
        this._temp.setAttribute('id',this._parameters.id);
        this._temp.className=this._parameters.className;
        var width=this._img.width;
        var height=this._img.height;

        this._img._widthMax=this._img._heightMax=Math.sqrt((height)*(height) + (width) * (width));
        this._img._heightMax=Math.sqrt((height)*(height) + (width) * (width));

        this._vimage = document.createElement('v:image');
        this._vimage._ref=this;
        this._vimage.style.height=height;
        this._vimage.style.width=width;
        this._vimage.style.position="relative";
        this._temp.style.display="inline-block";
        this._temp.style.width=this._temp.style.height=this._img._heightMax;
        this._vimage.src=src;
        this._vimage.rotate=0;
        this._temp.appendChild(this._vimage);

        var self = this;
        this._parameters.animateAngle=0;
        if (this._parameters.bind) 
        {
            for (var a in this._parameters.bind) if (this._parameters.bind.hasOwnProperty(a)) 
            for (var b in this._parameters.bind[a]) if (this._parameters.bind[a].hasOwnProperty(b)) 
            jQuery(this._temp).bind(b,this._parameters.bind[a][b]);
        }
        this._rotate(this._parameters.angle);       

    }
    else
    return function ()
    {
        this._IEfix.parentNode.removeChild(this._IEfix);
        this._temp.setAttribute('id',this._parameters.id);
        this._temp.className=this._parameters.className;
        var width=this._img.width;
        var height=this._img.height;

        this._img._widthMax=this._img._heightMax=Math.sqrt((height)*(height) + (width) * (width));

        this._canvas=document.createElement('canvas');
        this._canvas._ref=this;
        this._canvas.height=height;
        this._canvas.width=width;

        this._canvas.setAttribute('width',width);

        this._temp.appendChild(this._canvas);

        var self = this;
        this._parameters.animateAngle=0;
        if (this._parameters.bind) 
        {
            for (var a in this._parameters.bind) if (this._parameters.bind.hasOwnProperty(a)) 
            for (var b in this._parameters.bind[a]) if (this._parameters.bind[a].hasOwnProperty(b)) 
            jQuery(this._canvas).bind(b,this._parameters.bind[a][b]);
        }
        this._cnv=this._canvas.getContext('2d');
        this._rotate(this._parameters.angle);
    }

})();

Wilq32.PhotoEffect.prototype._animateStart=function()
{   
    if (this._timer) clearTimeout(this._timer);
    this._animate();
}
Wilq32.PhotoEffect.prototype._animate=function()
{   
    var temp=this._angle;
    if (typeof this._parameters.animateAngle!="undefined") this._angle-=(this._angle-this._parameters.animateAngle)*0.1;
    if (typeof this._parameters.minAngle!="undefined") if (this._angle<this._parameters.minAngle) this._angle=this._parameters.minAngle;
    if (typeof this._parameters.maxAngle!="undefined") if (this._angle>this._parameters.maxAngle) this._angle=this._parameters.maxAngle; 

    if (Math.round(this._angle * 100 - temp * 100) == 0 && this._timer) 
        {
            clearTimeout(this._timer);
            if (this._parameters.callback) 
                this._parameters.callback();
        }
        else 
        {
            this._rotate(this._angle);
            var self = this;
            this._timer = setTimeout(function()
            {
                self._animate.call(self);
            }, 10);
        }
}

Wilq32.PhotoEffect.prototype._rotate = (function()
{
    if (jQuery.browser.msie)
    return function(angle)
    {
        this._vimage.style.rotation=angle;
        var radians=angle*Math.PI/180;
        this._vimage.style.top=  (this._img._heightMax - this._img.height)/2- (this._vimage.offsetHeight-this._img.height)/2 +"px";
        this._vimage.style.left= (this._img._widthMax - this._img.width)/2- (this._vimage.offsetWidth-this._img.width)/2 +"px";
    }
    else
    return function(angle)

    {

        if (!this._img.width) return;
        if (typeof angle!="number") return;
        angle=(angle%360)* Math.PI / 180;
        var width=this._img.width;
        var height=this._img.height;
        var widthAdd = this._img._widthMax - width;
        var heightAdd = this._img._heightMax - height;
        this._canvas.width = width+widthAdd;
        this._canvas.height = height+heightAdd;
        this._cnv.save();
        this._cnv.translate(widthAdd/2,heightAdd/2);
        this._cnv.translate(width/2,height/2); 
        this._cnv.rotate(angle);
        this._cnv.translate(-width/2,-height/2);
        this._cnv.drawImage(this._img, 0, 0);
        this._cnv.restore();
    }


})();
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-22T02:22:38+00:00Added an answer on May 22, 2026 at 2:22 am

    Packer jams everything onto one line if I’m not mistaken so that any missing semicolons that would have been originally parsed OK turn into hard errors.

    There are a few missing semicolons in your js for example

    return function(angle)
    {
        this._vimage.style.rotation=angle;
        var radians=angle*Math.PI/180;
        this._vimage.style.top=  (this._img._heightMax - this._img.height)/2- (this._vimage.offsetHeight-this._img.height)/2 +"px";
        this._vimage.style.left= (this._img._widthMax - this._img.width)/2- (this._vimage.offsetWidth-this._img.width)/2 +"px";
    }
    

    is missing a semicolon. there are more.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a string of pack ed values which was created sequentially using something
After using AS2 for several years, I'm getting started with writing applications in AS3
After using them a while I can't help but feel that the hoops you're
After using array_unique , an array without the duplicate values is removed. However, it
After using the ebay API recently, I was expecting it to be as simple
After using PHP for a while now, I've noticed that not all built-in PHP
after using own custom cms for over 6 years, I decided to go for
After using hg qnew and hg qrefresh to create and update a patch that
I've been using Subversion for a few years and after using SourceSafe , I
if Form.Release is called after using the form, it will free all related memory

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.