Search

If you’re using 2.0.7 beta, then the pagination issue is a known bug. I advise you to use 2.0.6 until 2.0.7 is out of beta!

ah, thanks nick. how do i roll back to 2.0.6 from 2.0.7?

edit: just overwriting the /symphony/ directory and index.php seemed to do the trick.

Select Box Link Field updated to version 1.16 on 25th of January 2010

I might add that this release adds some extra filtering options.

You can now filter a SBL field using sql: NULL or sql: NOT NULL to determine if the field has a value, or doesn’t have a value.

It’s useful in a situation where you have the SBL linking to entries in the same section, so therefore need to find out which is the parent, or which is a child.

I’m sure there are a bucket of other uses for it too.

1.16 also tidies up the filtering by handle, which mainly affected extensions that extend the SBL and don’t override the buildDSRetrivalSQL function. ie. Reference Link field.

is there some issue with encoding ampersands and other html entities with this field? i am not sure if this issue is caused by making my section links before my downgrade to 2.0.6. i am having issues with ampersands in a title being encoded correctly. creating a new entry doesn’t do any good.

this is happening when doing a section link for images to a project title in which the title has a html entity.

Are you using 2.0.7 download, or the integration branch?

downgraded rom 2.0.7 to 2.0.6 - i have a feeling it’s b/c i set things in 2.0.7 and now that i am on 2.0.6 it is causing issues

You can now filter a SBL field using sql: NULL or sql: NOT NULL to determine if the field has a value, or doesn’t have a value.

I would love to be able to pass null without the need for mysql: (wich didn’t seem to work when I tried) to the SBL field in order to get all entries that have no value set.

Unfortunately, I am a bit puzzled by the code, can somebody point me in the right direction where such a feature could be implemented?

The prefix sql: was added to make it very very clear that you want null entries. Otherwise, the filter would be incorrect if you actually had a handle called null which doesn’t sound probable, but if you had a programming site on Symphony, it could happen.

If you want to change it on your site, have a look at line 391-408 of field.selectbox_link.

Oh, I didn’t know SBL understood handles and not just IDs…

It was added in 1.13 and then bug fixed in 1.16 :)

Hm, maybe a checkbox could be added to the sections editor to enable “null for empty values” or a text input so that the empty-handle can be anything.

Is there any reason why you dislike the sql: predicate?

It’s common amongst Symphony extensions, almost a defacto standard. The Number, Map Location and Textbox field all use predicates to help filter a bit more ‘smartly’.

Yes, I would like to filter by “10,null” to get all entries having a link to entry 10 or no link at all.

Ah, good point :) That is some natural datasource functionality that goes missing when the predicate filters are active.

I’m not sure how difficult it would be to modify the extensions to take that into account, but I’m sure it could be done.

There’s anyway to make it don’t “show column” on the target section?

I have a section of Drivers and one of Teams. The Teams section have some Select Box Link fields so a Team owner can select the drivers of your team. So far so good.

But the problem is when I go to my Drivers entry list all those Select Box Link are listed on the columns, even if I uncheck Show Column on them.

I can confirm wtdan issue with html entites. They are not encoded in xml source! SBL 1.18, Symphony 2.0.7

If you get the latest SBL field code from GitHub, it should work. There hass been a fix for this issue. I am not sure why Alistair did not tag a new version.

post this in another comment but figured to give this one a shot as well. i’m trying to spit out a category count and have a select box link per each article containing those categories. when there is only one category selected, this count works 100%. however, once multiple categories are selected, i get this error:

Illegal offset type in isset or empty
/httpdocs/v1/extensions/selectbox_link_field/fields/field.selectbox_link.php line 244

239     
240     
241     public function findFieldIDFromRelationID($id){
242         if(is_null($id)) return NULL;
243         
244         if (isset(self::$cacheRelations[$id])) {
245             return self::$cacheRelations[$id];
246         }
247
248         try{

backtrace:

[/httpdocs/v1/extensions/selectbox_link_field/fields/field.selectbox_link.php:244] GenericErrorHandler::handler();
[/httpdocs/v1/extensions/selectbox_link_field/fields/field.selectbox_link.php:130] fieldSelectBox_Link->findFieldIDFromRelationID();
[/httpdocs/v1/extensions/selectbox_link_field/fields/field.selectbox_link.php:73] fieldSelectBox_Link->__findPrimaryFieldValueFromRelationID();
[/httpdocs/v1/symphony/lib/toolkit/data-sources/datasource.section.php:236] fieldSelectBox_Link->groupRecords();
[/httpdocs/v1/workspace/data-sources/data.category_count.php:52] include();
[/httpdocs/v1/symphony/lib/toolkit/class.frontendpage.php:489] datasourcecategory_count->grab();
[/httpdocs/v1/symphony/lib/toolkit/class.frontendpage.php:238] FrontendPage->processDatasources();
[/httpdocs/v1/symphony/lib/toolkit/class.frontendpage.php:63] FrontendPage->__buildPage();
[/httpdocs/v1/symphony/lib/core/class.frontend.php:50] FrontendPage->generate();
[/httpdocs/v1/index.php:20] Frontend->display();

i’m not a php expert by any means. does anyone know what’s going on here? it seems like you can only store one relational id per entry, is that correct?

It’s quite late so I could be being stupid but I’m getting rouge apersands in my xml under the following conditions.

Section B’s page title contains an ampersand Section A is linked to Section B by Section B’s page title.

I have a data source for section A that gets section B’s page title. This is fine apart from if I then group my section A results by the linked Section B’s title.

Here’s a section of the outputted xml

    <page handle="portfolio" id="8">
        <name>Portfolio</name>
    </page>
</navigation>
<services>
    <pagination total-entries="10" total-pages="1" entries-per-page="20" current-page="1" />
    <section id="3" handle="services">Services</section>
    <title handle="web-hosting-and-domain-transfer" value="Web Hosting & Domain Transfer">
        <entry id="23">
            <title handle="web-hosting-and-domain-transfer">Web Hosting &amp; Domain Transfer</title>
            <categories>

My fix is to not group my data - I’ve only started using symphony today after trying it once a few months ago so I don’t really know what I’m doing but I’m picking it up!

Create an account or sign in to comment.

Symphony • Open Source XSLT CMS

Server Requirements

  • PHP 5.3-5.6 or 7.0-7.3
  • PHP's LibXML module, with the XSLT extension enabled (--with-xsl)
  • MySQL 5.5 or above
  • An Apache or Litespeed webserver
  • Apache's mod_rewrite module or equivalent

Compatible Hosts

Sign in

Login details