Return-Path: X-Original-To: apmail-couchdb-user-archive@www.apache.org Delivered-To: apmail-couchdb-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id D9E7B10796 for ; Tue, 12 Nov 2013 21:19:51 +0000 (UTC) Received: (qmail 28729 invoked by uid 500); 12 Nov 2013 21:19:50 -0000 Delivered-To: apmail-couchdb-user-archive@couchdb.apache.org Received: (qmail 28692 invoked by uid 500); 12 Nov 2013 21:19:50 -0000 Mailing-List: contact user-help@couchdb.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@couchdb.apache.org Delivered-To: mailing list user@couchdb.apache.org Received: (qmail 28684 invoked by uid 99); 12 Nov 2013 21:19:50 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 12 Nov 2013 21:19:50 +0000 X-ASF-Spam-Status: No, hits=1.5 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of dch@jsonified.com designates 74.125.83.42 as permitted sender) Received: from [74.125.83.42] (HELO mail-ee0-f42.google.com) (74.125.83.42) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 12 Nov 2013 21:19:44 +0000 Received: by mail-ee0-f42.google.com with SMTP id e52so2109798eek.15 for ; Tue, 12 Nov 2013 13:19:23 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=jsonified.com; s=google; h=date:from:to:message-id:in-reply-to:references:subject:mime-version :content-type; bh=HiDF7yfPafH/fRgnw14xNofFqBfD4K24GCD4XLasXDA=; b=gS2JRVxtwWyn41kFKme4QcyJM6/gKlaSSSiMoMv6wzUBaCMpDBaIPx5nICBiY+K2sx k8FdVAC26nP0w3ST3TBUwR2oQdaZ/EnuK2KNQPUmEwcPIaUqVXV07f7Qf8yQZcxIthZM s3Azo8sT6opSosUZpXYdZO/UxEPXuUDGJILRk= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:date:from:to:message-id:in-reply-to:references :subject:mime-version:content-type; bh=HiDF7yfPafH/fRgnw14xNofFqBfD4K24GCD4XLasXDA=; b=Sff2n5aiXBr/QJmDCTuqFvwXeLyLFTEyKHGkWv5zdHmQKcIAPfDDW4g4YrZTqVilAX +YrvvRBTiqEtAHJhsQlRqdqt636iyE2U4a+mD++cjPONLRQ58I3zyYa8yZQxwh+eLjLC m6aNNGKkHhcM44D2poANS7I8r1tJH4gHPU2+qqCN3We7uxfwnyqEv0w/4kDPuBeeIg2E lve76b+nEDkn6dChf/noQmCdfSj65wC1XvkMHM6dbVbuufUQwxrctPwYREP6FxsP7TG+ 8Ae9AO3981vAPSur70k1Mp/CcUoLn5B5f4coD7PU0ihdUkAVeyvBTbJAn9oV1OeisIBq Rjxg== X-Gm-Message-State: ALoCoQmKu86RNEmMiFQev7aZe7OZW7UVYeVm58QnSCwPVu0JSdqqxqkiyq9ttdZlSO82jMtkDnSz X-Received: by 10.14.109.1 with SMTP id r1mr13427787eeg.32.1384291163672; Tue, 12 Nov 2013 13:19:23 -0800 (PST) Received: from akai.jsonified.com (chello084112019176.2.11.vie.surfer.at. [84.112.19.176]) by mx.google.com with ESMTPSA id x4sm80196303eef.1.2013.11.12.13.19.22 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 12 Nov 2013 13:19:23 -0800 (PST) Date: Tue, 12 Nov 2013 22:19:20 +0100 From: Dave Cottlehuber To: user@couchdb.apache.org Message-ID: In-Reply-To: References: <874224A6-BCB2-45DC-9CF1-5B0FAD7DB99D@couchbase.com> Subject: Re: CouchDB: Can a hierarchical URL structure be accomplished with unique documents? X-Mailer: Airmail Beta (214) MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="52829b58_60dc6223_ab0c" X-Virus-Checked: Checked by ClamAV on apache.org --52829b58_60dc6223_ab0c Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline On 12. November 2013 at 21:46:08, Hank Knight (hknight555=40gmail.com) wr= ote: > =20 > Here is an example of an entire website run entirely from attachments =20 > of a single document: > =20 > https://samplecouchpoweredsite.couchappy.com/site/www/zootemplate/index= .html =20 > =20 > It does not work so well when I add the attachments to unique documents= : =20 > https://samplecouchpoweredsite.couchappy.com/site2/zootemplate%2findex.= html/zootemplate%2findex.html =20 Hi Hank, What does =E2=80=9Cnot work so well=E2=80=9D mean=3F > The site can be managed here: > https://samplecouchpoweredsite.couchappy.com/=5Futils/ =20 > =20 > I would like for this to work like the first link but with each > attachment associated with a unique document. > =20 > Is this even possible=3F If so, how=3F I=E2=80=99m assuming you noticed that the relative paths aren=E2=80=99t c= orrect, but I don=E2=80=99t see anything to suggest you have fixed it: https://samplecouchpoweredsite.couchappy.com/site2/zootemplate%2findex.ht= ml =7B =5Fid:=C2=A0=22zootemplate/index.html=22, =5Frev:=C2=A0=222-fbd9de49558247a3115ba061daf8774f=22, =5Fattachments:=C2=A0=7B zootemplate/index.html:=C2=A0=7B content=5Ftype:=C2=A0=22text/html=22, revpos:=C2=A02, digest:=C2=A0=22md5-IBLi/kLPPv0dDYOhPMjlSQ=3D=3D=22, length:=C2=A06598, stub:=C2=A0true =7D =7D =7D should have things like the style sheet included: https://samplecouchpoweredsite.couchappy.com/site2/zootemplate%2findex.h= tml/css/style.css should appear in the attachment list as: =5Fattachments:=C2=A0=7B zootemplate/index.html/css/style.css:=C2=A0=7B content=5Ftype:=C2=A0=E2=80=9Ctext/css=22, =7D =7D =7D or the links made relative to another doc etc. I=E2=80=99m not clear what you are asking for, but I=E2=80=99d have a set= of documents, say 1 per each standard template or layout, and another wi= th the customer-specific content: template1 =C2=A0 =C2=A0 =5F/style.css =C2=A0 =C2=A0 -/asset.js template2 =C2=A0 =C2=A0 =5F/style.css =C2=A0 =C2=A0 -/asset.js mysite1 =C2=A0 =C2=A0 =5F/index.html and index.html could contain relative links ../../template1/style.css etc= . Hopefully that example makes sense for your use case. =46or example, the whole iriscouch site is delivered out of a single couc= hdb document: http://www.iriscouch.com/ and the css etc are all just atta= chments. Magic. Also, this old intro might be useful -=C2=A0http://www.slideshare.net/Cou= chbase/couchconfsfdesigningcouchbasedocuments with IIRC code here=C2=A0ht= tps://github.com/bigbluehat/blueink A+ Dave --52829b58_60dc6223_ab0c--