You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session. Dismiss alert
ようこそ 時代遅れの情報がウェブ上にあふれている。そんな情報を見たPHP初心者は戸惑ってしまうだろう。そして、まずい手法やまずいコードが広まってしまう。 そんなのはもうやめよう。PHP: The Right Way は気軽に読めるクイックリファレンスだ。PHPの一般的なコーディング規約、 ウェブ上のよくできたチュートリアルへのリンク、そして現時点でのベストプラクティスだと執筆者が考えていることをまとめた。 大事なのは、 PHPを使うための正式なお作法など存在しない ってこと。 このサイトの狙いは、はじめて PHP を使うことになった開発者に、いろんなトピックを紹介すること。 経験豊富なプロの人にとっても、これまで深く考えることなく使ってきた内容について、新鮮な見方を伝えられるだろう。 このサイトは、決して「どのツールを使えばいいのか」を教えるものじゃない。 いくつかの選択肢を示して、それぞ
みなさんはコーディング規約を利用していますか。 個人で開発している時はオレオレルールで良かったのですが、 複数人で開発するようになると共通のルールがあった方がストレス無く開発が出来るようになります。 WEB系の言語のコーディング規約について、調べ物が必要だったので、 まとめたものをブログでもシェアします。 HTML・CSS Google HTML/CSS Style Guide の推奨ガイドラインまとめ HTML5 コーディングガイドライン(HTML5)ver1.0 JavaScript JavaScriptのいろいろなコーディングルールをまとめてみた PHP PHPのコーディング規約 PSR-0、PSR-1、PSR-2、PSR-3とは WordPress コーディング基準 Pear Manual :: 標準コーディング規約 Zend Framework PHP 標準コーディング規約 Ca
http://www.quora.com/Node-js-Ruby-Python-who-wins-in-5-years を読んでて「勝利条件としてより多くの”スタートアップ”に選択されること」という話がでてたけど、そもそも今は何が採用されているのか状況がよくわかたっていなかったので調べた。 スタートアップ? 一般(自分の周辺)に「ウェブサービス」みたいな呼称されているもの。消費者向けというかなんというか、企業向けシステムとか、ソーシャルゲーム単品とかは含めないことにした なんでスタートアップ?(小規模な企業) 企業が大きくなってくると、いろんな領域で必要なことがあってこの企業は→このプログラミング言語みたいなひもづけができなくなるので 項目は =企業ではなく=サービスでわけた 順番、国内外は適当。できるだけ知名度のありそうなサイトを選んだ いわゆるサーバーサイドのアーキテクチャの話(それ
私は結構エディタ難民で、HTML/CSS/PHP等をコーディングする際のエディタをWindows・Mac含め色々試してきましたが、最近は NetBeans IDE に落ち着いています。 NetBeans IDE は厳密にはエディタではなく、Windows・Mac・Linux用の無料で利用できるIDE(統合開発環境)の一種です。 ちなみに、↓のキャラクターは NetBeans IDE 日本語コミュニティの公式マスコットの「ねこび〜ん」です。 私はWordPressのテーマファイルを作成しているときに、PHPで独自のCMSを開発されている @kawagooch さんに勧められて使い始めたのですがとてもしっくりきたので、以後 HTML/CSS/PHP などWebサイトのコーディングには NetBeans IDE をメインで使っています。 私自身、NetBeans IDE を使うようになってからサ
デフォルトではXML形式の空要素を出力しますが、PHP 5.3.0から第2引数にfalseを指定すると<br>として出力できるようにもなりました。 この関数はもはやPHPerなら常識でしょうか? ■mb_strimwidth 文字を丸める関数です。 <?php $string = "アシアルは今、より多くのお客様にサービスを提供していこうと考えています。業務内容には多くの範囲が含まれますが、自身のアイデアを活かしたい、今までにないWebサービス を作りたい、PHP言語に興味がある、といった方は、アシアルで一緒に頑張ってみませんか?"; echo mb_strimwidth($string, 0, 60, '...', 'UTF-8');
最近はWebSocketで遊びたくてしかたがないfujimotoです、こんにちは。今回は、本日(2010/11/12)発売されている(はずの)待望の書籍、「パーフェクトPHP」の書評をお届けします。 僕は今週ひと足お先に献本をいただいて目を通したのですが、様々なPHP関連の書籍で「こういうことにも言及してほしいなぁ」「このサンプルを鵜呑みにされてしまうと困るかも...」というところをきちんとカバーしていたり、最新版の仕様や、PHPを使い倒しているユーザの考え方が反映されていて、今までにない書籍だな、というのが第一印象で、初心者のかたから上級者のかたまで、全員が買って損はない(少なくとも、書店で手にとってみる価値はある)一冊だと思います。 これは、いずれもPHPのヘビーユーザであり、よいところもわるいところも知り尽くしている著者のかたがたが、執筆するにあたって最初に考えたであろう「既にPHP
いよいよ2011年がスタートしました。 今年も去年同様、勉強することが 沢山あります。まだモチベーションが そこそこあるうちに勉強になりそうな 国内の記事をリンク集にしました。 迷ったときに見てみようかなと思い ます。 より最適な方法というのはあると思いますが、まずは扉を叩かない事には何が悪いかも分かりません。ということで、内容に拘らず、否の意見をスルーしてここに色々まとめさせて頂きました。 勉強したい気持ちはあるけど出来ない理由は「何を始めればいいのか分からない」という方も、何が出来るのか、どういった勉強法で出来るようになるかが分かればやる気が起きるかも知れません。 5分で分るシリーズ 以前も流行ったんですね。Web関連以外も含めてここにまとめられています。 5分で分かる PHP を知らない人が PHP の便利さを学べる記事を書いたよ 5分でわかる Ruby を知らない人が Ruby の
*.keicode.com について 2005年頃から個人的にソフトウェアの技術記事をまとめて、 当サイトに情報を掲載開始。その後、さまざまなテーマ毎に初心者向けの入門サイトなどをまとめてきました。 主な姉妹サイトとしては 「Python 入門」「Android 入門」 「Java 入門」「基礎からの IoT 入門」などがあります。 最近は YouTube チャンネル「IT なるほど TV」も開設し、動画を用いた技術解説も行っていくつもりです。 (なかなか更新できていませんが、やめたわけではありませんので、ぜひチャンネル登録をよろしくお願いします!) 当サイトのウェブホスティングについて 当サイトはブルーホストという米系のウェブホスティングを利用して運用しています。 参考までに書くと 2018年3月の実績では keicode.com ドメインの関連サイト合わせて、 月間約 25万 PV で
PHP、Perl、Ruby、C、C++等40以上の言語をブラウザで実行できるようになるjQueryプラグイン「Run This」 2010年03月11日- Run This! PHP、Perl、Ruby、C、C++等40以上の言語をブラウザで実行できるようになるjQueryプラグイン「Run This」。 ブラウザ内の<pre>コードで記述した部分を、その場でそのまま動かすことができ、うまくサイトに組み込めばより訪問者にとってわかりやすいページを作ることが出来そうです。 例えば、PHPの入門サイトなんかでは挙動を一瞬で確認できてしまいます。 具体的には以下の言語に対応しています。 Ada, Assembler, AWK, Bash, bc, Brainf**k, C, C#, C++, CLIPS, Clojure, COBOL, Common Lisp, D, Erlang, Forth
こんにちはこんにちは!! 今日、はてなの人気記事を見ていてこんな記事がありました…! ちゃんとセキュリティのこと考えてますか・・・!? 『セキュリティ対策とか難しいし面倒くせーし、俺の適当に作ったサービスとかどうなってもイイしww』 いいんですいいんです! 別にそう思ってるならどうでもいいんです! でもそんなプログラムをWeb上で公開すんじゃねーよボケと。 PHPで誰でも簡単Webサービス製作!でなんか作って公開した奴ちょっと来い - 甘味志向@はてな ふむふむ、PHPで簡単につくっちゃうのは良いけど、 公開するのなら、ちゃんとセキュリティホールなくしてからにしましょうね って記事ですね! でもぼくは、この記事を読んでも… なぜXSSがいけないのか 結局よくわかりませんでした…。 いちおうXSS脆弱性があるとダメな理由として、下のようなことが書かれてあったんだけど… フォームに入力したHT
タイトルは出来れば関連する方に読んで欲しかったので、軽く釣り針にしました。すみません。:*) 最近はやりのヒウィッヒヒー(Twitter)でも、よく「○○ったー」みたいなサービスがばんばん登場してますね! おかげでますますツイッターが面白い感じになってて、いい流れですね! でも・・・ちょっと気になることが・・・ 最近「もうプログラマには頼らない!簡単プログラミング!」だとか・・・ 「PHPで誰でも簡単Webサービス作成!」だとか・・・ はてなブックマークのホッテントリで見かけますよね・・・ プログラミングする人が増えるのは素敵です!レッツ・プログラミングなう! なんですけど・・・ ちゃんとセキュリティのこと考えてますか・・・!? 『セキュリティ対策とか難しいし面倒くせーし、俺の適当に作ったサービスとかどうなってもイイしww』 いいんですいいんです! 別にそう思ってるならどうでもいいんです!
PerlとRubyの文法一覧がとても良くまとまっていたので、便乗してPHPでもやってみました。 Perl基礎文法最速マスター – Perl入門〜サンプルコードによるPerl入門〜 Route 477 – Ruby基礎文法最速マスター 他の言語をある程度知っている人はこれを読めばPHPの文法を何となく理解できると思います。 間違い、不足等々あれば教えて下さいm(_ _)m バージョン PHP5.3系がリリースされていますが、ここではPHP5.2系を対象としています。 1.基礎 コードブロック PHPコードは「<?php」という開始タグから始まります。終了タグは「?>」です。HTMLにPHPコードを埋める際は終了タグを使いますが、ライブラリのようにPHPコードのみを記述する際は終了タグを省くことが慣例となっています。 終了タグを省く理由について id:Kiske さんに解説頂いています。ありが
PHPのあの関数をJavaScriptでやるには?をまとめた「phpjs.org」 2009年12月04日- PHPのあの関数をJavaScriptでやるには?をまとめた「phpjs.org」が便利です。 PHPを使っていて、JavaScript もかいているときに、PHPのあの関数をJavaScript で実装したいんだけどなぁ、という場合に索引から牽けて参考になります。 例えば、functions ページには使える関数がまとまっているのですが、array系、ソート系、入力チェック系やオブジェクト指向系、日付、ファイルシステム系、Math系、ハッシュなど実に多数のJavaScript用php関数が掲載されています。 例えば、addslashes だと次のような感じでJSのソースが見れます。 function addslashes (str) { return (str+'').repla
「追記とか」にコメントの返答や追記をしてますので合わせてどうぞ。 かれこれ3年くらいPHPをやっているので、せっかくなので10個の便利な関数を並べてみました。 作業効率がかなりアップするので、これからPHPをやってみようかなぁって思う方は知っておくと便利だと思います。 変数、配列の内容をキレイに表示する関数「d」 変数や配列の内容をHTML構文でキレイに表示してくれます。 しかも、var_dumpと書くとタイピングが大変なので「d($hoge)」として簡単に記述。 これだけでも作業効率8倍 function d() { echo '<pre style="background:#fff;color:#333;border:1px solid #ccc;margin:2px;padding:4px;font-family:monospace;font-size:12px">'; foreac
PHP では以下のように new してすぐメソッドを呼べない <?php new DateTime()->getOffset(); なので、引数をそのまま返す関数を作ってやると <?php function expr($a) { return $a; } expr(new DateTime())->getOffset(); // OK! 便利だなー おまけ 配列アクセス用のも作っておくと便利 <?php function expr($a) { return $a; } function idx($array, $i) { return $array[$i]; } echo idx(idx(expr(new DateTimeZone('Asia/Tokyo'))->getTransitions(), 0), 'abbr') . "\n"; おまけ2 無名関数をそのまま呼ぶときにも使える。 <
Haxe 4 is here! Haxe is an open source high-level strictly-typed programming language with a fast optimizing cross-compiler. Download 4.3.4 Released: 2024-03-04 Haxe can build cross-platform applications targeting JavaScript, C++, C#, Java, JVM, Python, Lua, PHP, Flash, and allows access to each platform's native capabilities. Haxe has its own VMs (HashLink and NekoVM) but can also run in interpre
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く