上一页 1 ··· 3 4 5 6 7 8 下一页
摘要: 阅读全文
posted @ 2011-09-08 23:56 Lux.Y 阅读(487) 评论(2) 推荐(0)
摘要: PHP判断数组为空首选方法:count($arr),size($arr);$arr= array("");echo count($arr);echo size($arr);//输出1$arr= array();echo count($arr);echo size($arr);//输出0PHP判断数组为空方法2:empty($arr);$arr= array("");$result = empty($arr);//$result = false$arr = array();$result = empty($arr);//$result = true这两种方 阅读全文
posted @ 2011-09-07 21:38 Lux.Y 阅读(88933) 评论(0) 推荐(0)
摘要: <a href="Javascript:window.history.go(-1)">返回上一页</a><a onclick="window.location.href='list.php'">跳转到list.php</a> 阅读全文
posted @ 2011-08-31 22:53 Lux.Y 阅读(4975) 评论(0) 推荐(0)
摘要: Some times, when you work with symfony forms in this way:<form action="<?php echo url_for('@sf_guard_signin') ?>" method="post"> <?php echo $form['username']->renderLabel(); ?> <?php echo $form['username']; ?> <?php echo $form 阅读全文
posted @ 2011-08-31 22:40 Lux.Y 阅读(455) 评论(0) 推荐(0)
摘要: routing.ymlindex_offer: url: /offer/index/page/:page param: { module: offers, action: index, page: 1} #set default value of page to 1actions.class.phppublic function preExecute() { $culture = $this->getUser()->getCulture(); $siteSectionId = SiteSectionTable::getS... 阅读全文
posted @ 2011-08-31 20:37 Lux.Y 阅读(451) 评论(0) 推荐(0)
摘要: routing.ymlfacebook_contest: url:/facebook/f param: { module: sfGuardRegister, action: facebook }app.ymlall: facebook: appid:203549026375001 appsecret: 0321a3ee6737a28b15366d3575f7ac93 #channel_url: http://studiosm.fr.dev/channel.html perms: offline_access,email,publ... 阅读全文
posted @ 2011-08-31 20:31 Lux.Y 阅读(1705) 评论(0) 推荐(0)
摘要: 由于长期慢性劳损,颈椎病的发病年龄已经从40岁提前到30岁,并成为名副其实的白领职业病。更让人担心的是,颈椎上承头颅,下接躯干,既是脊椎中活动最多部位,也是神经中枢最重要部位,更是心脑血管的必经之路,一旦发生故障,后果严重。 阅读全文
posted @ 2011-08-30 18:19 Lux.Y 阅读(326) 评论(0) 推荐(0)
摘要: 转自: http://www.odino.org/281/incorrect-options-values-in-the-sfwidgetformdateThe cool stuff about sfWidgetForm[I18n]Date is that, obviously, you can specify which options' values should be included in the 3 selects rendering days, months and years.For example, to specify custom years:new sfWidge 阅读全文
posted @ 2011-08-26 20:23 Lux.Y 阅读(389) 评论(0) 推荐(0)
摘要: sfGuardTestFunctional class under /libclass sfGuardTestFunctional extends sfTestFunctional{ public function signin($username, $password) { return $this-> info(sprintf('Signin user using username "%s" and password "%s"', $username, $password))-> click('Signin' 阅读全文
posted @ 2011-08-26 18:14 Lux.Y 阅读(420) 评论(0) 推荐(0)
摘要: 转自: http://en.wikipedia.org/wiki/List_of_HTTP_status_codesList of HTTP status codesThe following is a list of HyperText Transfer Protocol (HTTP) response status codes. This includes codes from IETF in... 阅读全文
posted @ 2011-08-25 22:49 Lux.Y 阅读(586) 评论(0) 推荐(0)
摘要: Sometimes it is not as straightforward as one may think to get the current url to use it inside your application. Here is a snippet that I use to fetch the current URL and use it in a script. The current url (whether http or https) is now a local variable that you can do with as you please.$url = (! 阅读全文
posted @ 2011-08-25 21:43 Lux.Y 阅读(674) 评论(0) 推荐(0)
摘要: 几个巨牛的网站:作web开发要是不知道它们,那想做出nb的网站估计困难!960grid:http://960.gs/ 它把网页设定为960帧,分为12个columns.typekit:http://typekit.com/libraries/full 设置相关字体,可以把喜欢的字体下载到本地cufon:http://cufon.shoqolate.com/generate/ 用javascript设定特殊字体RSS 订阅: http://www.feedsky.com/Top 10 Free Tools to Create RSS for Any Websitejs: http://www.d 阅读全文
posted @ 2011-08-25 21:11 Lux.Y 阅读(419) 评论(0) 推荐(0)
摘要: $returnUrl = rawurlencode(base64_encode($returnUrl)); //编码 $returnUrl = parse_str(base64_decode($returnUrl));//解码 或者$returnUrl = base64_decode($returnUrl);//解码//或者//不知道为何, 上面第一种解码方式返回的是null, 求解$returnUrl = base64_encode($returnUrl); //编码$returnUrl = base64_decode($returnUrl);//解码 这是一种方式,但... 阅读全文
posted @ 2011-08-25 16:39 Lux.Y 阅读(6250) 评论(1) 推荐(0)
摘要: 转自: http://www.yslow.net/show.php?tid=447像有些搜索框中会显示“在这里输入要搜索的东西”,鼠标点击那个搜索框后,那些字就没有了, 鼠标点击页面其它地方后,搜索框里的文字又出现。<input value="请输入关键字" onfocus="if (value =='请输入关键字'){value =''}" onblur="if (value ==''){value='请输入关键字'}" />如果更换为以下的代码,鼠标伸过去 阅读全文
posted @ 2011-08-19 00:40 Lux.Y 阅读(818) 评论(0) 推荐(0)
摘要: See Michael Feathers' definitionA test is not a unit test if:It talks to the databaseIt communicates across the networkIt touches the file systemIt can't run at the same time as any of your other unit testsYou have to do special things to your environment (such as editingconfig files) to run 阅读全文
posted @ 2011-08-10 23:52 Lux.Y 阅读(352) 评论(0) 推荐(0)
上一页 1 ··· 3 4 5 6 7 8 下一页