| CARVIEW |
Select Language
HTTP/2 302
server: nginx
date: Tue, 23 Dec 2025 18:14:16 GMT
content-type: text/plain; charset=utf-8
content-length: 0
x-archive-redirect-reason: found capture at 20081123113610
location: https://web.archive.org/web/20081123113610/https://github.com/sd/embedded-actions
server-timing: captures_list;dur=0.866468, exclusion.robots;dur=0.091739, exclusion.robots.policy;dur=0.076299, esindex;dur=0.013854, cdx.remote;dur=5.998492, LoadShardBlock;dur=279.587887, PetaboxLoader3.datanode;dur=95.255849, PetaboxLoader3.resolve;dur=70.128563
x-app-server: wwwb-app218-dc8
x-ts: 302
x-tr: 318
server-timing: TR;dur=0,Tw;dur=0,Tc;dur=0
set-cookie: wb-p-SERVER=wwwb-app218; path=/
x-location: All
x-as: 14061
x-rl: 0
x-na: 0
x-page-cache: MISS
server-timing: MISS
x-nid: DigitalOcean
referrer-policy: no-referrer-when-downgrade
permissions-policy: interest-cohort=()
HTTP/2 301
server: nginx
date: Tue, 23 Dec 2025 18:14:17 GMT
content-type: text/html; charset=utf-8
content-length: 115
x-archive-orig-server: nginx/0.6.31
x-archive-orig-date: Sun, 23 Nov 2008 11:36:10 GMT
x-archive-orig-connection: close
x-archive-orig-status: 301 Moved Permanently
location: https://web.archive.org/web/20081123113610/https://github.com/sd/embedded-actions/tree/master
x-archive-orig-x-runtime: 47ms
x-archive-orig-cache-control: no-cache
x-archive-orig-content-length: 115
cache-control: max-age=1800
memento-datetime: Sun, 23 Nov 2008 11:36:10 GMT
link: ; rel="original", ; rel="timemap"; type="application/link-format", ; rel="timegate"
content-security-policy: default-src 'self' 'unsafe-eval' 'unsafe-inline' data: blob: archive.org web.archive.org web-static.archive.org wayback-api.archive.org athena.archive.org analytics.archive.org pragma.archivelab.org wwwb-events.archive.org
x-archive-src: BNF-CRAWL-004-20081123110019-14876-crawling100-c/BNF-CRAWL-004-20081123113024-12724-crawling108.us.archive.org.arc.gz
server-timing: captures_list;dur=0.658195, exclusion.robots;dur=0.022499, exclusion.robots.policy;dur=0.009370, esindex;dur=0.011337, cdx.remote;dur=5.604940, LoadShardBlock;dur=120.974957, PetaboxLoader3.datanode;dur=125.388314, PetaboxLoader3.resolve;dur=102.717654, load_resource;dur=144.078256
x-app-server: wwwb-app218-dc8
x-ts: 301
x-tr: 302
server-timing: TR;dur=0,Tw;dur=0,Tc;dur=0
x-location: All
x-as: 14061
x-rl: 0
x-na: 0
x-page-cache: MISS
server-timing: MISS
x-nid: DigitalOcean
referrer-policy: no-referrer-when-downgrade
permissions-policy: interest-cohort=()
HTTP/2 302
server: nginx
date: Tue, 23 Dec 2025 18:14:17 GMT
content-type: text/plain; charset=utf-8
content-length: 0
x-archive-redirect-reason: found capture at 20081220010439
location: https://web.archive.org/web/20081220010439/https://github.com/sd/embedded-actions/tree/master
server-timing: captures_list;dur=0.625296, exclusion.robots;dur=0.023397, exclusion.robots.policy;dur=0.011221, esindex;dur=0.012577, cdx.remote;dur=10.880798, LoadShardBlock;dur=242.069119, PetaboxLoader3.datanode;dur=139.477036, PetaboxLoader3.resolve;dur=96.537384
x-app-server: wwwb-app218-dc8
x-ts: 302
x-tr: 279
server-timing: TR;dur=0,Tw;dur=0,Tc;dur=0
x-location: All
x-as: 14061
x-rl: 0
x-na: 0
x-page-cache: MISS
server-timing: MISS
x-nid: DigitalOcean
referrer-policy: no-referrer-when-downgrade
permissions-policy: interest-cohort=()
HTTP/2 200
server: nginx
date: Tue, 23 Dec 2025 18:14:18 GMT
content-type: text/html; charset=utf-8
x-archive-orig-server: nginx/0.6.31
x-archive-orig-date: Sat, 20 Dec 2008 01:04:38 GMT
x-archive-orig-connection: close
x-archive-orig-set-cookie: tender_email=; domain=.github.com; path=/; expires=Thu, 01 Jan 1970 00:00:00 GMT
x-archive-orig-set-cookie: tender_expires=; domain=.github.com; path=/; expires=Thu, 01 Jan 1970 00:00:00 GMT
x-archive-orig-set-cookie: tender_hash=; domain=.github.com; path=/; expires=Thu, 01 Jan 1970 00:00:00 GMT
x-archive-orig-set-cookie: _github_sess=; path=/; expires=Thu, 01 Jan 1970 00:00:00 GMT
x-archive-orig-status: 200 OK
x-archive-orig-x-runtime: 454ms
x-archive-orig-etag: "1bfcfb256fe514b0affbf37c0859a2dc"
x-archive-orig-cache-control: private, max-age=0, must-revalidate
x-archive-orig-content-length: 19164
x-archive-guessed-content-type: text/html
x-archive-guessed-charset: utf-8
memento-datetime: Sat, 20 Dec 2008 01:04:39 GMT
link: ; rel="original", ; rel="timemap"; type="application/link-format", ; rel="timegate"
content-security-policy: default-src 'self' 'unsafe-eval' 'unsafe-inline' data: blob: archive.org web.archive.org web-static.archive.org wayback-api.archive.org athena.archive.org analytics.archive.org pragma.archivelab.org wwwb-events.archive.org
x-archive-src: 50_7_20081219232317_crawl102-c/50_7_20081220004854_crawl103.arc.gz
server-timing: captures_list;dur=0.482241, exclusion.robots;dur=0.017195, exclusion.robots.policy;dur=0.008192, esindex;dur=0.010265, cdx.remote;dur=11.490041, LoadShardBlock;dur=365.045982, PetaboxLoader3.datanode;dur=280.450616, PetaboxLoader3.resolve;dur=234.337127, load_resource;dur=222.452360
x-app-server: wwwb-app218-dc8
x-ts: 200
x-tr: 641
server-timing: TR;dur=0,Tw;dur=0,Tc;dur=0
x-location: All
x-as: 14061
x-rl: 0
x-na: 0
x-page-cache: MISS
server-timing: MISS
x-nid: DigitalOcean
referrer-policy: no-referrer-when-downgrade
permissions-policy: interest-cohort=()
content-encoding: gzip
sd's embedded-actions at master — GitHub
This repository is private.
All pages are served over SSL and all pushing and pulling is done over SSH.
No one may fork, clone, or view it unless they are added as a member.
Every repository with this icon (
) is private.
Every repository with this icon (
This repository is public.
Anyone may fork, clone, or view it.
Every repository with this icon (
) is public.
Every repository with this icon (
| Description: | A Rails plugin that lets you embed actions in your views (with caching and response_to support) |
| Homepage: | https://github.com/sd/embedded-actions/wikis/home |
| Clone URL: |
git://github.com/sd/embedded-actions.git
Give this clone URL to anyone.
git clone git://github.com/sd/embedded-actions.git
|
| name | age | message | |
|---|---|---|---|
| |
README | Fri Dec 05 14:44:15 -0800 2008 | added github repo url to readme [sd] |
| |
Rakefile | Mon Oct 08 08:38:21 -0700 2007 | r63@chuao: sd | 2007-10-08 11:35:59 -0400 [sd] |
| |
init.rb | Fri Dec 05 14:28:38 -0800 2008 | simplified responds_to behaviour... plus rails ... [sd] |
| |
lib/ | Fri Dec 05 14:28:38 -0800 2008 | simplified responds_to behaviour... plus rails ... [sd] |
| |
test/ | Fri Dec 05 14:28:38 -0800 2008 | simplified responds_to behaviour... plus rails ... [sd] |
README
The "embedded actions" plugin
=============================
BASIC USAGE
Just like the traditional render :partial, embedded actions allow you to
refactor your views and extract presentation logic and templates into separate
files.
Unlike partials, embedded actions also let you define business logic to be
performed before the partial is included. That logic is encapsulated in the
already well understood metaphor of an action inside a controller.
So a simple call like
<%= embed_action :controller => "songs", :action => "top10" %>
lets you include an html fragment containing the top 10 songs into any of your
pages, regardless of which controller, action or view wants to do the including.
CACHING
Embedded actions can provide caching of their results (allowing for different
parameters) just like page caching, but at the level of html fragments.
So your dynamic pages can still be rendered dynamically, but some of the embedded
actions can be cached (and expired) independently.
Just declare an action as 'cacheable' in a way similar to page caching,
by invoking "caches_embedded" with the name of the action to cache.
class TestController < ApplicationController
caches_embedded :user_list
def user_list
...
end
end
Cached fragments can be invalidated with calls to expires_embedded, but you must
remember to use the same set of parameters used to embed the cached action in
the first place.
Additionally, the underlying fragment caching mechanism can be passed
an options hash in the following manner:
caches_embedded :user_list, :ttl => 60.minutes
RESPONDS_TO
Actions can use Rails' responds_to to provide different behaviours when invoked
normally or embedded in another view.
class TestController < ApplicationController
def user_list
responds_to do |format|
format.html {render :layout => :application}
format.embedded {render :layout => false}
end
end
end
SOURCE CODE
The official repository for embedded_actions is in GitHub:
https://github.com/sd/embedded-actions/tree/master
-------------------------------------------------------------------------------
Copyright (c) 2007, 2008 Sebastian Delmont <sd@notso.net>
Copyright (c) 2007, 2008 StreetEasy / NMD Interactive <https://www.streeteasy.com/>
All rights reserved.
Redistribution and use in source and binary forms, with or without modification,
are permitted provided that the following conditions are met:
* Redistributions of source code must retain the above copyright notice, this
list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright notice, this
list of conditions and the following disclaimer in the documentation and/or
other materials provided with the distribution.
* Neither the name of Sebastian Delmont, nor StreetEasy nor NMD Interactive
nor the names of their contributors may be used to endorse or promote products
derived from this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-------------------------------------------------------------------------------
CONTRIBUTORS
- Sebastian Delmont <sd@notso.net>
- Jerret Taylor <jerrett@gmail.com>
- Ryan Barber <rfb@skyscraper.nu>
- Andreas Simon <asimon@med4you.de>
- Jonathan Boler <galatians@gmail.com>
RELEASE HISTORY
1.0 - Oct 23 2007
First widespread release.
1.0.1 - Oct 30 2007
Fixed bug that was causing a "Content-encoding: identity" to leak
to all requests.
1.0.2 - Nov 29 2007
Fixed bug (thanks Jerret) that caused caching settings to leak
to actions with the same name in other controllers.
1.1 - Dec 4 2007
Passthrough options for fragment caching (Ryan).
Support for namespaced controllers in caching (Jerret).
Minor bug fixes.
1.1.1 - Feb 20 2008
Allow symbol names for controllers and actions (Andreas)
Fixed deprecated 'require_gem' in test environment (Andreas)
1.1.2 - Dec 5 2008
Simplified responds_to behaviour
Rails 2.2 compatibility (Jonathan)
This feature is coming soon. Sit tight!





