Alright, I actually tried it out, which I probably should have done at the
beginning, and now I'm pretty sure I know what the issue is. You're using
"input type=dropdown", but "values from url" only works with the
autocompletion input types. I don't know, by the way, if that's a good idea
or not - I think my original thought with disallowing "dropdown" and the
like is so that, if there's a drastic change to the set of external values
- or if the URL is temporarily inaccessible, or some such - it won't mess
up editing of existing values. But perhaps there's an argument to be made
the other way.
On the other hand, maybe "dropdown" was a mistake there, and you just meant
"combobox".
On Mon, Jul 21, 2014 at 12:38 PM, Yury Katkov <katkov.ju...@gmail.com>
wrote:
> my point is that I don't need <substr> at all. My URL is static and I'm
> totally satisfied.
>
> -----
> Yury Katkov
>
>
> On Mon, Jul 21, 2014 at 5:50 PM, Yaron Koren <ya...@wikiworks.com> wrote:
>
>> Oops, sorry, you're right - it's the string "new" in the URL that you
>> should replace with "<substr>".
>>
>>
>> On Mon, Jul 21, 2014 at 11:43 AM, Yury Katkov <katkov.ju...@gmail.com>
>> wrote:
>>
>>> Hi Yaron!
>>> > You should replace "substr" in that URL with "<substr>" - that might
>>> just be the issue.
>>>
>>> I don't think I should... I don't need any parameters, try to click on
>>> the link - it produces perfect results.
>>>
>>> -----
>>> Yury Katkov
>>>
>>>
>>> On Mon, Jul 21, 2014 at 4:07 PM, Yaron Koren <ya...@wikiworks.com>
>>> wrote:
>>>
>>>> Hi Yury,
>>>>
>>>> You should replace "substr" in that URL with "<substr>" - that might
>>>> just be the issue.
>>>>
>>>> However, I should note that we're currently, as part of Jatin Mehta's
>>>> Google Summer of Code project on SF autocompletion, working on improving
>>>> autocompletion on external values. Right now the setup is quite limited -
>>>> you need to basically set up an API that outputs the necessary values in a
>>>> specific JSON format, unless you happen to be autocompleting on values from
>>>> another SMW-based wiki. Jatin's project will hopefully expand that
>>>> considerably, making use of functionality like that of the External Data
>>>> extension to allow for flexibly getting value sets from a variety of
>>>> formats. I don't know if you were planning to create such a mini-API
>>>> already, but, if you're willing to wait a month or two, it could be that
>>>> that effort would no longer be necessary.
>>>>
>>>> -Yaron
>>>>
>>>>
>>>> On Mon, Jul 21, 2014 at 6:06 AM, Yury Katkov <katkov.ju...@gmail.com>
>>>> wrote:
>>>>
>>>>> Hi everyone!
>>>>>
>>>>> I'm trying to figure out how the autocompletion on outside values
>>>>> works. [1] Is that possible to use it for the dropdowns? I'm trying to do
>>>>> that but have no results.
>>>>>
>>>>> I've added this to the LocalSettings.php:
>>>>> $sfgAutocompletionURLs['discourse'] = '
>>>>> http://discoursedb.org/w/api.php?action=sfautocomplete&substr=new&property=Was_written_by&format=json
>>>>> ';
>>>>>
>>>>> I've created the following field in the form:
>>>>> {{{field|Was written by|input type=dropdown|values from
>>>>> url=discourse|remote autocompletion}}}
>>>>>
>>>>> I expect that the dropdown will be populated with the values from
>>>>> discoursedb:
>>>>> Bangor Daily News editorial board
>>>>> Gavin Newsom, etc
>>>>>
>>>>> ... but nothing happens. What do I do wrong?
>>>>>
>>>>> [1]
>>>>> https://www.mediawiki.org/wiki/Extension:Semantic_Forms/Autocompleting_on_outside_values
>>>>> -----
>>>>> Yury Katkov
>>>>>
>>>>>
>>>>> ------------------------------------------------------------------------------
>>>>> Want fast and easy access to all the code in your enterprise? Index and
>>>>> search up to 200,000 lines of code with a free copy of Black Duck
>>>>> Code Sight - the same software that powers the world's largest code
>>>>> search on Ohloh, the Black Duck Open Hub! Try it now.
>>>>> http://p.sf.net/sfu/bds
>>>>> _______________________________________________
>>>>> Semediawiki-devel mailing list
>>>>> Semediawiki-devel@lists.sourceforge.net
>>>>> https://lists.sourceforge.net/lists/listinfo/semediawiki-devel
>>>>>
>>>>>
>>>>
>>>>
>>>> --
>>>> WikiWorks · MediaWiki Consulting · http://wikiworks.com
>>>>
>>>
>>>
>>
>>
>> --
>> WikiWorks · MediaWiki Consulting · http://wikiworks.com
>>
>
>
--
WikiWorks · MediaWiki Consulting · http://wikiworks.com
------------------------------------------------------------------------------
Want fast and easy access to all the code in your enterprise? Index and
search up to 200,000 lines of code with a free copy of Black Duck
Code Sight - the same software that powers the world's largest code
search on Ohloh, the Black Duck Open Hub! Try it now.
http://p.sf.net/sfu/bds
_______________________________________________
Semediawiki-devel mailing list
Semediawiki-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/semediawiki-devel