Welcome, Guest. Please login or register.
Did you miss your activation email?
2019-Dec-07 09:27

Login with username, password and session length

Recent

Shoutbox

Den:
Nov. 20 2019 - 1:23am
adding drop shadow to rules box makes art pop out toward viewer and rules box much interesting. overall the entire card looks much cooler
Den:
Nov. 16 2019 - 12:20am
check out the new card frames - Vogon GC - like greeting cards - just in time for the holiday season @
https://shenafu.com/magic/cc//
Den:
Nov. 15 2019 - 4:15am
check out the new card frames - Vogon LS - for landscape (letterbox) format @
https://shenafu.com/magic/cc//
break:
Sep. 01 2019 - 2:22am
@Den  Thanks, I have not submitted it and it should be available in about 24~48 hours !!
Den:
Aug. 31 2019 - 11:48pm
the same field for robot stat boost
break:
Aug. 20 2019 - 6:30pm
@Den Small question, what determines which stat and item use increases after battle (For Humans/Mutants) ?
break:
Mar. 24 2019 - 7:46pm
@Den Just finished 2nd playthrough and testing session. I really like the edits I have made. Going to take another week to look over things !!
break:
Mar. 11 2019 - 7:04pm
@Den Hey, thanks for all of the support. Finished with the changes and currently playing through the game !!

Author Topic: Card Search Page and API  (Read 5539 times)

Den

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1261
  • Selina is my Superstar
    • View Profile
    • Amuseum
Card Search Page and API
« on: 2010-Oct-30 13:15 »
CCG Card Search
http://daccg.com/ccgsearch/
The following fields do exact match: mana cost, cmc, power, toughness, loyalty
Color is inclusive (will find gold cards).
The rule field accepts these wildcards:
Dot (.) allows you to match any single character.
Dot+Asterisk (.*) allows you to match any string of zero or more characters.
Hover over keywords to display its rules in this box.

API
http://daccg.com/ccgsearch/ajax_ccgsearch.php
Fields are cardname, color, cost, cmc, supertype, cardtype, subtype, rule, power, toughness, loyalty.
Entire cards are returned as array of JSON objects, except cardname and cardtype are returned as name and type, respectively. (see ccgsearch.js for example of how to extract these objects)

Can retrieve rules using 'keyword' field.
Returns as array of one JSON object with fields keyword and rule.
Ex:
Code: [Select]
http://daccg.com/ccgsearch/ajax_ccgsearch.php?keyword=flying
to extract:
keyword = data[0].keyword;
rule = data[0].rule;

Changelog:
Spoiler:
09/13/18
All sets up to Commander 2019
Data source from mtgjson
Card link to scryfall (was magiccards.info)
Upgrade to PHP 7.2

10/08/11
All sets up to Innistrad
Double-face cards handled like split and flip cards
Minor changes to rules formatting (ie. some abilities may be split e.g. protection from two colors become two abilities)
New keywords fight and transform

6/22/11
Added exact card search.
Escape special characters.

6/18/11
Mirrodin Besieged and New Phyrexian cards
Both halves of split card and flip card searchable by name. Reminder text will tell you the other half: (See also xxxx.) Retrieved field is multi which returns the name of the other half.
Flavor text now included in setinfo.

2/22/11
The fields name, supertype, type, subtype, and rules search patterned words in any order

2/21/11
search by rarity and artist
return set info

2/20/11
search by color and cmc

2/19/11
added Mirrodin Besieged cards
new keywords battle cry and living weapon

1/28/11
added instructions
wildcards for rules field

11/3/10
keyword links (mouseover or click)
keyword rules box

11/1/10
autocard links


TODO.:
- import AllSets data
- allow +- symbols in rules search. +1/+1, -1/-1
- allow wildcards in mana search
« Last Edit: 2018-Sep-15 17:15 by Den »
Support me on Patreon

I saw. I conquered. I came.

Den

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1261
  • Selina is my Superstar
    • View Profile
    • Amuseum
Re: Card Search Page and API
« Reply #1 on: 2018-Sep-13 13:30 »
09/13/18
- All sets up to Commander 2019
- Data source from mtgjson
- Card link to scryfall (was magiccards.info)
- Upgrade to PHP 7.2

09/14/18
- link to support forums point to this topic page

09/15/18
- update keywords
- sort results alphabetically
« Last Edit: 2018-Sep-15 08:08 by Den »

Den

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1261
  • Selina is my Superstar
    • View Profile
    • Amuseum
Re: Card Search Page and API
« Reply #2 on: 2018-Nov-20 19:06 »
2018/11/20
; added sets ; up to Guilds of Ravnica
; added keywords ; jump-start ; mentor ; surveil
« Last Edit: 2018-Nov-20 19:14 by Den »

 

4 Guests, 1 User