Question: What is the right regex to

create this url: domain.nl/projecten/scheidingswanden from

```
http://www.domain.nl/?module=projectencat&action=scheidingswanden

```

**in other words: replace the variable names ?module= and &action= with slashes**

**but also the other way around
because the frontcontroller needs to read the get variables module and action**

I don't know if it's only htaccess, but this logic is missing

thanks, Richard

Answer: 
Put the variable outside the function and than get the value 

```
var getWidth ;
var getHeight ;

$(function(){

    var slideBox = {

        gb: $('#box'),

        init: function() {

                sb = this,
                getBox = sb.gb,
                getWidth = getBox.width(),
                getHeight = getBox.height();
            getBox.animate({ marginLeft: '+='+getWidth }, 600 );

            $("#button").on("click", this.clickSlide);
        },

        clickSlide: function() {

            getBox.animate({ marginLeft: '+='+getWidth }, 600 );
        }
    };

    slideBox.init(); 
});

```

than make use in the function so that you can get the vlue in you clickside function
Your variables seem unnecessary, you can access everything you need to like this:
<http://jsfiddle.net/4WfZa/6/>. If you do need to store them you can always add them to the slideBox object and then populate them in init. This way the variables are stored against the object and can be used in any of the functions within it.

For a great article on javascript namespacing, including how to set up private and public variables see [this article](http://enterprisejquery.com/2010/10/how-good-c-habits-can-encourage-bad-javascript-habits-part-1/).