Page 1 of 2

ContentPart "Register (Tabs)" -> MooTabs (MooTools)

Posted: Tue 6. May 2008, 09:17
by flip-flop
No solution, but a hint into the right direction :!:

Ok, let´s go --> If you want to have a output like this:

Code: Select all

  __________   __________   __________
  (  tab 1  )  (  tab 2  )  (  tab n  )
_____________________________________________________

   register content here
_____________________________________________________
e.g. using the mootabs snippet: (Example)

- We must have a closer look to the output of this cp.

My example template at /template/inc_cntpart/tabs/:

Code: Select all

<!--TABS_START//-->
[TITLE]<h3>{TITLE}</h3>[/TITLE]
[SUBTITLE]<h4>{SUBTITLE}</h4>[/SUBTITLE]
[TABS_ENTRIES]
<div id="myTabs{ID}" class="tabs">{TABS_ENTRIES}</div>
[/TABS_ENTRIES]
<!--TABS_END//-->

<!--TABS_ENTRY_START//-->
	<ul><li><h2>{TABTITLE}</h2>
		<ul><li>[TABCONTENT]
			[TABHEADLINE]<h3>{TABHEADLINE}</h3>[/TABHEADLINE]<br />
			[TABTEXT]{TABTEXT}[/TABTEXT]
		[/TABCONTENT]
		</li></ul>
	</li></ul>
<!--TABS_ENTRY_END//-->
The runtime output of the example template:

Code: Select all

<h3>CP Register Tabs</h3>
<h4>MooTabs development</h4>

<div id="myTabs19" class="tabs">   <!-- e.g. 19 is the ID of this CP //-->
	<ul><li>Tab 1 Label
		<ul><li>
			<h3>Title01</h3><br />
			Tab 1 Content
		</li></ul>
	</li></ul>

	<ul><li>Tab 2 Label
		<ul><li>
			<h3>Title02</h3><br />
			Tab 1 Content
		</li></ul>
	</li></ul>

	<ul><li>Tab 2 Label
		<ul><li>
			<h3>Title03</h3><br />
			Tab 1 Content
		</li></ul>
	</li></ul>
</div>
- but following the mootabs programming scheme:

Code: Select all

<div id="myTabs19">
  <ul>
    <li title="Tab1">Tab 1 Label</li>
    <li title="Tab2">Tab 2 Label</li>
    <li title="Tab3">Tab 3 Label</li>
  </ul>

  <div id="Tab1">
    Tab 1 Content
  </div>
  
  <div id="Tab2">
    Tab 2 Content
  </div>

  <div id="Tab3">
    Tab 3 Content
  </div>
</div>
What we need is a JS programmer who would like to write a script for sorting the unordered list to a mootabs conform output.
All the "tab" snippets I have found are following this scheme.

There is only one programmer who had solved this problem, but there are no examples. (German)

We can solve this using a php script before the site is deliver by the system, but that isn´t the best solution.
I think we need an XHTML semanticaly correct output and logical order for Screanreaders.
In this context an JS solution by runtime is the better one.

Knut

Re: ContentPart "Register (Tabs)" -> MooTabs (MooTools)

Posted: Tue 6. May 2008, 19:37
by Jensensen
Hi flip-flop,

well, I was testing, working on templates all the time and i found many other "Tabs" scripts, mooFX, proto... and all that stuff... i will send later.
The main problem you already mentioned and we discussed yesterday is:
flip-flop wrote:...We can solve this using a php script before the site is delivered by the system, but that isn´t the best solution...
I'll try to explain in some other words:

This is the structure of the template:
<!--TABS_START//-->
{TABS_ENTRIES}
<!--TABS_END//-->


<!--TABS_ENTRY_START//-->
{TABTITLE}
{TABHEADLINE}
{TABTEXT}
<!--TABS_ENTRY_END//-->

And this is the way, the script works:
At first, all tab ENTRIES are rendered as a whole!

Secondly the whole HTML output, the whole content, is targeted, placed INTO the {TABS_ENTRIES} block!

We can wrap a lot of DIV's around, edit HTML within, but we CANNOT place any elements of EACH "entry" part also ABOVE --> on top of the template output.

Most scripts need TABTITLE --> TABS BUTTONS obove!
Most "tab script solutions" require e.g. something like this:
{TABTITLE} | {TABTITLE} | {TABTITLE}... what could be used as TABS BUTTONS

<!--TABS_START//-->
{TABS_ENTRIES}
<!--TABS_END//-->
I AM REALLY wondering why OG called/named this CP TABS??? Because, default, even after hours of testing, there will be no "Tabs"! Guess, OG already has it, uses it, typing code, watching the forum with a smile on his face, while we're still searching for a solution... :wink:

Well, the sooner or later... :wink:

Re: ContentPart "Register (Tabs)" -> MooTabs (MooTools)

Posted: Tue 6. May 2008, 22:41
by Jensensen
found more like this:

http://www.nyokiglitter.com/tutorials/tabs.html
http://people.cs.uchicago.edu/~meweltma ... _tabs.html
http://thahaac.300mb.info/accordion/

latest idea was to use a horizontal accordion to arrange, style e.g. <h3>{TABTITLE}</3> like tab buttons with CSS, but failed.

So, hopefully pepe succeeds by using adobe spry...

Re: ContentPart "Register (Tabs)" -> MooTabs (MooTools)

Posted: Wed 7. May 2008, 10:27
by pepe
Hi friends,

nur mal ein kurzer Zwischenbericht bezüglich meiner Experimente mit dem CP "Register (Tabs)".

Ich hab's fast so hinbekommen, wie ICH es wollte... zumindest bin ich auf dem richtigen Weg :D
Ich habe jetzt echte TABS und die Seite wird NICHT jedesmal wieder aufgerufen, wenn ich die Tabs wechsle!
Es wechselt nur der Inhalt des Tab-Container !!!

Wollt ihr mal sehen?

Image

Da ich aber unbedingt möglichst alle vorhandenen CPs innerhalb des Inhaltsbereichs umsetzen können möchte, und das mit phpwcms-Bordmitteln :wink: , mußte ich mal wieder einige (kleine) Kompromisse machen. So ist eben das Leben!

Also, nicht so elegant, wie erhofft, aber im phpwcms Backend nur mit den vorhandenen Eingabemöglichkeiten realisierbar.
Als Script habe ich eine einzelne JS-Datei aus dem Adobe JS-Framework "SPRY" verwendet... ich werde aber in der kommenden Woche mal mit moo experimentieren, da ist eine ähnliche Lösung möglich...
Bei den Adobe-Jungs war aber alle so schön übersichtlich und verständlich und mit Code-Beispielen beschrieben.

Wenn ihr die 3 tmpl-Dateien haben möchtet... bitte melden :wink: ( Irgendwie RETHORISCH, glaube ich, oder? )

PS
Das es natürlich möglich ist, die Inhalte in den einzelnen Containern beliebig zu schachteln und z.B. Image-Popups aufzurufen, ist doch selbstverständlich!

PPS
Was die "Bordmittel" angeht, die ich immer so gerne anwende...
In diesem Fall verwende ich zwar den beiliegenden "56er Maulschlüssel", benutze ihn hier aber zum "Einkloppen" derContentParts in die Container :D

Re: ContentPart "Register (Tabs)" -> MooTabs (MooTools)

Posted: Wed 7. May 2008, 10:48
by update
DoppelWOW ;)

Re: ContentPart "Register (Tabs)" -> MooTabs (MooTools)

Posted: Wed 7. May 2008, 16:02
by flip-flop
For me I have solved the tabbing output in register tabs (MooTabs.js with an php snippet in template).
But my solution cant´t display pictures in this CP. Or my version (r161) is to old to do so.
I think pepe is your man, he had implemented this in register tabs.
My question, where have you patched the system to do so?

-> We are talking about ContentPart "Register (Tabs)" -> MooTabs (MooTools) (Please see the headline).

Knut :D

Re: ContentPart "Register (Tabs)" -> MooTabs (MooTools)

Posted: Thu 8. May 2008, 00:26
by pepe
flip-flop wrote:...
-> We are talking about ContentPart "Register (Tabs)" -> MooTabs (MooTools) (Please see the headline).
...
Ohhh yes ... pardon me :oops: :oops: :oops: But now i have another one, what fits with this Theme!

OK, not ready to go, but looks good and i hope, i will get it!!! I'm fiddeling on the JS code, to let it moove like an accordion :D
All made with ContentPart "Register (Tabs)" and prepared to work with mootools.js out of the phpwcms script-package :D ....
After pasting the 3 tmpl-files to the tabs-directory, all input can be done inside the backend of phpwcms :D

And here is, what i have until now:

Image

All CPs are possible inside the different register-containers ! Tomorrow its on the way, to play accordion... i will hope so :wink:

Re: ContentPart "Register (Tabs)" -> MooTabs (MooTools)

Posted: Thu 8. May 2008, 00:36
by pepe
flip-flop wrote:...
My question, where have you patched the system to do so?
...
Hi Knut... It's no patch!
All the code is inside the templates and is included "on the fly" during rendering the site!!!

But, because i want to go with all CPs of phpwcms inside the separate containers, it was necessary, to break it into 3 tmpl-files! But the use is that easy... every NewBee will do it in 10 Minutes...

It's a workaround... but works for me inside the backend, like a "charm" :D

Re: ContentPart "Register (Tabs)" -> MooTabs (MooTools)

Posted: Thu 8. May 2008, 14:36
by pepe
OK, here i am again... and my accordion is playing :D :D :D

Since my last posting, the static containers have gone... now all is fading vertical with the well known accordion effect.

Content of Register 3, fitting into its box:
Image

Content of Register 4, fitting into its box as well:
Image

But to be honest... at the moment its not jet working with the incuded mootools.js but with its little brother moo.fx.
Pardon me again, flip-flop :oops: :oops: :oops:
I have some difficulties, getting the demoscript running with the onboard-scriptset.... but i'm working on it.
See you later, friends, i will think over it for a while!!!

Now it's a good time for the backjard. A biiiig icecreame is waiting for me... and the GIRLS as well, you understand :D

Re: ContentPart "Register (Tabs)" -> MooTabs (MooTools)

Posted: Sat 24. May 2008, 17:15
by nora0355
Hallo,

habe gerade die "Register (Tabs)" -> Accordion (MooTools) ausprobiert, funktioniert super.
Würde die "Register (Tabs)" -> MooTabs (MooTools) auch mal ausprobieren, gibt es dafür auch schon eine Lösung?

Gruß Rainer

Re: ContentPart "Register (Tabs)" -> MooTabs (MooTools)

Posted: Wed 2. Jul 2008, 17:53
by flopi
Pepe wie hast du den die tabs so hinbekommen? :?:

ok nachdem ich nochmals nachgedacht habe hab ichs auch geschafft. Ich hab aber für den Anfang nur ein hmtl cp genommen. :)

mfg
flopi

Re: ContentPart "Register (Tabs)" -> MooTabs (MooTools)

Posted: Wed 2. Jul 2008, 18:04
by pepe
Und.... kannst du dann auch mehrere CPs in eine Box bekommen ???

Re: ContentPart "Register (Tabs)" -> MooTabs (MooTools)

Posted: Wed 2. Jul 2008, 18:40
by Jensensen
never - ever <--> trick :?: :idea:
zeigen... :shock:

nora0355 auch, bitte, bitte....

Re: ContentPart "Register (Tabs)" -> MooTabs (MooTools)

Posted: Wed 2. Jul 2008, 20:59
by pepe
Ich habe MEINEN Lösungsansatz mal hier zusammengefasst...
Here is the way, i have DONE it! Not that "elegant", but works for me...


http://forum.phpwcms.org/viewtopic.php? ... &sk=t&sd=a

Re: ContentPart "Register (Tabs)" -> MooTabs (MooTools)

Posted: Thu 3. Jul 2008, 08:34
by flopi
Das mit mehreren cp's in eine box muss ich noch gucken.
Ich habs mal nur zum laufen gebracht. Für mich schon eine Höchstleistung.
Aber ich werd mir mal den Beitrag von Pepe reinziehen, mal schaun ob ich alles kapier was er da alles getrieben hat. :D

mfg
flopi