Showing posts with label client-side. Show all posts
Showing posts with label client-side. Show all posts

Tuesday, June 11, 2013

SVG Navigable Viewport Part 4: The Quad Viewport and Fixing some Assumptions (again)

In my last post I had implemented viewport rotations, and I had assumed that I had fixed the problem with nested SVG elements. Unfortunately, as I started working on a "quad" viewport demo, I realized there were some problems with my assumptions about how SVG establishes new viewports. In short, I had to devise a new way to get the transformation matrix of an individual element.

Tuesday, June 4, 2013

SVG Navigable Viewport Part 3: Adding Rotations and Extending Functionality

This is a sample of how to rotate a SVG viewport using matrix transformations. There are two methods I explored. They basically are implemented near-identically, but operate somewhat differently. I'm also going to explore some slight changes to my previous implementation which made a few assumptions about the SVG DOM state.

Tuesday, May 28, 2013

SVG Navigable Viewport Part 2: Some Cross-Browser Support

So last time I presented a basic SVG viewport navigation strategy. I tested it in Chrome and it worked a treat. However, when I decided to test in the other browsers at my disposal (FF20, IE10), the nasty head of cross-platform incompatibility popped up in the strangest ways possible. I managed to add custom handlers for Firefox, but I didn't have time to look at IE10 or other browsers.

This time I'm going to try to figure out what gotcha's I have to solve to get IE10 working, seeing that it is currently the second most used browser. I would test Safari, but unfortunately the latest version is simply unavailable for me to test. I might try testing on Opera as well if I have time.

Tuesday, May 21, 2013

SVG Navigable Viewport Part 1: Theory and Frustrations

This is a continuation of my previous tests to try and develop a navigatable 2D scene using HTML5 and Scalable Vector Graphics. The features I want to discuss are:

  • Panning the scene
  • Scaling/Zooming in and out
  • Rotating the scene

Tuesday, May 14, 2013

Some Tests with HTML5 and Scalable Vector Graphics

These are a few tests with HTML and SVG vector graphics. There are a variety of good resources available online on how to use SVG, particularly the Mozilla Development Network (MDN). This is still a relatively new area of web development, and as such not every browser supports the SVG standard, and many don't support the full standard. I'm going to be focusing primarily on the "nitty-gritty" details so I won't be using GUI tools such as InkScape to create SVG (a.k.a. I'm going to be writing raw SVG code in a text editor, or use Javascript to generate/modify SVG elements).

Some good SVG resources:

Tuesday, May 7, 2013

Windows, NginX, MySQL, and PHP

Introduction

A while back I setup a LEMP server (Linux, NginX, MySQL, and PHP) using Virtual Box. This is fine for testing out how a live server might behave, or even for using as a virtual server if you don't have the dedicated hardware to host a server. However, for a server in active development it's a huge inconvenience as everytime I want to test out a change, no matter how small, I was forced to push the changes to the virtual server. To get around this, I'm going to setup a development server which can run in the Windows environment I normally use. I'm also going to setup the XDebug plugin. This will allow me to debug php code without using the "traditional" console/echo solution. I'm unsure if XDebug would work with my virtual server setup, but I do know it works with this development setup.

Tuesday, April 30, 2013

Online Transmission Line Simulation

This is a finite element simulation of the Telegrapher's Equations. I outlined the details of the simulation in my last post and had a SciPy implementation, and this time I've created a javascript port with user adjustable params. The simulation is only able to handle a point-to-point transmission line with a pulse step source. The termination resistor R1 is located at the source. There are 3 pre-defined scenarios which demonstrate issues with various termination resistances. I would recommend you read my other post for details on how the simulation works.

Tuesday, March 12, 2013

A Safer Way to test the Validity/Safety of a Link

One thing that's always bothered me is figuring out if a link is legitimate or potentially a security risk. This is especially problematic with shortened URL's. I really dislike these and don't follow shortened URLs unless I absolutely know it's a trusted link. Many times just knowing the poster isn't enough to convince me to click a shortened URL as it's way to easy for someone to have their account compromised.

So how do you analyze the contents of a target link in a safer environment other than test-clicking willy-nilly in a browser?

Tuesday, January 8, 2013

SSH Key-Pair Authentication

Introduction

In the past I've limited SSH access to my Ubuntu virtual server by using static IP addresses. This works, but I've recently implemented a better method for ensuring SSH security for my virtual server. It uses the private/public key authentication method.

This is actually the method used pretty much everywhere else because it doesn't require hard-coded static IP addresses.

This is based mostly on the HowtoForge article about Key-Based SSH Logins with PuTTY.

Tuesday, January 1, 2013

Automatic Preview

Introduction

This is a fun little post. I created a client-side preview box which automatically updates as the user types. It supports Alex Gorbatchev's Syntax Highlighter and MathJax.

Tuesday, December 25, 2012

Implementing my Useful Resources Page part 2

Introduction

This is the second part of my overview of how I implemented the Useful Resources page. This part focuses on the HTML and Javascript portions.

I'm using JQuery to animate the collapsible menus, as well as perform various selection and event handling tasks.

Wednesday, November 7, 2012

Blogger Syntax Highlighting

Introduction

One of the greatest features of any code editor is syntax highlighting. It makes code much easier to read. Luckily, there are several ways to add Syntax Highlighting to webpages, too. Like pretty much anything else on the web, you have two places you can perform the syntax highlighting: On the server, or on the client.

For server-side syntax highlighting there is the GeSHi tool written in PHP. For the client-side, there's Alex Gorbatchev's Syntax Highlighter written in Javascript. Both support a wide variety of languages and are fairly easy to use. There are pros and cons with each option.

A server-side solution obviously requires a server, and the server needs to be able host dynamic content.

A client-side solution doesn't need a server, but it does require the client to run a javascript program in order to get syntax highlighting. For most clients this is fine, but some clients, particularly older mobile clients, this can make your website fairly slow to load.

Because I want to use syntax highlighting with Blogger and I don't have access to the Blogger servers, the only option I have is a client-side solution, so I'll be using Alex Gorbatchev's Syntax Highlighter.

Note: at the time of this writing the latest version of Alex Gorbatchev's Syntax Highlighter is 3.0.83