# THIS SOFTWARE IS A PART OF FREE COMPETITOR PROJECT # THE FOLLOWING SOURCE CODE I UNDER THE GNU # AGPL LICENSE V3 OR ANY LATER VERSION. # This project is not for simple users, but for # web-masters and a like, so we are counting on # your ability to set it up and running. from modules import search def html(page, json): # This function adds a rendering of the json into the page free = False if "licenses" in json and json["licenses"]: free = True page = page + "\n
"+json.get("comment","")+"
" # Links website = json.get("links",{}).get("website", "") if free and website: page = page + """ """ git = json.get("links",{}).get("git", "") if git: page = page + """ """ wikipedia = json.get("links",{}).get("wikipedia", "") if wikipedia: page = page + """ """ return page def suggestions(page, json): # This function will render suggestions page = page + "