Page 8 of 12

Re: Bonus Fields

PostPosted: Mon Feb 20, 2012 4:21 pm
by habbekak
Here's the array I get(I've out sided passwords and database details) :
Code: Select all
Array
(
    [SCRIPT_NAME] => /index.php
    [pagetype] => entry
    [entry] => Array
        (
            [uid] => 18
            [title] => Buscamper 1
            [uri] => buscamper
            [subtitle] => Vanaf €450
            [introduction] =>

Buscamper 1 is een compacte sterke camper die instaat is om door heel Europa te reizen. Hij beschikt over twee zeer comfortabele autostoelen en een heerlijk bed om tijdens en na de reis goed te kunnen rusten. Uiteraard is deze camper van alle gemakken voorzien zoals een gasfornuis, koelkast, potti potti en een achteruitrijd camera. Interesse om deze camper te huren? Neem dan contact met ons op.

            [body] =>

    Zeer comfortabele auto stoelen.
    2 persoons bed met een heerlijk matras.
    Beschikt over een gasfornuis, verwarming, koelkast, wc, fietsenrek, buiten stoelen, tafel en een achteruitrijd camera.
    Compact zodat u overal kunt parkeren.
    Sterke motor.
    Complete inventaris zie inventarislijst.


            [convert_lb] => 5
            [status] => publish
            [date] => 2010-10-11 12:05:00
            [publish_date] => 2010-10-11 12:05:00
            [edit_date] => 2012-02-17 23:20:16
            [user] => admin
            [allow_comments] => 0
            [keywords] => 2slaapplaatsen bus compact
            [via_link] =>
            [via_title] =>
            [comment_count] => 0
            [comment_names] =>
            [trackback_count] => 0
            [trackback_names] =>
            [extrafields] => Array
                (
                    [prijs] =>
Voorseizoen    Hoogseizoen    Naseizoen
475,- euro    550,- euro    450,- euro

Exclusief 50€ schoonmaakkosten

                    [foto] => 2012-01/dsc_0008.jpg
                    [reserveringssysteemurl] => http://www.camperverhuurpetten.nl/calendar/?id_item=4
                    [seokeywords] => buscamper te huur, bus camper, camper bus huren, goedkoop camper huren
                    [galleryimagelist] => 2010-10/dsc_0002.jpg######
2010-10/dsc_0022.jpg######
2010-10/dsc_0025.jpg######
2010-10/dsc_0029.jpg######
2010-10/dsc_0048.jpg######
2010-10/dsc_0031.jpg######
2010-10/dsc_0035.jpg######
2010-10/dsc_0042.jpg######
2010-10/dsc_0050.jpg######

                    [seodescription] => Buscamper te huur met comfortabele auto stoelen en een goedwerkende 2.9 Turbo Diesel
                    [seotitle] => Buscamper huren met omvormer, koelkast, gasfornuis en een klein oventje - Camperverhuur Petten
                )

            [code] => 18
            [link] => /2010/10/11/buscamper
            [vialink] =>
            [viatitle] =>
            [category] => Array
                (
                    [0] => camper-huren
                )

   <---cut--->

    [modifier] => Array
        (
            [uri] => buscamper
            [entry] => buscamper
            [date] => 2010-10-11
            [root] =>
            [action] => entry
            [pagetype] => entry
            [uid] => 18
            [weblog] => camper-huren
        )

    [timetaken] => 0.089
    [memtaken] => 17.9 mb
    [query_count] => 9
    [templatedir] => 2011
)


--

Re: Bonus Fields

PostPosted: Mon Feb 20, 2012 5:27 pm
by Harm10
Could you please post your template code as well (including the subweblog loop please).
And better edit the code you posted in your previous reply and cut out the config array. You never know who's looking..... ;)

Re: Bonus Fields

PostPosted: Mon Feb 20, 2012 6:08 pm
by habbekak
Hello,
This is the html-code from the template.
Code: Select all
[[ include file="2011/_sub_header.html" ]]
[[ if $entry.extrafields.foto!="" ]]
<img src="[[pivotx_dir]]includes/timthumb.php?src=[[$entry.extrafields.foto]]&amp;w=933&amp;h=200&amp;a=r" alt="[[$entry.extrafields.description]]" />
[[ /if ]]
   <div id="campermenu">
<ul>
<li><a href="http://www.camperverhuurpetten.nl/camper-huren">Terug</a></li>         
<li>[[popup description="Beschikbaarheid en reserveren" title="Beschikbaarheid en reserveren" fb_type="iframe" url="$entry.extrafields.reserveringssysteemurl" ]] </li>
<li><a href="http://www.camperverhuurpetten.nl/voorwaarden">Voorwaarden</a></li>
<li><a href="http://www.camperverhuurpetten.nl/inventarislijst">Inventarislijst</a></li>
</ul>
</div>

<div id="contentwrap">

   <div id="main">
   
      <div class="mainitems">
      
      <!-- entry: [[ title ]] -->
      <div class="entry">
         
         <h1>[[ title ]]</h1>
         <h4>[[ subtitle ]]</h4>
         <div class="entrybody">
            [[ introduction ]]
[[ if $entry.extrafields.foto!="" ]]
<img src="[[pivotx_dir]]includes/timthumb.php?src=[[$entry.extrafields.foto]]&amp;w=278&amp;h=186"
alt="[[$entry.extrafields.description]]" align="left" />
[[ /if ]]
            [[ body ]]
            
         </div>

      </div>
      </div>
   

   </div><!-- #main -->

<div id="sidebar">
<div class="gallery">
<h2>Foto's</h2>
[[gallery popup="fancybox"]]
<a href='%pivotxurl%includes/timthumb.php?src=%filename%&amp;w=700' class="fancybox" title="%title%" rel="gallery-%uid%" ><img src="%pivotxurl%includes/timthumb.php?src=%filename%&amp;w=75&amp;h=75&amp;q=50" alt="%alttext%" /></a>
[[/gallery]]
</div>

[[if $entry.extrafields.prijs!=""]]
<div id="prijs">
<h2>Prijzen</h2>
[[$entry.extrafields.prijs]]
</div>
[[/if]]

</div>

</div> <!-- #contentwrap -->

[[ include file="2011/_sub_footer.html" ]]

Re: Bonus Fields

PostPosted: Mon Feb 20, 2012 7:03 pm
by Harm10
Code should read
Code: Select all
[[popup description="Beschikbaarheid en reserveren" title="Beschikbaarheid en reserveren" fb_type="iframe" url=$entry.extrafields.reserveringssysteemurl ]]
to make it work (so remove the double quotes).
Remember that if you want the popup on only part of your screen you have to code a width as well.

Re: Bonus Fields

PostPosted: Thu Jun 14, 2012 1:08 pm
by Logfather
Has anyone ever used this for video's i.e. YouTube / Vimeo? This extension should be great for resizing vids (as you can already have one image, calling it in different formats) in different parts of your site. Or should the wysiwyg option be used for this?

Re: Bonus Fields

PostPosted: Thu Jun 14, 2012 1:48 pm
by Harm10
YouTube and Vimeo in a popup is supported by extension Fancybox http://extensions.pivotx.net/entry/29/fancybox
So check that one out!

Re: Bonus Fields

PostPosted: Thu Jun 14, 2012 1:57 pm
by Logfather
Hey Harm, thanks for letting me know about the pop-up / Fancybox. I'll have to test drive it sometime.

What I'm trying to do is keep every kind of media (images and videos) out of Introduction and Body blocks and give them their own Bonus Fields, doesn't have to be in a pop-up. :)

Re: Bonus Fields

PostPosted: Thu Jun 14, 2012 2:02 pm
by Harm10
Specifying any value in a Bonusfield is not that hard. But what do you want to do when some field is filled? Just display it? Then still Fancybox can be used.

Re: Bonus Fields

PostPosted: Thu Jun 14, 2012 2:18 pm
by Logfather
What input type to use for videos?

Re: Bonus Fields

PostPosted: Thu Jun 14, 2012 3:12 pm
by Harm10
YouTube and Vimeo can also be put into a field as there URL's or movie-id. But I guess you want 1 field that can contain all types?