Skip to content

Function problem inside formatter #8

@stevefister

Description

@stevefister

Hey guys,

Having a problem. I am using a custom function in a custom formatter and am receiving errors on the search results page because it is trying to redeclare the function. I have tried:

if (function_exists('myfunction') != true) {

function myfunction { ... }

}

but then I receive an error that the function is undefined. Any ideas on where I can place this function, maybe at a higher level, where it can be defined once?

Thanks!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions