Wifi Shield2.0 + 2 Servo/1 Webcam help

it’s been a long time since my last post been kind of shy asking questions here due to a few previous responses but i’m stuck.

Alright so i purchased Wifi Shield from Asynclabs before they stopped selling, i purchased Wifi shield2.0. I have found that the wifi shield really cant handle a whole bunch of code, I will post my current code.
I actually want to use 2servo’s and 2 motors for driving and looking, however when i have the code for the motors in the wifi shield crashes… Even without the motors it crashes after about 30 minutes online.
So i’m trying to simplify what the shield is actually handling, So i setup a Windows server at home, with a static IP address, and now have domain name so i can access externally. I’m encounter problems with the programming portion due to onclick and website trying to change pages rather than just send the html update to wifishield for movement.

My current code running on Arduino i’m trying to replicate in into webserver is the basic which was posted by others, however posting code here for reference.
Now when i run it direct from Wifi shield, current IP address 192.168.0.220, works fine but crashes eventually. Anyone have some Ideas or areas i can look.
What i currently have going i copied the Wiserver print functions to html, so the html website works, however upon clicking of course /tiltup and stuff do not exist so i have to create these “Functions” or pages within the page to assist the wifi shield with the arduino update on positioning…

in Summary my end goal i’m trying to complete is have a webserver take over alot of the data and let the wifishield and arduino only handle the movement functions. I’d also like to get my motors back online and create a mobile site since the camera for mobile doesnt support live footage only snapshots. I know this is way to much to put on the wifishield and arduino alone.

    #include <WiServer.h>
    #include <Servo.h>

    #define WIRELESS_MODE_INFRA   1
    #define WIRELESS_MODE_ADHOC   2


    int panpin = 14;  // analog pin 0 to control panning servo for camera
    int tiltpin = 15; // analog pin 1 to control tilting servo for camera
    Servo panservo; Servo tiltservo;  // handles for panning and tilting
    int panpos = 90;  // initialize pan position to middle (range 0-180)
    int tiltpos = 90;  // initialize tilt position to middle (range 0-180)
    int servoinc = 5; // panning and tilting increments in degrees

    // Wireless configuration parameters ----------------------------------------
    unsigned char local_ip[] = {192,168,0,220};   // IP address of WiShield
    unsigned char gateway_ip[] = {192,168,0,1};   // router or gateway IP address
    unsigned char subnet_mask[] = {255,255,255,0};   // subnet mask for the local network
    const prog_char ssid[] PROGMEM = {"LyghtHouse"};      // max 32 bytes

    unsigned char security_type = 2;   // 0 - open; 1 - WEP; 2 - WPA; 3 - WPA2

    // WPA/WPA2 passphrase
    const prog_char security_passphrase[] PROGMEM = {"FFFFFFFFFFFFFFFFFFFFFFFFFF"};   // max 64 characters

    // WEP 128-bit keys
    // sample HEX keys
    prog_uchar wep_keys[] PROGMEM = { 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d,   // Key 0
                  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,   // Key 1
                  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,   // Key 2
                  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00   // Key 3
                };

    // setup the wireless mode
    // infrastructure - connect to AP
    // adhoc - connect to another WiFi device
    unsigned char wireless_mode = WIRELESS_MODE_INFRA;

    unsigned char ssid_len;
    unsigned char security_passphrase_len;
    // End of wireless configuration parameters ----------------------------------------


    // This is our page serving function that generates web pages
    boolean sendMyPage(char* URL) {

        // Check if the requested URL matches "/"
        if (strcmp(URL, "/") == 0) {
            // Use WiServer's print and println functions to write out the page content
             links ();
            // URL was recognized
            return true;
        }
        else if (strcmp(URL, "/tiltdown") == 0) {
          tiltpos = tiltpos + servoinc;
          if (tiltpos > 180) {
            tiltpos = 170;
          }
          tiltservo.write(tiltpos);
            links ();
            return true;
        }
        else if (strcmp(URL, "/tiltup") == 0) {
          tiltpos = tiltpos - servoinc;
          if (tiltpos < 0) {
            tiltpos = 10;
          }
          tiltservo.write(tiltpos);
            links ();
            return true;
        }
        else if (strcmp(URL, "/center") == 0) {
          tiltpos = 90;
          panpos = 90;
          tiltservo.write(tiltpos);
          panservo.write(panpos);
            links ();
            return true;
        }
            else if (strcmp(URL, "/panright") == 0) {
          panpos = panpos + servoinc;
          if (panpos > 180) {
            tiltpos = 170;
          }
          panservo.write(panpos);
            links ();
            return true;
        }
        else if (strcmp(URL, "/panleft") == 0) {
          panpos = panpos - servoinc;
          if (panpos < 0) {
            tiltpos = 10;
          }
          panservo.write(panpos);
            links ();
            return true;
        }
	else if (strcmp(URL, "/straightup") == 0) {
	   panpos = 90;
	   tiltpos = 0;
	panservo.write(panpos);
	tiltservo.write(tiltpos);
	links ();
	return true;
	}
	else if (strcmp(URL, "/straightdown") == 0) {
		tiltpos = 180;
		panpos = 90;
	panservo.write(panpos);
	tiltservo.write(tiltpos);
	links ();
	return true;
	}
	else if (strcmp(URL, "/center2") == 0) {
		tiltpos = 90;
		panpos = 90;
	panservo.write(panpos);
	tiltservo.write(tiltpos);
	links ();
	return true; 
	}
	else if (strcmp(URL, "/farright") == 0) {
		tiltpos = 90;
		panpos = 180;
	panservo.write(panpos);
	tiltservo.write(tiltpos);
	links ();
	return true; 
	}
	else if (strcmp(URL, "/farleft") == 0) {
		tiltpos = 90;
		panpos = 0;
	panservo.write(panpos);
	tiltservo.write(tiltpos);
	links ();
	return true; 
	}

        // URL not found
        return false;
    }

    void links () {
        WiServer.print("<html>");
        WiServer.print("<style type=\"text/css\">body {background-color:gray;color:white;font-size:150%} a:link,a:visited {color:blue;} a:hover {color:blue; background-color:brown;}</style>");
	WiServer.print("<head><center><h1>");
	WiServer.print("Household Bot");
	WiServer.print("</h1></head>");
	WiServer.print("<body>");
	WiServer.print("<u> Camera Control </u>");
	WiServer.print("
");
	WiServer.print("<a href=\"/tiltup\">Up</a>");
	WiServer.print("
");
	WiServer.print("<a href=\"/panleft\">Left</a>");
	WiServer.print("<a href=\"/center\">Center</a>");
	WiServer.print("<a href=\"/panright\">Right</a>");
	WiServer.print("
");
	WiServer.print("<a href=\"/tiltdown\">Down</a>");
	WiServer.print("
");
	WiServer.print("
");
	WiServer.print("<u> Preset </u>");
	WiServer.print("
");
	WiServer.print("<a href=\"/straightup\">Straight Up</a>");
	WiServer.print("
");
	WiServer.print("<a href=\"/farleft\">Left</a>");
	WiServer.print("<a href=\"/center2\">Center</a>");
	WiServer.print("<a href=\"/farright\">Right</a>");
	WiServer.print("
");
	WiServer.print("<a href=\"/straightdown\">Straight Down</a>");
	WiServer.print("
");
        WiServer.print("<img src=\"http://192.168.0.150:5412/nphMotionJpeg?&Resolution=640x480&Quality=Clarity\">  ");
	WiServer.print("</img>");
	WiServer.print("</center>");
	WiServer.print("</body>");
	WiServer.print("</html>");




    }

    void setup() {
      // Initialize WiServer and have it use the sendMyPage function to serve pages
      WiServer.init(sendMyPage);
      panservo.attach(panpin);  // attach pan function to analog pin
      tiltservo.attach(tiltpin);  // attach tilt function to analog pin
      panservo.write(90);
      tiltservo.write(90);
      // Enable Serial output and ask WiServer to generate log messages (optional)
      Serial.begin(57600);
      WiServer.enableVerboseMode(true);
    }

    void loop(){
      // Run WiServer
      WiServer.server_task();
    }

Bump anyone used a webserver with wifi shield and know how to update arduino from webserver rather then direct from wifishield?