Skip to content

Instantly share code, notes, and snippets.

View alanerzhao's full-sized avatar
🎯
Focusing

螃蟹 alanerzhao

🎯
Focusing
View GitHub Profile
var app = angular.module('validationExample', []);
app.controller('signupController', ['$scope', function($scope) {
$scope.submitted = false;
$scope.signupForm = function() {
if ($scope.signup_form.$valid) {
} else {
$scope.signup_form.submitted = true;
}
@alanerzhao
alanerzhao / user.js
Created November 25, 2014 02:09
user
/**
* @file user.js
* @brief async login render mod
* @author baozi
* @version 0.0.1
* @date 2014-11-05
*/
define("user",["mf/login","jquery","handlebars"],function(require, exports, module) {
/**
* @file editor-main.js
* @brief editor upload mod
* @author baozi
* @version
* @date 2014-11-19
*/
define("comment",["mf/login","jquery",'handlebars'],function(require, exports, module) {
@alanerzhao
alanerzhao / base.js
Created November 25, 2014 02:07
base.js
/**
* @file base.js
* @brief ui dom handle
* @author baozi
* @version
* @date 2014-11-19
*/
define("base",["jquery"],function(require, exports, module) {
@alanerzhao
alanerzhao / loadmod.js
Last active August 29, 2015 14:09
load
/**
* @file load.js
* @brief Pull Load
* @author baozi
* @version 0.0.1
* @date 2014-11-19
*/
define('load',["jquery","handlebars"],function (require,exports,module){
seajs.use(['jquery'],function($) {
//hover
var hover = (function () {
function init () {
var _item = $(".J_list");
_item.on("mouseenter","dl",function(){
var _self = $(this);
_self.addClass("J_hover").siblings().removeClass("J_hover");
});
}
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title></title>
</head>
<body>
<ul id="postswrapper">
<li>2</li>
<li>2</li>
/*
* <li class="ui-listall clearfix">
* <a class="nbd" href="">
* <img _src="http://pic0.mofang.com/2014/0527/20140527041200936.jpg/214x120" style="display: block;">
* <p class="gong-hd-more">英雄联盟</p>
* </a>
* </li>
* $(function () {
* scrollLoad.init();
* })
//load cnzz
function loadScript(id,src, callback) {
var cnzz_protocol = (("https:" == document.location.protocol) ? " https://": " http://");
var cnzz_url = ""+cnzz_protocol+"w.cnzz.com/q_stat.php?id=" + id + "";
var s, r, t;
r = false;
s = document.createElement('script');
s.defer = "defer";
Math.floor(Math.random()*6)