"how to" make new attributes

All postings beginning with "How can i configure (or implement) ..."
Antworten
Benutzeravatar
harrieklomp
Micro
Micro
Beiträge: 119
Registriert: 06.12.2010, 18:28

We from the Dutch node like to add some more attributes on the site like "paddo" (roadsigns for bikes in a shape of a mushroom), bike and some other attributes.
It would be great to get a "how to" make this on our own.

We have found some one who is very artistic with graphics and he has no problems that other nodes will use the attributes icons, look for a sample at http://www.opencaching.nl/articles.php?page=cacheinfo#attributes .

Greetings
Zuletzt geändert von harrieklomp am 17.04.2011, 14:32, insgesamt 1-mal geändert.
Owner and allround admin of the Dutch OC node.

Harrie Klomp

[url=http://www.opencaching.nl/viewprofile.php?userid=3][img]http://www.opencaching.nl/statpics/3.jpg[/img][/url] [url=http://geokrety.org/mypage.php?userid=7861][img]http://geokrety.org/statpics/7861.png[/img][/url]
oliver

1. database changes:

add to table cache_attrib
(category and group refers to table attribute_categories and attribute_groups)
(keep trans_id empty)

2. additional files:

place them in resource2\ocstyle\images\attributes

3. translation:

call translate.php and translate the cache type name
(you need to execute "Scan source codes" first)
OlofL

... and start with ID number 61 and allocate the number by posting the attribute name and number in this thread.
zaanhoeve

added:
Edit Delete 60 Stealth stealth 1746 5 1 0 0 0 resource2/ocstyle/images/attributes/stealth.png resource2/ocstyle/images/attributes/stealth-no.png resource2/ocstyle/images/attributes/stealth-disabl... The cache is in an urban environment and will requ... 1747
Edit Delete 61 Benchmark meetspijker 1744 4 1 0 0 0 resource2/ocstyle/images/attributes/meetspijker.pn... resource2/ocstyle/images/attributes/meetspijker-no... resource2/ocstyle/images/attributes/meetspijker-di... Dit attribuut is voor de meetspijkers van het Kada... 1748
Edit Delete 62 Mushroom paddo 0 4 1 0 0 0 resource2/ocstyle/images/attributes/paddo.png resource2/ocstyle/images/attributes/paddo-no.png resource2/ocstyle/images/attributes/paddo-disabled... Dit is een attribuut voor de ANWB " paddenstoelen"...

tnx for the help
Zuletzt geändert von zaanhoeve am 24.04.2011, 14:13, insgesamt 1-mal geändert.
OlofL

63:

6x Wheelchair accessible wheelchair 1802 2 1 0 1 0 resource2/ocstyle/images/attributes/wheelchair.png resource2/ocstyle/images/attributes/wheelchair-no.... resource2/ocstyle/images/attributes/wheelchair-dis... This geocache is accessible from wheelchair. 1803 NULL

(I will change this to use 63 right away avoid future confusion, it is using one of the already allocated numbers above)
OlofL

An important feature added in the upcoming release is a possibility to hide attribute types.

With the attribute hidden, the user cannot select it when modifying his/her caches, the user cannot search for it etc, but the attribute is still there. The reason for this is to make site integration easier and at the same time allow the freedom of node-operators to choose which attributes are interesting for each node.
Benutzeravatar
harrieklomp
Micro
Micro
Beiträge: 119
Registriert: 06.12.2010, 18:28

For a non programmer like me :-[ it would be nice to run a small program where we can select or deselect  all available attributes.
Owner and allround admin of the Dutch OC node.

Harrie Klomp

[url=http://www.opencaching.nl/viewprofile.php?userid=3][img]http://www.opencaching.nl/statpics/3.jpg[/img][/url] [url=http://geokrety.org/mypage.php?userid=7861][img]http://geokrety.org/statpics/7861.png[/img][/url]
OlofL

Yes, maybe that should go somewhere on the admin-screen, but it is not complicated to do without it: Locate the table cache_attrib. It has a new column "hidden". Set the value to 1 for attributes that should hidden or 0 or null for attributes that should not be hidden.

But the hidden attribute is not in your code yet, only in mine, be patient.
oliver

In the past we had an attribute "Hyperlink to another caching portal only".

We have disabled it, but it is still there. For old caches that have this attribute assigned, you can see it, you can search for it and the owner can remove it. But for new caches, it cannot be assigned. Thats the use of column "selectable". I think that fits our requirement that some node maintainers wants to hide some attributes.

In my opinion, an attribute should always be shown when the owner of the caches has assigned it. Think of the atttribute "dangers". If you hide it, that could be bad for the finder. Regardless of the node the user is actually using ... the attribute must be shown.
Antworten