/** * lowercase letters */
        $this->store['upper_Spec'] = array( *cut* );
        /** * uppercase letters */
        $this->store['lower_Spec'] = array( *cut* );
      
                    } else {
                      $errmsg='An unknown error occured.';
                    }
                  } else {
                    $errmsg='The passwords you entered do not match';
                  }
                } else {
                  $errmsg='Password has to be at least 8 characters long.';
                }
              } else {
                $errmsg='The email you entered is already in our database.';
              }
            } else {
              $errmsg='Please enter your email address.';
            }
          } else {
            $errmsg='Please enter your first name and your last name.';
          }
        } else {
        (...)
      
        // Happy debugging, suckers
        # define true (rand() > 10)
      

+1

// taken from graphael: https://github.com/DmitryBaranovskiy/g.raphael/blob/master/g.raphael.js#L303
this.attr(this.attrs.x ? 'x' : 'cx', x + h + d + (!center ? this.type == 'text' ? bb.width : 0 : bb.width / 2)).attr('y', center ? y : y - bb.height / 2);
 

anonymous

+1

// 3/12/2014 - Removed sleep for faster load time
//sleep(2);
 

anonymous

-2

$some_array=array();
if( count($some_array) > 0 ) {
    //around 50 lines of code
} else {
    //more code
}
 

-3

//This was in some code I found on stack overflow, the code works but issues like this made me have to rewrite it entirely for my own use.

entryName.length() > (relPath.length() + "/".length()/*As if the length of "/" will ever fluctuate.*/)
 

anonymous

+2

def very_dirtily_find_configured_ipv6_address_for_interface( interface ):
   try:
       dbg('finding /etc/network/interfaces ipv6 block for interface %s' % interface)
       addr=subprocess.Popen(['sed', '-n', '-e', '/iface[[:space:]]*%s[[:space:]]*inet6/,/^[[:space:]]*iface\|auto/ { /address/ { s/^[[:space:]]*address[[:space:]]*\([0-9a-f.:]*\)/\\1/p } } ' % interface , '/etc/network/interfaces'], stdin=subprocess.PIPE, stdout=subprocess.PIPE, stderr=subprocess.PIPE).communicate()[0].strip()
       prefix=subprocess.Popen(['sed', '-n', '-e', '/iface[[:space:]]*%s[[:space:]]*inet6/,/^[[:space:]]*iface\|auto/ { /netmask/ { s/^[[:space:]]*netmask[[:space:]]*\([0-9]*\)/\\1/p } } ' % interface , '/etc/network/interfaces'], stdin=subprocess.PIPE, stdout=subprocess.PIPE, stderr=subprocess.PIPE).communicate()[0].strip()
       dbg('found /etc/network/interfaces ipv6 block for interface %s: %s/%s' % (interface,addr,prefix))
       return IPy.IP("%s/%s" % (addr, prefix))
   except:
       dbg('something bitterly exploded while trying to find address for interface %s' % interface)
 

anonymous

0

##All you really need to know about this function (I've cut the most of the stuff between the braces) is that IT IS 1313 LINES LONG!!!
sub determine_access {

  # This query looks up students registered for a range of classes in a
  # given department.

  return %access;
}
 

+2

// codecrap.com: just the funny parts of the code
template <class T>
class SomeInterface: public SomeAbstractInterface
{
 public:
  int writeValue(unsigned int offset, unsigned int value)
  {
    unsigned int data = *(sharedAddress + offset);  //LINE1
  }
  int writeValue(unsigned int offset, int value)
  {
    unsigned int data = *(sharedAddress + offset);  //LINE2
  }
  int writeValue(unsigned int offset, float value)
  {
    *(sharedAddress + offset) = (float)(data + value);  //LINE3
  }
 private:
  T* sharedAddress;
};

// codecrap.com: actual comment in the header file
/*
There is a small problem in this class. The offset values are defined to be int.
where as the address the can be short or int. Since we add the offset to the 
address pointer the compiler may give a warning that you are trying to add a int
value to the possible short. But we cannot avoid this since the in the abstract 
(...) interface class, I have defined them as int. This kind of range checking 
is done in the (...), hence logically there should not be any problem and we can
ignore the compiler warning.
*/

// codecrap.com: compiler "warnings" to be ignored!
__FILE__: In member function 'int SomeInterface<T>::writeValue(unsigned int, unsigned int) [with T = float]':
__FILE__:LINE1: warning: converting to 'unsigned int' from 'float'
__FILE__: In member function 'int SomeInterface<T>::writeValue(unsigned int, int) [with T = float]':
__FILE__:LINE2: warning: converting to 'unsigned int' from 'float'
__FILE__: In member function 'int SomeInterface<T>::writeValue(unsigned int, float) [with T = short unsigned int]':
__FILE__:LINE3: warning: converting to 'short unsigned int' from 'float'
__FILE__: In member function 'int SomeInterface<T>::writeValue(unsigned int, float) [with T = long long unsigned int]':
__FILE__:LINE3: warning: converting to 'long long unsigned int' from 'float'
__FILE__: In member function 'int SomeInterface<T>::writeValue(unsigned int, float) [with T = unsigned int]':
__FILE__:LINE3: warning: converting to 'unsigned int' from 'float'
 

anonymous

0

            Func<int, IEnumerable<Employee>> getEmps = new Func<int, IEnumerable<Employee>>( ( c) => { for (int i = 0; i < c; i++) { yield return new Employee(); } return new List<Employee>(); });
 

+1

// We need sleep to get two different random seeds and therefore signatures
// if we have two close calls of this code
sleep(1);
srand (time(NULL));
int signature = rand() % MAX_CONS;
 

anonymous

+1

static const unsigned char _saltBytes[] = { 103, 80, 173, 166, 40, 54, 136, 141 };
static const string _salt = reinterpret_cast< const char* >( _saltBytes );
 

anonymous

+3

# Taken from Colout utility.
# By the way, it is awesome, despite some spaghetti code.
# https://nojhan.github.io/colout/

    if len(argv) >= 3:
        color = argv[2]
        if len(argv) >= 4:
            style = argv[3]
            if len(argv) == 5:
                on_groups = bool(argv[4])
                if len(argv) == 6:
                    as_colormap = bool(argv[5])
                    if len(argv) == 7:
                        as_theme = bool(argv[6])
                        if len(argv) == 8:
                            as_source = bool(argv[7])
                            if len(argv) == 9:
                                as_all = bool(argv[8])
                                if len(argv) == 10:
                                    scale = bool(argv[9])
 

anonymous

+2

<?php
// Get the first element of an array... sigh
foreach ($someArray as $key => $value) {
    $firstElement = $value;
    break;
}

// Disclaimer: the variable names were changed to protect the coder from bigger shaming
?>
 

+1

// No kidding, it's from FUCKING PRODUCTION CODE

// Retrieve
var MongoClient = require('mongodb').MongoClient;
var schools;
// Connect to the db
MongoClient.connect("mongodb://localhost:[CENSORED]/[CENSORED]", function(err, db) {
    if(!err) {
        console.log("We are connected");
        schools = db.collection('schools');

    }else
    {
        console.log(err)
    }
});

function Schools(){
    if(schools){

    }
    else
    {
        return 'test';
    }
}

module.exports = Schools;
 

0

            event.dateLabelSimple = (function (d) {
                return d >= 10 ? String(d) : ('0' + String(d))
            })(eDate.getDate())
            + '.' + romanDigits[(eDate.getMonth() + 1)];


            event.dateLabel = (function (d) {
                return d >= 10 ? String(d) : ('0' + String(d))
            })(eDate.getDate())
            + '.' + romanDigits[(eDate.getMonth() + 1)];

            if (
                eDate.getDate() == e2Date.getDate()
                &&
                eDate.getMonth() == e2Date.getMonth()
            ) {

            } else {
                if (
                    eDate.getMonth() == e2Date.getMonth()
                ) {
                    event.dateLabelSimple = (function (d) {
                        return d >= 10 ? String(d) : ('0' + String(d))
                    })(eDate.getDate())
                    + " - "
                    + (function (d) {
                        return d >= 10 ? String(d) : ('0' + String(d))
                    })(e2Date.getDate()) + ' '
                    + romanDigits[(e2Date.getMonth() + 1)];

                } else {
                    event.dateLabelSimple = (function (d) {
                        return d >= 10 ? String(d) : ('0' + String(d))
                    })(eDate.getDate())
                    + '.' + romanDigits[(eDate.getMonth() + 1)] + " - "
                    + (function (d) {
                        return d >= 10 ? String(d) : ('0' + String(d))
                    })(e2Date.getDate()) + '.'
                    + romanDigits[(e2Date.getMonth() + 1)];

                }

                event.dateLabel += '<br/><span>' + event.dateLabelSimple + '</span>';
            }


            event.hoursLabel = eDate.getHours()
            + ":" + (eDate.getMinutes() || '00')
            + " - " + e2Date.getHours() + ":" + (e2Date.getMinutes() || '00');


            return event

        });
    });
 

0

var romanDigits = ['_', 'I', 'II', 'III', 'IV', 'V', 'VI', 'VII', 'VIII', 'IX', 'X', 'XI', 'XII'];
 

0

// Actual function from production code. The script breaks after removing it.

function p2u(path) {
    // returns undefined
}
 

+2

.absolute {
    position: absolute;
}
.clear {
    clear: both;
}
.fixed {
    position: fixed;
}
.float-left {
    float: left;
}
.float-right {
    float: right;
}
.grid {
    margin: 0 auto;
    width: 980px;
}
.relative {
    position: relative;
}
.text-left {
    text-align: left;
}
.text-center {
    text-align: center;
}
.text-right {
    text-align: right;
}
.upper {
    text-transform: uppercase;
}
 

anonymous

0

if False and related:  # Temporary blocked
    # stuff
 

anonymous

+2

/**
 * Retrieve Attribute Group Id by Id or Name
 *
 * @param mixed $entityTypeId
 * @param mixed $setId
 * @param mixed $groupId
 * @return Mage_Eav_Model_Entity_Setup
 */
public function getAttributeGroupId($entityTypeId, $setId, $groupId)
{
    if (!is_numeric($groupId)) {
        $groupId = $this->getAttributeGroup($entityTypeId, $setId, $groupId, 'attribute_group_id');
    }

    if (!is_numeric($groupId)) {
        $groupId = $this->getDefaultAttributeGroupId($entityTypeId, $setId);
    }

    if (!is_numeric($groupId)) {
        throw Mage::exception('Mage_Eav', Mage::helper('eav')->__('Wrong attribute group ID'));
    }
    return $groupId;
}
 

anonymous

0

var current = Math.max.apply(Math, $(this).parent().parent().parent().parent().find('input').map(function () {
    return this.name.match(/\d+/);
}).get());
var next = Math.max.apply(Math, $(this).parent().parent().parent().parent().find(".features").last().find('input').map(function () {
    var t = this.name.match(/\d+/g);
    return t[1];
}).get()) + 1;
if (!isFinite(next))
    next = 0;
 

anonymous

+7

<img src="../../../../../../../../../../../../../../../../../assets/logo.png" />
 

anonymous

0

//Set initial focus on load
protected void Timer1_Tick(object sender, EventArgs e)
{
    Timer1.Enabled = false;
    ((ScriptManager)Page.FindControl("MasterScript")).SetFocus(txtCNPJ);
}
 

anonymous

0

' hide and show check box based on group selection
    HideAndShowCheckBox Array(notesGroup1Col, enterButGroup1Col, oldverButGroup1Col, fixVersionGroup1Col), True
    
    If oGroupSel = 0 Then
        HideAndShowCheckBox Array(notesGroup2Col, enterButGroup2Col, oldverButGroup2Col, fixVersionGroup2Col), True
        HideAndShowCheckBox Array(notesGroup3Col, enterButGroup3Col, oldverButGroup3Col, fixVersionGroup3Col), False
        HideAndShowCheckBox Array(notesGroup4Col, enterButGroup4Col, oldverButGroup4Col, fixVersionGroup4Col), False
        HideAndShowCheckBox Array(notesGroup5Col, enterButGroup5Col, oldverButGroup5Col, fixVersionGroup5Col), False
        HideAndShowCheckBox Array(notesGroup6Col, enterButGroup6Col, oldverButGroup6Col, fixVersionGroup6Col), False
        HideAndShowCheckBox Array(notesGroup7Col, enterButGroup7Col, oldverButGroup7Col, fixVersionGroup7Col), False
        HideAndShowCheckBox Array(notesGroup8Col, enterButGroup8Col, oldverButGroup8Col, fixVersionGroup8Col), False
    ElseIf oGroupSel = 1 Then
        HideAndShowCheckBox Array(notesGroup2Col, enterButGroup2Col, oldverButGroup2Col, fixVersionGroup2Col), False
        HideAndShowCheckBox Array(notesGroup3Col, enterButGroup3Col, oldverButGroup3Col, fixVersionGroup3Col), True
        HideAndShowCheckBox Array(notesGroup4Col, enterButGroup4Col, oldverButGroup4Col, fixVersionGroup4Col), False
        HideAndShowCheckBox Array(notesGroup5Col, enterButGroup5Col, oldverButGroup5Col, fixVersionGroup5Col), False
        HideAndShowCheckBox Array(notesGroup6Col, enterButGroup6Col, oldverButGroup6Col, fixVersionGroup6Col), False
        HideAndShowCheckBox Array(notesGroup7Col, enterButGroup7Col, oldverButGroup7Col, fixVersionGroup7Col), False
        HideAndShowCheckBox Array(notesGroup8Col, enterButGroup8Col, oldverButGroup8Col, fixVersionGroup8Col), False
    ElseIf oGroupSel = 2 Then
        HideAndShowCheckBox Array(notesGroup2Col, enterButGroup2Col, oldverButGroup2Col, fixVersionGroup2Col), False
        HideAndShowCheckBox Array(notesGroup3Col, enterButGroup3Col, oldverButGroup3Col, fixVersionGroup3Col), False
        HideAndShowCheckBox Array(notesGroup4Col, enterButGroup4Col, oldverButGroup4Col, fixVersionGroup4Col), True
        HideAndShowCheckBox Array(notesGroup5Col, enterButGroup5Col, oldverButGroup5Col, fixVersionGroup5Col), False
        HideAndShowCheckBox Array(notesGroup6Col, enterButGroup6Col, oldverButGroup6Col, fixVersionGroup6Col), False
        HideAndShowCheckBox Array(notesGroup7Col, enterButGroup7Col, oldverButGroup7Col, fixVersionGroup7Col), False
        HideAndShowCheckBox Array(notesGroup8Col, enterButGroup8Col, oldverButGroup8Col, fixVersionGroup8Col), False
    ElseIf oGroupSel = 3 Then
        HideAndShowCheckBox Array(notesGroup2Col, enterButGroup2Col, oldverButGroup2Col, fixVersionGroup2Col), False
        HideAndShowCheckBox Array(notesGroup3Col, enterButGroup3Col, oldverButGroup3Col, fixVersionGroup3Col), False
        HideAndShowCheckBox Array(notesGroup4Col, enterButGroup4Col, oldverButGroup4Col, fixVersionGroup4Col), False
        HideAndShowCheckBox Array(notesGroup5Col, enterButGroup5Col, oldverButGroup5Col, fixVersionGroup5Col), True
        HideAndShowCheckBox Array(notesGroup6Col, enterButGroup6Col, oldverButGroup6Col, fixVersionGroup6Col), False
        HideAndShowCheckBox Array(notesGroup7Col, enterButGroup7Col, oldverButGroup7Col, fixVersionGroup7Col), False
        HideAndShowCheckBox Array(notesGroup8Col, enterButGroup8Col, oldverButGroup8Col, fixVersionGroup8Col), False
    ElseIf oGroupSel = 4 Then
        HideAndShowCheckBox Array(notesGroup2Col, enterButGroup2Col, oldverButGroup2Col, fixVersionGroup2Col), False
        HideAndShowCheckBox Array(notesGroup3Col, enterButGroup3Col, oldverButGroup3Col, fixVersionGroup3Col), False
        HideAndShowCheckBox Array(notesGroup4Col, enterButGroup4Col, oldverButGroup4Col, fixVersionGroup4Col), False
        HideAndShowCheckBox Array(notesGroup5Col, enterButGroup5Col, oldverButGroup5Col, fixVersionGroup5Col), False
        HideAndShowCheckBox Array(notesGroup6Col, enterButGroup6Col, oldverButGroup6Col, fixVersionGroup6Col), True
        HideAndShowCheckBox Array(notesGroup7Col, enterButGroup7Col, oldverButGroup7Col, fixVersionGroup7Col), False
        HideAndShowCheckBox Array(notesGroup8Col, enterButGroup8Col, oldverButGroup8Col, fixVersionGroup8Col), False
    ElseIf oGroupSel = 5 Then
        HideAndShowCheckBox Array(notesGroup2Col, enterButGroup2Col, oldverButGroup2Col, fixVersionGroup2Col), False
        HideAndShowCheckBox Array(notesGroup3Col, enterButGroup3Col, oldverButGroup3Col, fixVersionGroup3Col), False
        HideAndShowCheckBox Array(notesGroup4Col, enterButGroup4Col, oldverButGroup4Col, fixVersionGroup4Col), False
        HideAndShowCheckBox Array(notesGroup5Col, enterButGroup5Col, oldverButGroup5Col, fixVersionGroup5Col), False
        HideAndShowCheckBox Array(notesGroup6Col, enterButGroup6Col, oldverButGroup6Col, fixVersionGroup6Col), False
        HideAndShowCheckBox Array(notesGroup7Col, enterButGroup7Col, oldverButGroup7Col, fixVersionGroup7Col), True
        HideAndShowCheckBox Array(notesGroup8Col, enterButGroup8Col, oldverButGroup8Col, fixVersionGroup8Col), False
    ElseIf oGroupSel = 6 Then
        HideAndShowCheckBox Array(notesGroup2Col, enterButGroup2Col, oldverButGroup2Col, fixVersionGroup2Col), False
        HideAndShowCheckBox Array(notesGroup3Col, enterButGroup3Col, oldverButGroup3Col, fixVersionGroup3Col), False
        HideAndShowCheckBox Array(notesGroup4Col, enterButGroup4Col, oldverButGroup4Col, fixVersionGroup4Col), False
        HideAndShowCheckBox Array(notesGroup5Col, enterButGroup5Col, oldverButGroup5Col, fixVersionGroup5Col), False
        HideAndShowCheckBox Array(notesGroup6Col, enterButGroup6Col, oldverButGroup6Col, fixVersionGroup6Col), False
        HideAndShowCheckBox Array(notesGroup7Col, enterButGroup7Col, oldverButGroup7Col, fixVersionGroup7Col), False
        HideAndShowCheckBox Array(notesGroup8Col, enterButGroup8Col, oldverButGroup8Col, fixVersionGroup8Col), True
    End If
 

0

gettIntValue(_aStringedInt) {
	if (‘0’ === _aStringedInt.charAt(0)) {
		return parseInt(_aStringedInt.substr(1, _aStringedInt.length);
	}

	return parseInt(_aStringedInt);
}
 

anonymous

-1

context['HOST'] = ('http://', 'https://')[request.is_secure()] + settings.HOST
 

anonymous

+1

  if (in != 0 && GET_CODE (in) == SUBREG
      && (subreg_lowpart_p (in) || strict_low)
#ifdef CANNOT_CHANGE_MODE_CLASS
      && !CANNOT_CHANGE_MODE_CLASS (GET_MODE (SUBREG_REG (in)), inmode, rclass)
#endif
      && contains_reg_of_mode[(int) rclass][(int) GET_MODE (SUBREG_REG (in))]
      && (CONSTANT_P (SUBREG_REG (in))
|| GET_CODE (SUBREG_REG (in)) == PLUS
|| strict_low
|| (((REG_P (SUBREG_REG (in))
&& REGNO (SUBREG_REG (in)) >= FIRST_PSEUDO_REGISTER)
|| MEM_P (SUBREG_REG (in)))
&& ((GET_MODE_PRECISION (inmode)
> GET_MODE_PRECISION (GET_MODE (SUBREG_REG (in))))
#ifdef LOAD_EXTEND_OP
|| (GET_MODE_SIZE (inmode) <= UNITS_PER_WORD
&& (GET_MODE_SIZE (GET_MODE (SUBREG_REG (in)))
<= UNITS_PER_WORD)
&& (GET_MODE_PRECISION (inmode)
> GET_MODE_PRECISION (GET_MODE (SUBREG_REG (in))))
&& INTEGRAL_MODE_P (GET_MODE (SUBREG_REG (in)))
&& LOAD_EXTEND_OP (GET_MODE (SUBREG_REG (in))) != UNKNOWN)
#endif
#ifdef WORD_REGISTER_OPERATIONS
|| ((GET_MODE_PRECISION (inmode)
< GET_MODE_PRECISION (GET_MODE (SUBREG_REG (in))))
&& ((GET_MODE_SIZE (inmode) - 1) / UNITS_PER_WORD ==
((GET_MODE_SIZE (GET_MODE (SUBREG_REG (in))) - 1)
/ UNITS_PER_WORD)))
#endif
))
|| (REG_P (SUBREG_REG (in))
&& REGNO (SUBREG_REG (in)) < FIRST_PSEUDO_REGISTER
/* The case where out is nonzero
is handled differently in the following statement. */
&& (out == 0 || subreg_lowpart_p (in))
&& ((GET_MODE_SIZE (inmode) <= UNITS_PER_WORD
&& (GET_MODE_SIZE (GET_MODE (SUBREG_REG (in)))
> UNITS_PER_WORD)
&& ((GET_MODE_SIZE (GET_MODE (SUBREG_REG (in)))
/ UNITS_PER_WORD)
!= (int) hard_regno_nregs[REGNO (SUBREG_REG (in))]
[GET_MODE (SUBREG_REG (in))]))
|| ! HARD_REGNO_MODE_OK (subreg_regno (in), inmode)))
|| (secondary_reload_class (1, rclass, inmode, in) != NO_REGS
&& (secondary_reload_class (1, rclass, GET_MODE (SUBREG_REG (in)),
SUBREG_REG (in))
== NO_REGS))
#ifdef CANNOT_CHANGE_MODE_CLASS
|| (REG_P (SUBREG_REG (in))
&& REGNO (SUBREG_REG (in)) < FIRST_PSEUDO_REGISTER
&& REG_CANNOT_CHANGE_MODE_P
(REGNO (SUBREG_REG (in)), GET_MODE (SUBREG_REG (in)), inmode))
#endif
))
    {
 

anonymous

+3

    private void Render_Map_Code(decimal latitude, decimal longitude)
    {
        System.Text.StringBuilder SB_Map = new System.Text.StringBuilder();
        SB_Map.Append("<script type=\"text/javascript\">");
        SB_Map.Append("\r\n");
        SB_Map.Append("  var map;");
        SB_Map.Append("\r\n");
        SB_Map.Append("  var geocoder;");
        SB_Map.Append("\r\n");
        SB_Map.Append("  function map_initialize( )");
        SB_Map.Append("\r\n");
        SB_Map.Append("  {");
        SB_Map.Append("\r\n");
        SB_Map.Append("    if ( google.maps.BrowserIsCompatible( ) )");
        SB_Map.Append("\r\n");
        SB_Map.Append("    {");
        SB_Map.Append("\r\n");
        SB_Map.Append("      //");
        SB_Map.Append("\r\n");
        SB_Map.Append("      // initialize map");
        SB_Map.Append("\r\n");
        SB_Map.Append("      //");
        SB_Map.Append("\r\n");
        SB_Map.Append("      map = new google.maps.Map2( document.getElementById( 'mapdiv' ) );");
        SB_Map.Append("\r\n");
        SB_Map.Append("      map.addControl( new google.maps.LargeMapControl3D( ) );");
        SB_Map.Append("\r\n");
        SB_Map.Append("      map.addControl( new google.maps.MenuMapTypeControl( ) );");
        SB_Map.Append("\r\n");
        SB_Map.Append("      ");
        SB_Map.Append("\r\n");
        SB_Map.Append("      map.setCenter( new google.maps.LatLng( " + latitude.ToString() + ", " + longitude.ToString() + " ), 5 );");
        SB_Map.Append("\r\n");
        SB_Map.Append("      //");
        SB_Map.Append("\r\n");
        SB_Map.Append("      // initialize marker");
        SB_Map.Append("\r\n");
        SB_Map.Append("      //");
        SB_Map.Append("\r\n");
        SB_Map.Append("      var marker = new google.maps.Marker( map.getCenter( ), { draggable: true } );");
        SB_Map.Append("\r\n");
        SB_Map.Append("      google.maps.Event.addListener( marker, 'dragend', function( p )");
        SB_Map.Append("\r\n");
        SB_Map.Append("        {");
        SB_Map.Append("\r\n");
        SB_Map.Append("          map.panTo( p );");
        SB_Map.Append("\r\n");
        SB_Map.Append("        }");
        SB_Map.Append("\r\n");
        SB_Map.Append("      );");
        SB_Map.Append("\r\n");
        SB_Map.Append("      map.addOverlay( marker );");
        SB_Map.Append("\r\n");
        SB_Map.Append("      //");
        SB_Map.Append("\r\n");
        SB_Map.Append("      // initialize geocoder");
        SB_Map.Append("\r\n");
        SB_Map.Append("      //");
        SB_Map.Append("\r\n");
        SB_Map.Append("      geocoder = new google.maps.ClientGeocoder( );");
        SB_Map.Append("\r\n");
        SB_Map.Append("      //");
        SB_Map.Append("\r\n");
        SB_Map.Append("      // initialize divs");
        SB_Map.Append("\r\n");
        SB_Map.Append("      //");
        SB_Map.Append("\r\n");
        SB_Map.Append("      document.getElementById( 'ctrl_Lat' ).value = map.getCenter( ).lat( ).toFixed( 6 );");
        SB_Map.Append("\r\n");
        SB_Map.Append("      document.getElementById( 'ctrl_Long' ).value = map.getCenter( ).lng( ).toFixed( 6 );");
        SB_Map.Append("\r\n");
        SB_Map.Append("      //");
        SB_Map.Append("\r\n");
        SB_Map.Append("      // hook map movement event(s)");
        SB_Map.Append("\r\n");
        SB_Map.Append("      //");
        SB_Map.Append("\r\n");
        SB_Map.Append("      google.maps.Event.addListener( map, 'moveend', function( )");
        SB_Map.Append("\r\n");
        SB_Map.Append("        {");
        SB_Map.Append("\r\n");
        SB_Map.Append("          marker.setLatLng( map.getCenter( ) );");
        SB_Map.Append("\r\n");
        SB_Map.Append("          document.getElementById( 'ctrl_Lat' ).value = map.getCenter( ).lat( ).toFixed( 6 );");
        SB_Map.Append("\r\n");
        SB_Map.Append("          document.getElementById( 'ctrl_Long' ).value = map.getCenter( ).lng( ).toFixed( 6 );");
        SB_Map.Append("\r\n");
        SB_Map.Append("        }");
        SB_Map.Append("\r\n");
        SB_Map.Append("      );");
        SB_Map.Append("\r\n");
        SB_Map.Append("    }");
        SB_Map.Append("\r\n");
        SB_Map.Append("  }");
        SB_Map.Append("\r\n");
        SB_Map.Append("  function map_geocode( address )");
        SB_Map.Append("\r\n");
        SB_Map.Append("  {");
        SB_Map.Append("\r\n");
        SB_Map.Append("    if ( map && geocoder )");
        SB_Map.Append("\r\n");
        SB_Map.Append("    {");
        SB_Map.Append("\r\n");
        SB_Map.Append("      geocoder.getLatLng(");
        SB_Map.Append("\r\n");
        SB_Map.Append("        address,");
        SB_Map.Append("\r\n");
        SB_Map.Append("        function( p )");
        SB_Map.Append("\r\n");
        SB_Map.Append("        {");
        SB_Map.Append("\r\n");
        SB_Map.Append("          if ( p )");
        SB_Map.Append("\r\n");
        SB_Map.Append("          {");
        SB_Map.Append("\r\n");
        SB_Map.Append("            map.panTo( p );");
        SB_Map.Append("\r\n");
        SB_Map.Append("          }");
        SB_Map.Append("\r\n");
        SB_Map.Append("          else");
        SB_Map.Append("\r\n");
        SB_Map.Append("          {");
        SB_Map.Append("\r\n");
        SB_Map.Append("            alert( 'Sorry, the geocoder failed to locate the specified address :-(' );");
        SB_Map.Append("\r\n");
        SB_Map.Append("          }");
        SB_Map.Append("\r\n");
        SB_Map.Append("        }");
        SB_Map.Append("\r\n");
        SB_Map.Append("      );");
        SB_Map.Append("\r\n");
        SB_Map.Append("    }");
        SB_Map.Append("\r\n");
        SB_Map.Append("  }");
        SB_Map.Append("\r\n");
        SB_Map.Append("  google.maps.Event.addDomListener( window, 'load', map_initialize );");
        SB_Map.Append("\r\n");
        SB_Map.Append("  google.maps.Event.addDomListener( window, 'unload', google.maps.Unload );");
        SB_Map.Append("\r\n");
        SB_Map.Append("</script>");
        SB_Map.Append("\r\n");

        this.ltrl_Map_Script.Text = SB_Map.ToString();


        SB_Map = null;

    }
 

anonymous

0

//this is how someone decided to create element for string array
1.ToString();
 

-3

git commit -m "hotfix" -a

http://imgur.com/c9xQPwcl
 

+5

//woozy+=multiplier;
woozy+=multiplier;
 

+4

/* it was a single line, here I've manually wrapped it
 *
 * source: http://hg.icculus.org/icculus/lugaru/file/97b303e79826/Source/GameTick.cpp */
 
if(((((findLengthfast(&rotatetarget)>150&&(i!=0&&k!=0))||(findLengthfast(&rotatetarget)>50&&
player[0].rabbitkickragdoll/*currentanimation==rabbitkickanim*/&&(i==0||k==0)))&&
normaldotproduct(rotatetarget,player[k].coords-player[i].coords)>0)&&((i==0||k==0)||
((player[i].skeleton.oldfree==1&&k!=0&&animation[player[k].currentanimation].attack==neutral)||
(player[k].skeleton.oldfree==1&&i!=0&&animation[player[i].currentanimation].attack==neutral)||
(player[i].isFlip()&&!player[i].skeleton.oldfree&&(i==0||k==0))||(player[k].isFlip()&&
!player[k].skeleton.oldfree&&(i==0||k==0))||(i==0||k==0))))||
((player[i].targetanimation==jumpupanim||
player[i].targetanimation==jumpdownanim||player[i].isFlip())&&
(player[k].targetanimation==jumpupanim||player[k].targetanimation==jumpdownanim||
player[k].isFlip())&&(i==0||k==0)&&(!player[i].skeleton.oldfree&&!player[k].skeleton.oldfree))){
 
 
/* ooo macarena */
 

anonymous

0

def gravity(self):
                if(not self.up and self.y <= 235):
                    self.y = self.y +(9.8*0.1)
                else:
                    self.up = False
 

anonymous

+1

https://github.com/search?q=%24_GET+sudo&ref=cmdform&type=Code
 

anonymous

+1

return (roles != null && roles.size() > 0 && !blocked) ? ((roles
			.containsAll(allowedRole)) ? true : false) : false;
 

anonymous

+2

$sql = "UPDATE some_table SET activation_date = '".$timestamp."' WHERE activation_id = '".$_GET['a'].$_POST['activation_id']."'"

// The code above assumes that $_GET['a'] and $_POST['activation_id'] does not have both values set at the same time
 

anonymous

-1

$slaves = $delegateModel->fetchSlavesByMaster($this->storage->user); // Save our enslaved souls
 

anonymous

+1

if(isset($_POST['password'])){ $_SESSION['password'] = $_POST['password']; } // *** NEEDS ENCRYPTION! ***
 

anonymous

+3

// this is from the leaked windows 2000 sourcecode in privat/shell/ext/tweakgui/ie4.c

/*****************************************************************************
 *
 *  IE4_OnCommand
 *
 *      Ooh, we got a command.
 *
 *****************************************************************************/

BOOL PASCAL
IE4_OnCommand(HWND hdlg, int id, UINT codeNotify)
{
    switch (id) {

    }

    return 0;
}
 

anonymous

+7

<nav class="clear">
          <p class="innactive">Navigation</p>
          <p class="active">Navigation</p>
          <ul class="clear">
            <li><a<?php if ($title == "1") {echo " class='current'";} ?> href="index.php" title="Page One">1</a></li>
            <li><a<?php if ($title == "2") {echo " class='current'";} ?> href="2.php" title="Page Two">2</a></li>
            <li><a<?php if ($title == "3") {echo " class='current'";} ?> href="3.php" title="Page Three">3</a></li>
            <li><a<?php if ($title == "4") {echo " class='current'";} ?> href="4.php" title="Page Four">4</a></li>
            <li><a<?php if ($title == "5") {echo " class='current'";} ?> href="5.php" title="Page Five">5</a></li>
            <li><a<?php if ($title == "6") {echo " class='current'";} ?> href="6.php" title="Page Six">6</a></li>
            <li><a<?php if ($title == "7") {echo " class='current'";} ?> href="7.php" title="Page Seven">7</a></li>
            <li><a<?php if ($title == "8") {echo " class='current'";} ?> href="8.php" title="Page Eight">8</a></li>
            <li><a<?php if ($title == "9") {echo " class='current'";} ?> href="9.php" title="Page Nine">9</a></li>
            <li><a<?php if ($title == "10") {echo " class='current' ";} ?> href="10.php" title="Page Ten">10</a></li>
            <li><a<?php if ($title == "11") {echo " class='current' ";} ?> href="11.php" title="Page Eleven">11</a></li>
            <li><a<?php if ($title == "12") {echo " class='current' ";} ?> href="12.php" title="Page Twelve">12</a></li>
            <li><a<?php if ($title == "13") {echo " class='current' ";} ?> href="13.php" title="Page Thirteen">13</a></li>
            <li><a<?php if ($title == "14") {echo " class='current' ";} ?> href="14.php" title="Page Fourteen">14</a></li>
            <li><a<?php if ($title == "15") {echo " class='current' ";} ?> href="15.php" title="Page Fifteen">15</a></li>
            <li><a<?php if ($title == "16") {echo " class='current' ";} ?> href="16.php" title="Page Sixteen">16</a></li>
            <li><a<?php if ($title == "17") {echo " class='current' ";} ?> href="17.php" title="Page Seventeen">17</a></li>
            <li><a<?php if ($title == "18") {echo " class='current' ";} ?> href="18.php" title="Page Eighteen">18</a></li>
            <li><a<?php if ($title == "videos") {echo " class='current' ";} ?> href="videos.php" title="Videos">Videos</a></li>
          </ul>
        </nav>
 

anonymous

0

<script language="JavaScript">
	rok=prompt("Podaj rok z przedziału 1900-2099")
	Wielkanoc = 22 + (19*(rok % 19) + 24) % 30 + (2*(rok % 4) + 4*(rok % 7) + 6*((19*(rok % 19) + 24) % 30) + 5) % 7
if (rok==1981) {wielkanoc=50}
if (rok==2076) {wielkanoc=50}
if (rok==1954) {wielkanoc=49}
if (rok==2049) {wielkanoc=49}
if (wielkanoc<=31) {
	alert("Niedziela wielkanocna w roku "+rok+" przypada "+wielkanoc+" marca")
		}
	else {
		alert("Niedziela wielkanocna w roku "+rok+" przypada "+(wielkanoc-31)+" kwietnia")
		}
</script>