{"id":20842835,"url":"https://github.com/mudge/jquery_placeholder","last_synced_at":"2025-05-08T22:42:24.320Z","repository":{"id":687400,"uuid":"331435","full_name":"mudge/jquery_placeholder","owner":"mudge","description":"A jQuery plugin to support HTML5's placeholder attribute in older browsers.","archived":false,"fork":false,"pushed_at":"2011-11-30T07:45:06.000Z","size":98,"stargazers_count":15,"open_issues_count":0,"forks_count":2,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-05-08T22:42:20.091Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mudge.png","metadata":{"files":{"readme":"README.markdown","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2009-10-08T21:38:59.000Z","updated_at":"2019-08-13T14:28:31.000Z","dependencies_parsed_at":"2022-07-14T19:47:07.046Z","dependency_job_id":null,"html_url":"https://github.com/mudge/jquery_placeholder","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mudge%2Fjquery_placeholder","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mudge%2Fjquery_placeholder/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mudge%2Fjquery_placeholder/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mudge%2Fjquery_placeholder/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mudge","download_url":"https://codeload.github.com/mudge/jquery_placeholder/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253160727,"owners_count":21863624,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-18T01:25:40.464Z","updated_at":"2025-05-08T22:42:24.300Z","avatar_url":"https://github.com/mudge.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"jQuery Placeholder Plugin\n=========================\n\nA plugin to make HTML5's [`placeholder`][placeholder_spec] attribute work in non-HTML5 \nbrowsers.\n\nThis started as an attempt to simplify [my jQuery Form Example plugin][jquery_example]\nby delegating functionality to the browser where possible.\n\n  [placeholder_spec]: http://www.whatwg.org/specs/web-apps/current-work/multipage/common-input-element-attributes.html#the-placeholder-attribute\n  [jquery_example]: http://github.com/mudge/jquery_example\n\nUsage\n-----\n\nSimply use the `placeholder` attribute on your `input` and `textarea` tags and include \n`jquery.placeholder.js` somewhere in your page (you'll need [jQuery][jquery] as well, of course).\n\ne.g.\n\n    \u003cinput type=\"text\" placeholder=\"Username\"\u003e\n    \u003ctextarea placeholder=\"Comment here...\"\u003e\u003c/textarea\u003e\n    \n    \u003cscript type=\"text/javascript\" src=\"http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js\"\u003e\u003c/script\u003e\n    \u003cscript type=\"text/javascript\" src=\"jquery.placeholder.js\"\u003e\u003c/script\u003e\n\n  [jquery]: http://jquery.com/\n\nPlaceholder values in non-HTML5 browsers will be given the CSS class of `jquery_placeholder` so \nyou can style them to mimic other browsers' defaults which for Safari seems to be something \nlike the following:\n\n    .jquery_placeholder { color: #aaa; }\n\nIf you want to customise the class name used, you'll have to stop the plugin from\nautomatically running itself by commenting out `$($.placeholder.backwardsCompatibility);`\ntowards the end of `jquery.placeholder.js`. You can then set the class name via\n`$.placeholder.className` and call `backwardsCompatibility()` yourself.\n\ne.g.\n\n    \u003cscript type=\"text/javascript\" src=\"http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js\"\u003e\u003c/script\u003e\n    \u003cscript type=\"text/javascript\" src=\"jquery.placeholder.js\"\u003e\u003c/script\u003e\n    \u003cscript type=\"text/javascript\"\u003e\n      $.placeholder.className = 'myPlaceholderCSSClass';\n      $.placeholder.backwardsCompatibility();\n    \u003c/script\u003e\n\nAll event handlers are namespaced with `.placeholder` so they can be unbound or\ntriggered selectively:\n\n* `unload.placeholder` on the window;\n* `blur.placeholder` on the affected inputs;\n* `focus.placeholder` on the affected inputs;\n* `change.placeholder` on the affected inputs;\n* `submit.placeholder` on the affected forms.\n\nLicensing\n---------\n\nCopyright (c) Paul Mucur (http://mudge.name), 2010-2011.\nLicensed under the MIT license (see LICENSE.txt).\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmudge%2Fjquery_placeholder","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmudge%2Fjquery_placeholder","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmudge%2Fjquery_placeholder/lists"}