Sunday, June 17, 2012

My Dads Website


Just finishing up my dad's website for fathers day.  He's an artist.  Mostly done with CSS3, and a little bit of java


Thursday, June 14, 2012

Redirecting To A Mobile Site

I hate when websites take you to a mobile version, but then do not let you view the full version. www.volcomfijipro.com is one of them.

I wanted the same thing with my site mrbrzenski.com, but I wanted the option to go back to the regular site, and to remember it. So, javascript to the rescue. PS, this is cut and pasted from other peoples sites, like Sebastian Bettana, so kudos to them for making these things, I just work here.

I added this to the beginning of my website:


<script type="text/javascript" src="js/redirection_mobile.js"></script>
    <!-- Redirect Mobile and Tablet to m.site -->
<script type="text/javascript">
             SA.redirection_mobile ({
                tablet_redirection : "true",
            });
    </script>




And then added redirection_mobile.js to the js folder of my website 


(Check it out here, cut and paste with a text editor and save it yourself http://mrbrzenskimath.com/js/redirection_mobile.js)


Boom, done, now it redirects to my mobile site at m.mrbrzenskimath.com, and if I click back to the full website, it remembers that, and will not redirect me for a couple of days.


Check it out, there are many variables to mess with, read the .js file for more on how to add variables, and specific devices to send or not. 
I added the tablet_redirection:"true" to redirect all tablets, because it looks better, but left the rest of the variables alone because I did not need them.


Good Luck.



FIND ME ON
Twitter | YouTube | AppStore | Etsy | Zazzle